Sha256: 1339d970c6e0c49f4980af9f279e6b94fd2c2c12e7938afcb1bc355876c816c8

Contents?: true

Size: 1.44 KB

Versions: 1

Compression:

Stored size: 1.44 KB

Contents

$LOAD_PATH << '../'
require 'yalgaar'

########################################################Callbacks#########################################	
#Callback for Connection

$connectionCallback = -> (arg0) { connectionCallback(arg0) } 
def connectionCallback(arg0)
	puts arg0
end

########################################################User Area for Calling Pub-sub######################################			
yalgaarClient = Yalgaar.new

#yalgaarConnect(clientKey,isSecure,$connectionCallback)#
yalgaarClient.yalgaarConnect("ck-47046d75cf64402f",0,$connectionCallback)
sleep 2
yalgaarClient.yalgaarDisconnect($connectionCallback)
sleep 2
#~ 
#yalgaarConnect(clientKey,isSecure,UUID,$connectionCallback)#
yalgaarClient.yalgaarConnect("ck-47046d75cf64402f",1,"123",$connectionCallback)
sleep 2
yalgaarClient.yalgaarDisconnect($connectionCallback)
sleep 2

#yalgaarConnect(clientKey,isSecure,AESSecretKey,AESType,$connectionCallback)#
yalgaarClient.yalgaarConnect("ck-47046d75cf64402f",1,"SystemLevelSolution",1,$connectionCallback)
sleep 2
yalgaarClient.yalgaarDisconnect($connectionCallback)
sleep 2

#yalgaarConnect(clientKey,isSecure,UUID,AESSecretKey,AESType,$connectionCallback)#
yalgaarClient.yalgaarConnect("ck-47046d75cf64402f",1,"123","SystemLevelSolution",1,$connectionCallback)
sleep 2
yalgaarClient.yalgaarDisconnect($connectionCallback)
########################################################END####################################################################

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
yalgaar-1.0.1 examples/connect.rb