Class Vocabulary

All Implemented Interfaces:
IConfigurableObject, INotScriptFriendly, ISupportsDeprecation, IDiffableObject, IAvatar, IEntityLifeCycleEvent, IPersistable, IServiceProvider, ITaggableObject, IDependencyScannableObject, IEntityDefinition, IPersistableObject<String>, IDesignTimeSecurable, IDesignTimeSecurableEntity, IRunTimeSecurable, IRunTimeSecurableEntity, ISecurable, IVisibilitySecurable, IVisibilitySecurableEntity, IAspectContainer, INamedObject, Serializable

@ThingworxExtensionApiClass(since={6,6}) public class Vocabulary extends ServiceProviderEntity
See Also:
  • Field Details

    • KEY_FIELD

      public static final String KEY_FIELD
      See Also:
    • SYSTEM_OBJECTS_VOCABULARY_NAME

      public static final String SYSTEM_OBJECTS_VOCABULARY_NAME
      A very special name identifying the Vocabulary used to categorize all out-of-the-box ThingWorx System Objects. See the VocabularyTerm.SystemObjectsVocabularyTerm class for more information.
      See Also:
  • Constructor Details

  • Method Details

    • getVocabularyType

    • setVocabularyType

    • AddVocabularyTerm

      @ThingworxExtensionApiMethod(since={6,6}) public void AddVocabularyTerm(String term) throws Exception
      Service Category:
      Terms
      Service Description:
      Add a new vocabulary term.
      Parameters:
      term - Vocabulary Term - STRING
      Throws:
      Exception - if an error occurs
    • DeleteVocabularyTerm

      @ThingworxExtensionApiMethod(since={6,6}) public void DeleteVocabularyTerm(String term) throws Exception
      Service Category:
      Terms
      Service Description:
      Delete a specific vocabulary term.
      Parameters:
      term - Vocabulary Term - STRING
      Throws:
      Exception - if an error occurs
    • GetVocabularyTerms

      @ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetVocabularyTerms() throws Exception
      Service Category:
      Queries
      Service Description:
      Return a list of vocabulary terms.
      Returns:
      result Vocabulary Terms - INFOTABLE - Aspects {dataShape:VocabularyTerm}
      Throws:
      Exception - if an error occurs
    • GetVocabularyTerm

      @ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetVocabularyTerm(String name) throws Exception
      Service Category:
      Terms
      Service Description:
      Return a specific vocabulary term.
      Parameters:
      name - Vocabulary term - STRING
      Returns:
      result Vocabulary Terms - INFOTABLE - Aspects {dataShape:VocabularyTerm}
      Throws:
      Exception - if an error occurs
    • GetVocabularyTermUsage

      @ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetVocabularyTermUsage(Double maxItems) throws Exception
      Service Category:
      Queries
      Service Description:
      Return a list of vocabulary terms and their usage/frequency.
      Parameters:
      maxItems - Maximum number of items to return - NUMBER
      Returns:
      result Vocabulary Term Usage - INFOTABLE - Aspects {dataShape:VocabularyTermUsage}
      Throws:
      Exception - if an error occurs
    • GetVocabularyTermLinks

      @ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetVocabularyTermLinks(String term, Double maxItems) throws Exception
      Service Category:
      Queries
      Service Description:
      Return a list of entities linked to this vocabulary term.
      Parameters:
      term - Term to match - STRING
      maxItems - Maximum number of items to return - NUMBER
      Returns:
      result Vocabulary Term Links - INFOTABLE - Aspects {dataShape:EntityDescriptor}
      Throws:
      Exception - if an error occurs
    • IsDynamic

      @ThingworxExtensionApiMethod(since={6,6}) public Boolean IsDynamic() throws Exception
      Service Category:
      Metadata
      Service Description:
      Whether the vocabulary is dynamic or not.
      Returns:
      IsDynamic Is dynamic vocabulary indicator - BOOLEAN
      Throws:
      Exception - if an error occurs
    • GetVocabularyLinks

      @ThingworxExtensionApiMethod(since={6,6}) public InfoTable GetVocabularyLinks(Double maxItems) throws Exception
      Service Category:
      Queries
      Service Description:
      Return a list of entities linked to this vocabulary.
      Parameters:
      maxItems - Maximum number of items to return - NUMBER
      Returns:
      result Vocabulary Links - INFOTABLE - Aspects {dataShape:EntityDescriptor}
      Throws:
      Exception - if an error occurs
    • QueryVocabularyTerms

      @ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryVocabularyTerms(String filter, Double maxItems) throws Exception
      Service Category:
      Queries
      Service Description:
      Return a list of vocabulary terms.
      Parameters:
      filter - Term filter - STRING
      maxItems - Maximum number of items to return - NUMBER
      Returns:
      result Vocabulary Terms - INFOTABLE - Aspects {dataShape:VocabularyTerm}
      Throws:
      Exception - if an error occurs
    • QueryVocabularyTermUsage

      @ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryVocabularyTermUsage(String filter, Double maxItems) throws Exception
      Service Category:
      Queries
      Service Description:
      Return a list of vocabulary terms and their usage/frequency.
      Parameters:
      filter - Term filter - STRING
      maxItems - Maximum number of items to return - NUMBER
      Returns:
      result Vocabulary Term Usage - INFOTABLE - Aspects {dataShape:VocabularyTermUsage}
      Throws:
      Exception - if an error occurs
    • QueryVocabularyTermLinks

      @ThingworxExtensionApiMethod(since={6,6}) public InfoTable QueryVocabularyTermLinks(String term, org.json.JSONObject types, String filter, Double maxItems) throws Exception
      Service Category:
      Queries
      Service Description:
      Return a list of entities linked to this vocabulary term.
      Parameters:
      term - Term to match - STRING
      types - Entity types - JSON
      filter - Term filter - STRING
      maxItems - Maximum number of items to return - NUMBER
      Returns:
      result Vocabulary Term Links - INFOTABLE - Aspects {dataShape:EntityDescriptor}
      Throws:
      Exception - if an error occurs
    • getEntityType

      Description copied from class: RootEntity

      Returns the type of this entity.

      Specified by:
      getEntityType in class RootEntity
      Returns:
      the entity type