org.xcmis.spi.model
Class TypeDefinition

java.lang.Object
  extended by org.xcmis.spi.model.TypeDefinition

public class TypeDefinition
extends Object

Version:
$Id: $
Author:
Andrey Parfonov

Constructor Summary
TypeDefinition()
           
TypeDefinition(String id, BaseType baseId, String queryName, String localName, String localNamespace, String parentId, String displayName, String description, boolean creatable, boolean fileable, boolean queryable, boolean fulltextIndexed, boolean includedInSupertypeQuery, boolean controllablePolicy, boolean controllableACL, boolean versionable, String[] allowedSourceTypes, String[] allowedTargetTypes, ContentStreamAllowed contentStreamAllowed, Map<String,PropertyDefinition<?>> propertyDefinitions)
           
 
Method Summary
 String[] getAllowedSourceTypes()
          Set of allowed type to be source of relationship.
 String[] getAllowedTargetTypes()
          Set of allowed type to be target of relationship.
 BaseType getBaseId()
          Base type ID.
 ContentStreamAllowed getContentStreamAllowed()
          Indicates is content stream allowed or not allowed or needed for this type.
 String getDescription()
          Optional type description.
 String getDisplayName()
          Optional type display name.
 String getId()
          Type unique identifier.
 String getLocalName()
          Local (internal) type name.
 String getLocalNamespace()
          Local (internal) name-space for type.
 String getParentId()
          Parent type ID.
 PropertyDefinition<?> getPropertyDefinition(String id)
          Get PropertyDefinition by ID.
 Collection<PropertyDefinition<?>> getPropertyDefinitions()
           
 String getQueryName()
          Type Query name.
 boolean isControllableACL()
          Indicates can be CMIS ACL applied to object of this type.
 boolean isControllablePolicy()
          Indicates can be CMIS policies applied to object of this type.
 boolean isCreatable()
          Indicates is type creatable or not.
 boolean isFileable()
          Indicates is type is fileable or not.
 boolean isFulltextIndexed()
          Indicates can it be used in fulltext queries via SQL CONTAINS(...) clause.
 boolean isIncludedInSupertypeQuery()
          Indicates is type included in queries of super-types.
 boolean isQueryable()
          Is type queryable.
 boolean isVersionable()
          Indicate is this type versionable or not.
 void setAllowedSourceTypes(String[] allowedSourceTypes)
           
 void setAllowedTargetTypes(String[] allowedTargetTypes)
           
 void setBaseId(BaseType baseId)
           
 void setContentStreamAllowed(ContentStreamAllowed contentStreamAllowed)
           
 void setControllableACL(boolean controllableACL)
           
 void setControllablePolicy(boolean controllablePolicy)
           
 void setCreatable(boolean creatable)
           
 void setDescription(String description)
           
 void setDisplayName(String displayName)
           
 void setFileable(boolean fileable)
           
 void setFulltextIndexed(boolean fulltextIndexed)
           
 void setId(String id)
           
 void setIncludedInSupertypeQuery(boolean includedInSupertypeQuery)
           
 void setLocalName(String localName)
           
 void setLocalNamespace(String localNamespace)
           
 void setParentId(String parentId)
           
 void setPropertyDefinitions(Map<String,PropertyDefinition<?>> propertyDefinitions)
           
 void setQueryable(boolean queryable)
           
 void setQueryName(String queryName)
           
 void setVersionable(boolean versionable)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TypeDefinition

public TypeDefinition()

TypeDefinition

public TypeDefinition(String id,
                      BaseType baseId,
                      String queryName,
                      String localName,
                      String localNamespace,
                      String parentId,
                      String displayName,
                      String description,
                      boolean creatable,
                      boolean fileable,
                      boolean queryable,
                      boolean fulltextIndexed,
                      boolean includedInSupertypeQuery,
                      boolean controllablePolicy,
                      boolean controllableACL,
                      boolean versionable,
                      String[] allowedSourceTypes,
                      String[] allowedTargetTypes,
                      ContentStreamAllowed contentStreamAllowed,
                      Map<String,PropertyDefinition<?>> propertyDefinitions)
Method Detail

getId

public String getId()
Type unique identifier.

Returns:
type id

getBaseId

public BaseType getBaseId()
Base type ID.

Returns:
base type id
See Also:
BaseType

getQueryName

public String getQueryName()
Type Query name. It is used in SQL queries as table name.

Returns:
type query name

getLocalName

public String getLocalName()
Local (internal) type name.

Returns:
local type name

getLocalNamespace

public String getLocalNamespace()
Local (internal) name-space for type.

Returns:
local name-space for type

getParentId

public String getParentId()
Parent type ID. Must be null for root types.

Returns:
parent type id or null

getDisplayName

public String getDisplayName()
Optional type display name. It may be used in representation purposes.

Returns:
display name or null if not provided

getDescription

public String getDescription()
Optional type description.

Returns:
type description or null if not provided

isCreatable

public boolean isCreatable()
Indicates is type creatable or not. If type is not creatable then repository may contains the object of this type but it is not allowed create new objects of this type.

Returns:
true if creatable false otherwise

isFileable

public boolean isFileable()
Indicates is type is fileable or not. If type is fileable than it may child of Folder(s)

Returns:
true if fileable false otherwise

isQueryable

public boolean isQueryable()
Is type queryable. It indicates can it be used in FROM clause of SQL statement.

Returns:
true if type queryable false otherwise

isFulltextIndexed

public boolean isFulltextIndexed()
Indicates can it be used in fulltext queries via SQL CONTAINS(...) clause.

Returns:
true if type fulltextIndexed false otherwise

isIncludedInSupertypeQuery

public boolean isIncludedInSupertypeQuery()
Indicates is type included in queries of super-types.

Returns:
true if type included in super types queries false otherwise

isControllablePolicy

public boolean isControllablePolicy()
Indicates can be CMIS policies applied to object of this type.

Returns:
true if type controllable by policies false otherwise

isControllableACL

public boolean isControllableACL()
Indicates can be CMIS ACL applied to object of this type.

Returns:
true if type controllable by ACL false otherwise

getContentStreamAllowed

public ContentStreamAllowed getContentStreamAllowed()
Indicates is content stream allowed or not allowed or needed for this type. Must be ContentStreamAllowed.NOT_ALLOWED for type other then cmis:document.

Returns:
type content stream rules

getAllowedSourceTypes

public String[] getAllowedSourceTypes()
Set of allowed type to be source of relationship. There is not sense of this attribute for types other then cmis:relationship and method should return null. For relationship null minds there is no any restriction for source types.

Returns:
set of allowed source type or null

getAllowedTargetTypes

public String[] getAllowedTargetTypes()
Set of allowed type to be target of relationship. There is not sense of this attribute for types other then cmis:relationship and method should return null. For relationship null minds there is no any restriction for target types.

Returns:
set of allowed source type or null

isVersionable

public boolean isVersionable()
Indicate is this type versionable or not.

Returns:
true if type versionable false otherwise

getPropertyDefinitions

public Collection<PropertyDefinition<?>> getPropertyDefinitions()
Returns:
property definitions or null if type was retrieved with parameter 'includePropertyDefintions' as false, see Connection.getTypeDefinition(String, boolean)

getPropertyDefinition

public PropertyDefinition<?> getPropertyDefinition(String id)
Get PropertyDefinition by ID.

Parameters:
id - property definition id
Returns:
property definition or null if type was retrieved with parameter 'includePropertyDefintions' as false, see Connection.getTypeDefinition(String, boolean) or if property definition with specified ID does not exist.

setId

public void setId(String id)

setBaseId

public void setBaseId(BaseType baseId)

setQueryName

public void setQueryName(String queryName)

setLocalName

public void setLocalName(String localName)

setLocalNamespace

public void setLocalNamespace(String localNamespace)

setParentId

public void setParentId(String parentId)

setDisplayName

public void setDisplayName(String displayName)

setDescription

public void setDescription(String description)

setCreatable

public void setCreatable(boolean creatable)

setFileable

public void setFileable(boolean fileable)

setQueryable

public void setQueryable(boolean queryable)

setFulltextIndexed

public void setFulltextIndexed(boolean fulltextIndexed)

setIncludedInSupertypeQuery

public void setIncludedInSupertypeQuery(boolean includedInSupertypeQuery)

setControllablePolicy

public void setControllablePolicy(boolean controllablePolicy)

setControllableACL

public void setControllableACL(boolean controllableACL)

setVersionable

public void setVersionable(boolean versionable)

setAllowedSourceTypes

public void setAllowedSourceTypes(String[] allowedSourceTypes)

setAllowedTargetTypes

public void setAllowedTargetTypes(String[] allowedTargetTypes)

setContentStreamAllowed

public void setContentStreamAllowed(ContentStreamAllowed contentStreamAllowed)

setPropertyDefinitions

public void setPropertyDefinitions(Map<String,PropertyDefinition<?>> propertyDefinitions)


Copyright © 2011 eXo Platform SAS. All Rights Reserved.