This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Prepares an update operation. | |
var mySingletonTypeMapper = | |
session.newModelMapperStub('MySingletonType'); | |
// Creates or retrieves a model object | |
var obj = ...; | |
obj.myProperty = 'myValue'; | |
obj.myIntProperty = 12345; | |
obj.myBooleanProperty = true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Prepares an update operation. | |
var myArrayTypeMapper = | |
session.newModelMapperStub('MyArrayType'); | |
// Creates or retrieves a model object | |
var obj = ...; | |
obj.myProperty = 'myValue'; | |
obj.myIntProperty = 12345; | |
obj.myBooleanProperty = true; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Get the UID | |
var uid = ....; | |
// Prepares an update operation. | |
var myArrayTypeMapper = | |
session.newModelMapperStub('MyArrayType'); | |
// Creates or retrieves a model object | |
var obj = ...; | |
obj.myProperty = 'myValue'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl -X POST -H "Accept:application/json" \ | |
-d "w=your-app-id&x=user@domain&y=passwordhash%3d&z=" \ | |
http://moat-iot-runtime:[port]/dms/restgw/Admin/Login |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"groupRoleUid":"-9223372036854775808", | |
"lastLoggedIn":"Wed, 25 Apr 2012 07:28:25 GMT", | |
"roleUid":"8aa01502329e284a01329f37e3ef0154", | |
"sessionKey":"11876d44-b285-4f9b-a9cb-a6b7a6b91a0c", | |
"userId":"user@domain", | |
"accessToken":"9999999999999999999999999999999999999999999" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl -X POST -H "Accept:application/json" \ | |
-d "region=**&type=B&addresses=my.gateway&token=9999999999999999999999999999999999999999999" \ | |
http://moat-iot-runtime:[port]/dms/restgw/NetworkDevice/FindByPushAddresses |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Prepares an add operation. | |
var mySingletonTypeMapper = | |
session.newModelMapperStub('MySingletonType'); | |
// Creates or retrieves a model object | |
var obj = mySingletonTypeMapper.newModelStub(); | |
obj.myProperty = 'myValue'; | |
obj.myIntProperty = 12345; | |
obj.myBooleanProperty = true; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Prepares an update operation. | |
var mySingletonTypeMapper = | |
session.newModelMapperStub('MySingletonType'); | |
// Enqueues the remove operation | |
mySingletonTypeMapper.remove({ | |
error : function(type, code) { // ---- (2) | |
if (type == 'NOT_FOUND') { | |
... | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'time' | |
require 'base64' | |
require 'net/http' | |
require 'net/https' | |
require 'openssl' | |
require 'uri' | |
module Route53 | |
class Client |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Example: | |
# $ scons && ~/sound.sh | |
# $ mvn clean deploy && ~/sound.sh Basso | |
VOL=6 | |
SND=$1 | |
if [ -z $SND ]; then |