Class RemoteThingWithTunnels

    • Method Detail

      • IsDerivedFromTemplate

        @ThingworxExtensionApiMethod(since={7,4})
        public java.lang.Boolean IsDerivedFromTemplate​(java.lang.String thingTemplateName)
                                                throws java.lang.Exception
        Service Category:
        Metadata
        Service Description:
        Check to see if a thing is derived from a particular thing template.
        Overrides:
        IsDerivedFromTemplate in class Thing
        Parameters:
        thingTemplateName - Thing template name - THINGTEMPLATENAME
        Returns:
        result Is Derived From Template - BOOLEAN
        Throws:
        java.lang.Exception - If an error occurs
      • GetTunnelNames

        @ThingworxExtensionApiMethod(since={7,4})
        public InfoTable GetTunnelNames()
                                 throws java.lang.Exception
        Service Category:
        Tunneling
        Service Description:
        Get a list of Tunnels registered at the edge.
        Returns:
        result Tunnel names - INFOTABLE - Aspects {dataShape:EntityList}
        Throws:
        java.lang.Exception - If an error occurs
      • GetTunnelStatus

        @ThingworxExtensionApiMethod(since={7,4})
        public InfoTable GetTunnelStatus()
                                  throws java.lang.Exception
        Service Category:
        Tunneling
        Service Description:
        Get the tunnel status and access URL.
        Returns:
        result Tunnel status - INFOTABLE - Aspects {dataShape:TunnelStatus}
        Throws:
        java.lang.Exception - If an error occurs
      • GetTunnels

        @ThingworxExtensionApiMethod(since={7,4})
        public InfoTable GetTunnels()
                             throws java.lang.Exception
        Service Category:
        Tunneling
        Service Description:
        Get a list of Tunnel Endpoints registered at the edge.
        Returns:
        result List of registered tunnel endpoints - INFOTABLE - Aspects {dataShape:TunnelEndpoint}
        Throws:
        java.lang.Exception - If an error occurs
      • AddTunnel

        @ThingworxExtensionApiMethod(since={7,4})
        public void AddTunnel​(java.lang.String name,
                              java.lang.String host,
                              java.lang.Double port,
                              java.lang.String proto,
                              java.lang.Double numConnects,
                              java.lang.String description,
                              java.lang.String appUri)
                       throws java.lang.Exception
        Service Category:
        Tunneling
        Service Description:
        Register a new tunnel endpoint at the edge.
        Parameters:
        name - Name of the tunnel to add - STRING
        host - Host that the tunnel will connect to - STRING
        port - Port that the tunnel will connect to - NUMBER
        proto - Protocol used by the tunnel - STRING
        numConnects - The number of connections required to initilaize the tunnel - NUMBER
        description - Description of the tunnel - STRING
        appUri - Location of the client app that will use this tunnel - STRING
        Throws:
        java.lang.Exception - If an error occurs
      • RemoveTunnel

        @ThingworxExtensionApiMethod(since={7,4})
        public void RemoveTunnel​(java.lang.String name)
                          throws java.lang.Exception
        Service Category:
        Tunneling
        Service Description:
        Remove a tunnel endpoint from the edge.
        Parameters:
        name - Name of the tunnel to remove - STRING
        Throws:
        java.lang.Exception - If an error occurs
      • GetTunnel

        @ThingworxExtensionApiMethod(since={7,4})
        public InfoTable GetTunnel​(java.lang.String name)
                            throws java.lang.Exception
        Service Category:
        Tunneling
        Service Description:
        Get information about a specific tunnel endpoint registered at the edge.
        Parameters:
        name - Name of the tunnel to query - STRING
        Returns:
        result A tunnel endpoint - INFOTABLE - Aspects {dataShape:TunnelEndpoint}
        Throws:
        java.lang.Exception - If an error occurs
      • StartTunnel

        @ThingworxExtensionApiMethod(since={7,4})
        public void StartTunnel​(java.lang.String tid,
                                java.lang.String type,
                                java.lang.Integer chunksize,
                                java.lang.Integer idle_timeout,
                                java.lang.Integer read_timeout,
                                java.lang.Integer startup_timeout,
                                org.json.JSONObject connection)
                         throws java.lang.Exception
        Parameters:
        tid - Id of the tunnel - STRING
        type - Type of tunnel, tcp or udp - STRING
        chunksize - Max size of tunnel data to send - INTEGER
        idle_timeout - How long tunnel can remain idle before it will be closed - INTEGER
        read_timeout - Read timout on tunnel socket - INTEGER
        startup_timeout - Read timout on tunnel socket - INTEGER
        connection - The connection parameters - JSON
        Throws:
        java.lang.Exception - If an error occurs
      • CompleteTunnel

        @ThingworxExtensionApiMethod(since={7,4})
        public void CompleteTunnel​(java.lang.String tid,
                                   org.joda.time.DateTime start_time,
                                   org.joda.time.DateTime stop_time,
                                   java.lang.String peer_name,
                                   org.json.JSONObject connection)
                            throws java.lang.Exception
        Parameters:
        tid - Id of the tunnel - STRING
        start_time - Start time of the tunnel - DATETIME
        stop_time - Stop time of the tunnel - DATETIME
        peer_name - Name of the peer connected to this tunnel - STRING
        connection - The connection parameters - JSON
        Throws:
        java.lang.Exception - If an error occurs
      • TunnelCommandToEdge

        @ThingworxExtensionApiMethod(since={7,4})
        public void TunnelCommandToEdge​(java.lang.String tid,
                                        java.lang.String command)
                                 throws java.lang.Exception
        Parameters:
        tid - Id of the tunnel - STRING
        command - The command - STRING
        Throws:
        java.lang.Exception - If an error occurs
      • TunnelCommandFromEdge

        @ThingworxExtensionApiMethod(since={7,4})
        public void TunnelCommandFromEdge​(java.lang.String tid,
                                          java.lang.String command)
                                   throws java.lang.Exception
        Parameters:
        tid - Id of the tunnel - STRING
        command - The command - STRING
        Throws:
        java.lang.Exception - If an error occurs