Class CollectionsServices

    • Constructor Detail

      • CollectionsServices

        public CollectionsServices()
    • Method Detail

      • AddCollectionRunTimePermission

        @ThingworxExtensionApiMethod(since={6,6})
        public void AddCollectionRunTimePermission​(java.lang.String collectionName,
                                                   java.lang.String type,
                                                   java.lang.String resource,
                                                   java.lang.String principal,
                                                   java.lang.String principalType,
                                                   java.lang.Boolean allow)
                                            throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Add a run time permission.
        Parameters:
        collectionName - Collection name (Things, Users, ThingShapes, etc.) - STRING
        type - Permission type (PropertyRead PropertyWrite ServiceInvoke EventInvoke EventSubscribe) - STRING
        resource - Resource name (* = all or enter a specific resource to override) - STRING
        principal - Principal name (name of user or group) - STRING
        principalType - Principal type (User or Group) - STRING
        allow - Permission (true = allow, false = deny) - BOOLEAN
        Throws:
        java.lang.Exception - If an error occurs
      • DeleteCollectionRunTimePermission

        @ThingworxExtensionApiMethod(since={6,6})
        public void DeleteCollectionRunTimePermission​(java.lang.String collectionName,
                                                      java.lang.String type,
                                                      java.lang.String resource,
                                                      java.lang.String principal,
                                                      java.lang.String principalType)
                                               throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Delete a run time permission.
        Parameters:
        collectionName - Collection name (Things, Users, ThingShapes, etc.) - STRING
        type - Permission type - STRING
        resource - Resource name - STRING
        principal - Principal name (name of user or group) - STRING
        principalType - Principal type (User or Group) - STRING
        Throws:
        java.lang.Exception - If an error occurs
      • GetCollectionRunTimePermissions

        @ThingworxExtensionApiMethod(since={6,6})
        public InfoTable GetCollectionRunTimePermissions​(java.lang.String collectionName)
                                                  throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Get a list of assigned runtime permissions.
        Parameters:
        collectionName - Collection name (Things, Users, ThingShapes, etc.) - STRING
        Returns:
        result Permission list - INFOTABLE - Aspects {dataShape:Permissions}
        Throws:
        java.lang.Exception - If an error occurs
      • AddCollectionDesignTimePermission

        @ThingworxExtensionApiMethod(since={6,6})
        public void AddCollectionDesignTimePermission​(java.lang.String collectionName,
                                                      java.lang.String type,
                                                      java.lang.String principal,
                                                      java.lang.String principalType,
                                                      java.lang.Boolean allow)
                                               throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Add a design time permission.
        Parameters:
        collectionName - Collection name (Things, Users, ThingShapes, etc.) - STRING
        type - Permission type (Create, Read, Update and Delete) - STRING
        principal - Principal name (name of user or group) - STRING
        principalType - Principal type (User or Group) - STRING
        allow - Permission (true = allow, false = deny) - BOOLEAN
        Throws:
        java.lang.Exception - If an error occurs
      • DeleteCollectionDesignTimePermission

        @ThingworxExtensionApiMethod(since={6,6})
        public void DeleteCollectionDesignTimePermission​(java.lang.String collectionName,
                                                         java.lang.String type,
                                                         java.lang.String principal,
                                                         java.lang.String principalType)
                                                  throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Delete a design time permission.
        Parameters:
        collectionName - Collection name (Things, Users, ThingShapes, etc.) - STRING
        type - Permission type - STRING
        principal - Principal name (name of user or group) - STRING
        principalType - Principal type (User or Group) - STRING
        Throws:
        java.lang.Exception - If an error occurs
      • GetCollectionDesignTimePermissions

        @ThingworxExtensionApiMethod(since={6,6})
        public InfoTable GetCollectionDesignTimePermissions​(java.lang.String collectionName)
                                                     throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Get a list of assigned design time permissions.
        Parameters:
        collectionName - Collection name (Things, Users, ThingShapes, etc.) - STRING
        Returns:
        result Permission list - INFOTABLE - Aspects {dataShape:Permissions}
        Throws:
        java.lang.Exception - If an error occurs
      • AddCollectionVisibilityPermission

        @ThingworxExtensionApiMethod(since={6,6})
        public void AddCollectionVisibilityPermission​(java.lang.String collectionName,
                                                      java.lang.String principal,
                                                      java.lang.String principalType)
                                               throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Add a visibility permission.
        Parameters:
        collectionName - Collection name (Things, Users, ThingShapes, etc.) - STRING
        principal - Principal name (name of organization or organization unit) - STRING
        principalType - Principal type (Organization or Organization Unit) - STRING
        Throws:
        java.lang.Exception - If an error occurs
      • DeleteCollectionVisibilityPermission

        @ThingworxExtensionApiMethod(since={6,6})
        public void DeleteCollectionVisibilityPermission​(java.lang.String collectionName,
                                                         java.lang.String principal,
                                                         java.lang.String principalType)
                                                  throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Delete a visibility permission.
        Parameters:
        collectionName - Collection name (Things, Users, ThingShapes, etc.) - STRING
        principal - Principal name (name of organization or organization unit) - STRING
        principalType - Principal type (Organization or Organization Unit) - STRING
        Throws:
        java.lang.Exception - If an error occurs
      • GetCollectionVisibilityPermissions

        @ThingworxExtensionApiMethod(since={6,6})
        public InfoTable GetCollectionVisibilityPermissions​(java.lang.String collectionName)
                                                     throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Get a list of assigned visibility permissions.
        Parameters:
        collectionName - Collection name (Things, Users, ThingShapes, etc.) - STRING
        Returns:
        result Permission list - INFOTABLE - Aspects {dataShape:Permissions}
        Throws:
        java.lang.Exception - If an error occurs
      • ExportUserPermissions

        @ThingworxExtensionApiMethod(since={7,1})
        public void ExportUserPermissions​(java.lang.String repositoryName,
                                          java.lang.String path,
                                          java.lang.String fileName,
                                          java.lang.Boolean includeCollectionPermissions,
                                          java.lang.Boolean includeEntityPermissions,
                                          TagCollection tags,
                                          java.lang.String projectName,
                                          java.lang.Boolean includeDependents)
                                   throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Export permissions for entities and collections.
        Parameters:
        repositoryName - File repository to which to export the permissions - THINGNAME
        path - Path to which to write the permissions - STRING
        fileName - Name of the file in which to write the permissions - STRING
        includeCollectionPermissions - Export the collection permissions - BOOLEAN
        includeEntityPermissions - Export the entity permissions - BOOLEAN
        tags - Tags (optional) - TAGS
        projectName - Project Name (optional) - PROJECTNAME
        includeDependents - Include dependent projects - BOOLEAN
        Throws:
        java.lang.Exception - If an error occurs
      • ImportUserPermissions

        @ThingworxExtensionApiMethod(since={7,1})
        public void ImportUserPermissions​(java.lang.String repositoryName,
                                          java.lang.String path,
                                          java.lang.String fileName)
                                   throws java.lang.Exception
        Service Category:
        Permissions
        Service Description:
        Import permissions for entities and collections.
        Parameters:
        repositoryName - File repository from which to import the permissions - THINGNAME
        path - Path from which to read the permissions - STRING
        fileName - Name of the file from which to read the permissions - STRING
        Throws:
        java.lang.Exception - If an error occurs