Benvenuto nella Documentazione API
Attualmente, sia la libreria, sia la sua documentazione, sono ancora in fare di progettazione, alcune informazioni potrebbero non essere corrette.
IDNjs.Manager Class
-
Manager() : IDNjs.Manager 1.0.0
Default constructor
-
loadNodes( String url, Function onSuccess, Function onError ) : jqXHR 1.0.0
Retrieve a list of nodes from the server.
-
url : String
document url
-
onSuccess
: Function (IDNjs.Node[] nodes)
callback called if the request succeded.
-
onError
: Function (Number status, IDNjs.Exceptions.NetworkException exception)
callback called if an error occurred during the request or if the server returned an error.
-
url : String
-
loadNode( String url, Function onSuccess, Function onError ) : jqXHR 1.0.0
Retrieve a node from the server.
-
url : String
node url
-
onSuccess
: Function (IDNjs.Node node)
callback called if the request succeded.
-
onError
: Function (Number status, IDNjs.Exceptions.Exception exception)
callback called if an error occurred during the request or if the server returned an error.
-
url : String
-
deleteNode( Node node, Function onSuccess, Function onError ) : jqXHR 1.0.0
Delete a node in the server.
-
node : Node
node to be deleted
-
onSuccess
: Function ()
callback called if the request succeded.
-
onError
: Function (Number status, IDNjs.Exceptions.Exception exception)
callback called if an error occurred during the request or if the server returned an error.
-
node : Node
-
writeNode( Node node, Function onSuccess, Function onError ) : jqXHR 1.0.0
Write a node in the server, performing a smartPUT.
-
node : Node
node to be written
-
onSuccess
: Function ()
callback called if the request succeded.
-
onError
: Function (Number status, IDNjs.Exceptions.Exception exception)
callback called if an error occurred during the request or if the server returned an error.
-
node : Node
IDNjs.Node Class
-
Node( String lri ) 1.0.0
Default constructor
-
lri : String
node LRI
-
lri : String
-
Node( String lri, String nodeLocalName ) 1.0.2
Default constructor
-
lri : String
node LRI
-
nodeLocalName : String
node local name
-
lri : String
-
getLRI( ) : String 1.0.0
Returns the node LRI
-
setLRI( String lri ) : void 1.0.0
Sets the node LRI.
-
lri : String
node LRI
-
lri : String
-
getLocalName( ) : String 1.0.0
Returns node local name
-
setLocalName( String localName ) : void 1.0.0
Sets the node local name.
-
localName : String
node local name
-
localName : String
-
getKeywords( ) : String 1.0.2
Returns node keywords
-
setKeywords( String keywords ) : void 1.0.2
Sets the node keywords.
-
keywords : String
node keywords
-
keywords : String
-
getLocation( ) : Object 1.2.1
Returns node location object. { "Latitude":0.000, "Longitude":0.000 }
-
setLocation( Float latitude, Float longitude ) : void 1.2.1
Sets the node location.
-
latitude : Float
node location latitude
-
longitude : Float
node location longitude
-
latitude : Float
-
getContent( ) : String 1.2.0
Returns node application data content
-
setContent( String content ) : void 1.2.0
Sets the node application data content.
-
content : String
node content data
-
content : String
-
setContent( String content, String contentType ) : void 1.2.0
Sets the node application data content and content type.
-
content : String
node content data
-
contentType : String
node content type
-
content : String
-
setContent( String content, String contentType, String contentEncoding ) : void 1.2.0
Sets the node application data content, content type and encoding.
-
content : String
node content data
-
contentType : String
node content type
-
contentEncoding : String
node content encoding
-
content : String
-
getContentType( ) : String 1.2.0
Returns node application data content type
-
setContentType( String contentType ) : void 1.2.0
Sets the node application data content type.
-
contentType : String
node content type
-
contentType : String
-
getContentEncoding( ) : String 1.2.0
Returns node application data content encoding
-
setContentEncoding( String contentEncoding ) : void 1.2.0
Sets the node application data content encoding.
-
contentEncoding : String
node content encoding
-
contentEncoding : String
-
getApplicationData( ) : String 1.0.0 deprecated 1.2.0
Returns the node application data
-
setApplicationData( String applicationData ) : void 1.0.0 deprecated 1.2.0
Sets the node application data.
-
applicationData : String
node application data
-
applicationData : String
-
setApplicationData( String applicationData, String contentType ) : void 1.0.1 deprecated 1.2.0
Sets the node application data. The contentEncoding is set to base64
-
applicationData : String
node application data
-
contentType : String
node application data content type
-
applicationData : String
-
setApplicationData( String applicationData, Object attributes ) : void 1.0.1 deprecated 1.2.0
Sets the node application data. Additional data attributes can be set with attributes.
-
applicationData : String
node application data
-
attributes : Object
node application data additional attributes
Must be a key-value map
-
applicationData : String
-
getRawData( ) : Object 1.0.0
Returns a clone of the node internal current raw data.
-
getMasterRawData( ) : Object 1.0.0
Returns a clone of the node internal original raw data, as retrieved from the server when the node was loaded.
-
getEtag( ) : String 1.0.0
Returns the node ETag.
-
getLinks( IDNjs.LinkTypes linkType ) : IDNjs.Link[] 1.0.0
Returns the node links for the specified link type.
-
linkType : IDNjs.LinkTypes
type of link
-
linkType : IDNjs.LinkTypes
-
getLink( Number id, IDNjs.LinkTypes linkType ) : IDNjs.Link 1.0.0
Returns the node link for the specified link type and id.
-
id : Number
link id
-
linkType : IDNjs.LinkTypes
type of link
-
id : Number
-
getLink( String lri, IDNjs.LinkTypes linkType ) : IDNjs.Link 1.0.0
Returns the node link for the specified link type and target node LRI.
-
lri : String
link target node LRI
-
linkType : IDNjs.LinkTypes
type of link
-
lri : String
-
getLinkByName( String linkLocalName, IDNjs.LinkTypes linkType ) : IDNjs.Link 1.0.0
Returns the node link for the specified link type and link local name.
-
linkLocalName : String
link local name
-
linkType : IDNjs.LinkTypes
type of link
-
linkLocalName : String
-
removeLink( Number id, IDNjs.LinkTypes linkType ) : void 1.0.0
Remove the link for the specified link type and id from node.
-
id : Number
link id
-
linkType : IDNjs.LinkTypes
type of link
-
id : Number
-
removeLink( String lri, IDNjs.LinkTypes linkType ) : void 1.0.0
Remove the link for the specified link type and target node LRI from node.
-
lri : String
link target node LRI
-
linkType : IDNjs.LinkTypes
type of link
-
lri : String
-
removeLink( IDNjs.Link link, IDNjs.LinkTypes linkType ) : void 1.0.0
Remove the specified link from node.
-
link : IDNjs.Link
link
-
linkType : IDNjs.LinkTypes
type of link
-
link : IDNjs.Link
-
addLink( String lri, IDNjs.LinkTypes linkType ) : Link 1.0.0
Add a link of the specified type to the specified node.
-
lri : String
link target node lri
-
linkType : IDNjs.LinkTypes
type of link
-
lri : String
-
addLink( IDNjs.Node node, IDNjs.LinkTypes linkType ) : Link 1.0.0
Add a link of the specified type to the specified node. it also sets the link local name same as node local name
-
node : IDNjs.Node
link target node
-
linkType : IDNjs.LinkTypes
type of link
-
node : IDNjs.Node
IDNjs.Link Class
-
Link( String lri ) 1.0.0
Constructor
-
lri : String
target node LRI
-
lri : String
-
Link( String lri, String localName ) 1.0.0
Constructor
-
lri : String
target node LRI
-
localName : String
link local name
-
lri : String
-
getLRI( ) : String 1.0.0
Returns the target node LRI
-
setLRI( String lri ) : void 1.0.0
Sets the target node LRI.
-
lri : String
target node LRI
-
lri : String
-
getRawData( ) : Object 1.0.0
Returns a clone of the link internal current raw data.
-
getId( ) : Number 1.0.0
Returns the link id.
-
getLocalName( ) : String 1.0.0
Returns link local name
-
setLocalName( String localName ) : void 1.0.0
Sets the link local name.
-
localName : String
link local name
-
localName : String
-
isBlank( ) : Boolean 1.0.0
Returns TRUE if the link is empty
-
setBlank( ) : void 1.0.0
Empty this link.
IDNjs.LinkTypes Enum
-
AGGREGATION 1.0.0
-
REFERENCE 1.0.0
-
BACKLINK 1.0.0
-
INCOMING_CHANGE 1.0.0