Class RemoteThingWithTunnelsAndFileTransfer

All Implemented Interfaces:
ISupportsAccessModifier, IConfigurableObject, INotScriptFriendly, IEndpointBindingObserver, ISupportsDeprecation, IDiffableObject, IAlertProvider, IAvatar, IEntityLifeCycleEvent, IEventMetadataProvider, IEventProvider, IPersistable, IPropertyProvider, IServiceMetadataProvider, IServiceProvider, IShapeProvider, ITaggableObject, IDependencyScannableObject, IImportDependencyHandler, IHierarchicalEntity, IEntityDefinition, IPersistableObject<String>, IDesignTimeSecurable, IDesignTimeSecurableEntity, IRunTimeSecurable, IRunTimeSecurableEntity, ISecurable, IVisibilitySecurable, IVisibilitySecurableEntity, IEventProcessor, IConnectedDevice, IAspectContainer, INamedObject, Serializable

@ThingworxExtensionApiClass(since={7,4}) public class RemoteThingWithTunnelsAndFileTransfer extends RemoteThingWithTunnels
See Also:
  • Constructor Details

  • Method Details

    • IsDerivedFromTemplate

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

      @ThingworxExtensionApiMethod(since={7,4}) public void StartFileTransfer(String tid, String path, String mode) throws Exception
      Parameters:
      tid - Transfer Id - STRING
      path - File path - STRING
      mode - Indicates if the file will be open in 'read' or 'write' mode - STRING
      Throws:
      Exception - If an error occurs
    • CompleteFileTransfer

      @ThingworxExtensionApiMethod(since={7,4}) public void CompleteFileTransfer(InfoTable job) throws Exception
      Parameters:
      job - The transfer job being completed - INFOTABLE
      Throws:
      Exception - If an error occurs
    • CancelFileTransfer

      @ThingworxExtensionApiMethod(since={7,4}) public void CancelFileTransfer(InfoTable job) throws Exception
      Parameters:
      job - The transfer job being completed - INFOTABLE
      Throws:
      Exception - If an error occurs
    • GetTransferInfo

      @ThingworxExtensionApiMethod(since={7,4}) public InfoTable GetTransferInfo() throws Exception
      Returns:
      result File Results - INFOTABLE - Aspects {dataShape:GetTransferInfoResult}
      Throws:
      Exception - If an error occurs
    • GetFileInfo

      @ThingworxExtensionApiMethod(since={7,4}) public InfoTable GetFileInfo(String path) throws Exception
      Service Category:
      FileTransfer
      Service Description:
      Get file info.
      Parameters:
      path - File path - STRING
      Returns:
      result File Results - INFOTABLE - Aspects {dataShape:FileSystemFile}
      Throws:
      Exception - If an error occurs
    • GetSupportedFileChecksumAlgorithms

      @ThingworxExtensionApiMethod(since={8,4}) public InfoTable GetSupportedFileChecksumAlgorithms() throws Exception
      Returns:
      result List of cryptographic algorithms this Thing supports for file transfers - INFOTABLE - Aspects {dataShape:ChecksumAlgorithmList}
      Throws:
      Exception - If an error occurs
    • GetFileChecksum

      @Deprecated @ThingworxExtensionApiMethod(since={7,4}, deprecatedSince={8,4,0}) public String GetFileChecksum(String path) throws Exception
      Deprecated.
      Throws:
      Exception - If an error occurs
    • GetFileChecksum

      @ThingworxExtensionApiMethod(since={8,4}) public String GetFileChecksum(String path, String checksumAlgorithm) throws Exception


      Gets the checksum of a file on this RemoteThing, using the cryptographic algorithm whose name was passed into the service as an argument. Supported checksum algorithms can be gotten using the GetSupportedChecksumAlgorithms service.
      Parameters:
      path - The path to the file to conduct a checksum on
      checksumAlgorithm - The name of the checksum algorithm to use
      Returns:
      The checksum of the indicated file
      Throws:
      Exception - Thrown if the cryptographic algorithm provided is invalid or is not recognized by the server
    • BrowseFileSystem

      @ThingworxExtensionApiMethod(since={7,4}) public InfoTable BrowseFileSystem(String path) throws Exception
      Service Category:
      FileTransfer
      Service Description:
      Get a list of files and/or directories on the Edge Thing.
      Parameters:
      path - Directory path - STRING
      Returns:
      result Browse Results - INFOTABLE - Aspects {dataShape:FileSystemFile}
      Throws:
      Exception - If an error occurs
    • BrowseDirectory

      @ThingworxExtensionApiMethod(since={7,4}) public InfoTable BrowseDirectory(String path) throws Exception
      Service Category:
      FileTransfer
      Service Description:
      Get a list of files and/or directories on the Edge Thing.
      Parameters:
      path - Directory path - STRING
      Returns:
      result Browse Results - INFOTABLE - Aspects {dataShape:FileSystemFile}
      Throws:
      Exception - If an error occurs
    • GetFileListing

      @ThingworxExtensionApiMethod(since={7,4}) public InfoTable GetFileListing(String path, String nameMask) throws Exception
      Service Category:
      FileTransfer
      Service Description:
      Get file system listing.
      Parameters:
      path - Directory path - STRING
      nameMask - Name mask - STRING
      Returns:
      result File Results - INFOTABLE - Aspects {dataShape:FileSystemFile}
      Throws:
      Exception - If an error occurs
    • ListFiles

      @ThingworxExtensionApiMethod(since={7,4}) public InfoTable ListFiles(String path, String nameMask) throws Exception
      Service Category:
      FileTransfer
      Service Description:
      Get file system listing.
      Parameters:
      path - Directory path - STRING
      nameMask - Name mask - STRING
      Returns:
      result File Results - INFOTABLE - Aspects {dataShape:FileSystemFile}
      Throws:
      Exception - If an error occurs
    • ListDirectories

      @ThingworxExtensionApiMethod(since={7,4}) public InfoTable ListDirectories(String path) throws Exception
      Service Category:
      FileTransfer
      Service Description:
      Get listing of directories.
      Parameters:
      path - Directory path - STRING
      Returns:
      result File Results - INFOTABLE - Aspects {dataShape:FileSystemDirectory}
      Throws:
      Exception - If an error occurs
    • CreateBinaryFile

      @ThingworxExtensionApiMethod(since={7,4}) public void CreateBinaryFile(String path, byte[] data, Boolean overwrite) throws Exception
      Parameters:
      path - File path - STRING
      data - The data to write to the file - BLOB
      overwrite - Overwrite the file if it already exists - BOOLEAN
      Throws:
      Exception - If an error occurs
    • ReadFromBinaryFile

      @ThingworxExtensionApiMethod(since={7,4}) public InfoTable ReadFromBinaryFile(String path, Double offset, Integer count) throws Exception
      Parameters:
      path - File path - STRING
      offset - File offset in bytes - NUMBER
      count - Number of bytes to read - INTEGER
      Returns:
      result File Read Results - INFOTABLE - Aspects {dataShape:ReadFromBinaryFileResult}
      Throws:
      Exception - If an error occurs
    • WriteToBinaryFile

      @ThingworxExtensionApiMethod(since={7,4}) public void WriteToBinaryFile(String path, Double offset, byte[] data) throws Exception
      Parameters:
      path - File path - STRING
      offset - File offset in bytes - NUMBER
      data - Initial data - BLOB
      Throws:
      Exception - If an error occurs
    • AppendToBinaryFile

      @ThingworxExtensionApiMethod(since={7,4}) public void AppendToBinaryFile(String path, byte[] data) throws Exception
      Parameters:
      path - File path - STRING
      data - Initial data - BLOB
      Throws:
      Exception - If an error occurs
    • MoveFile

      @ThingworxExtensionApiMethod(since={7,4}) public void MoveFile(String sourcePath, String targetPath, Boolean overwrite) throws Exception
      Service Category:
      FileSystemServices
      Service Description:
      Move a file.
      Parameters:
      sourcePath - Path of file to move - STRING
      targetPath - Target path - STRING
      overwrite - Overwrite existing file - BOOLEAN
      Throws:
      Exception - If an error occurs
    • DeleteFile

      @ThingworxExtensionApiMethod(since={7,4}) public void DeleteFile(String path) throws Exception
      Service Category:
      FileSystemServices
      Service Description:
      Delete a file.
      Parameters:
      path - File path - STRING
      Throws:
      Exception - If an error occurs
    • GetDirectoryStructure

      @ThingworxExtensionApiMethod(since={7,4}) public InfoTable GetDirectoryStructure() throws Exception
      Service Category:
      FileTransfer
      Service Description:
      Get directory structure.
      Returns:
      result The directory structure at the edge - INFOTABLE - Aspects {dataShape:FileSystemDirectory}
      Throws:
      Exception - If an error occurs
    • ValidateFileTransfer

      @ThingworxExtensionApiMethod(since={7,4}) public void ValidateFileTransfer(String sid, String toUri, String fromUri, String md5) throws Exception
      Service Category:
      FileTransfer
      Service Description:
      validate the file transfer based on the validation signature.
      Parameters:
      sid - File transfer Job ID - STRING
      toUri - File destination uri - STRING
      fromUri - File source uri - STRING
      md5 - Checksum signature used for validation - STRING
      Throws:
      Exception - If an error occurs