filenet.vw.api
Class VWTableDefinition
- java.lang.Object
-
- filenet.vw.api.VWTableDefinition
-
- All Implemented Interfaces:
- IVWTableDefinition, java.io.Serializable, java.lang.Cloneable
- Direct Known Subclasses:
- VWLogDefinition, VWQueueDefinition, VWRosterDefinition
public abstract class VWTableDefinition extends java.lang.Object implements IVWTableDefinition, java.io.Serializable, java.lang.Cloneable
Defines database tables for use with queues, rosters, and logs.Methods for Managing User and Group Access Control The following methods in the WQueueDefinition and VWRosterDefinition classes set read and write access permissions for users and groups, using VWParticipant objects:
- setReadSecurityPx(VWParticipant[])
- setWriteSecurityPx(VWParticipant[])
- VWParticipant[]
VWTableDefinition.getReadSecurityPx() - VWParticipant[]
VWTableDefinition.getWriteSecurityPx()
- setReadSecurity(String[])
- setWriteSecurity(String[])
- String[]
VWTableDefinition.getReadSecurity() - String[]
VWTableDefinition.getWriteSecurity()
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field and Description static intCONFIG_TYPE_LOGValue of 3. This constant indicates a log configuration type.static intCONFIG_TYPE_QUEUEValue of 2. This constant indicates a queue configuration type.static intCONFIG_TYPE_ROSTERValue of 1. This constant indicates a roster configuration type.static java.lang.StringIWFCaseFolderstatic java.lang.StringIWFCaseTaskstatic intLVALUEValue of 0. This constant can be used to subscript into the pre or post assignment arrays.static intRVALUEValue of 1. This constant can be used to subscript into the pre or post assignment arrays.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method and Description java.lang.Objectclone()Creates a clone of thisVWTableDefinitionobject.VWExposedFieldDefinitioncreateFieldDefinition(java.lang.String theName, int theType, int theLength)Create an exposed field by input of a field name and data type.abstract VWIndexDefinitioncreateIndexDefinition(java.lang.String theName, java.lang.String[] theFieldNames)Creates an index definition for one of following table types: log, queue, or roster.voiddeleteFieldDefinition(java.lang.String theName)Delete an exposed field from one of the following: log, queue, or roster.voiddeleteIndexDefinition(java.lang.String theName)Delete an index from one of the following: log, queue, or roster.java.lang.StringgetDescription()Get the description for this table definition.VWExposedFieldDefinition[]getFields()Get an array of exposed field definitions for this table definition.VWIndexDefinition[]getIndexes()Gets an array of index definitions for one of the following table types: log, queue, or roster.static java.lang.StringgetLocalizedString(int theConfigType)Gets a localized string representation of the config type (roster, queue, or log).java.lang.StringgetName()Gets the name for one of the following: log, queue, or roster.java.lang.String[]getReadSecurity()Returns a String array of users and/or groups who have read access.VWParticipant[]getReadSecurityPx()Returns an array of VWParticipant objects that specifies users and/or groups who have read access.intgetServerId()Get the server ID location for one of the following: log, queue, or roster.java.lang.String[]getWriteSecurity()Returns a String array of users and/or groups who have write access.VWParticipant[]getWriteSecurityPx()Returns an array of VWParticipant objects that specifies users and/or groups who have write access.booleanhasFieldName(java.lang.String fieldName)Determine whether a specified log, queue, or roster field exists.static booleanisValid(int theConfigType)Validates the config type (a process engine table type) as a valid type.static VWExposedFieldDefinition[]optionalSystemFields(int theType)Gets optional exposed workflow system fields of type roster, queue, or log.voidsetDescription(java.lang.String theDescription)Set the description for this table definition.voidsetServerId(int theNewServerId)Set the server ID location for one of the following: log, queue, or roster.java.lang.StringtoString()Get the string version of the table definition.
-
-
-
Field Detail
-
LVALUE
public static final int LVALUE
Value of 0. This constant can be used to subscript into the pre or post assignment arrays.- See Also:
- Constant Field Values
-
RVALUE
public static final int RVALUE
Value of 1. This constant can be used to subscript into the pre or post assignment arrays.- See Also:
- Constant Field Values
-
IWFCaseFolder
public static final java.lang.String IWFCaseFolder
- See Also:
- Constant Field Values
-
IWFCaseTask
public static final java.lang.String IWFCaseTask
- See Also:
- Constant Field Values
-
CONFIG_TYPE_ROSTER
public static final int CONFIG_TYPE_ROSTER
Value of 1. This constant indicates a roster configuration type.- See Also:
- Constant Field Values
-
CONFIG_TYPE_QUEUE
public static final int CONFIG_TYPE_QUEUE
Value of 2. This constant indicates a queue configuration type.- See Also:
- Constant Field Values
-
CONFIG_TYPE_LOG
public static final int CONFIG_TYPE_LOG
Value of 3. This constant indicates a log configuration type.- See Also:
- Constant Field Values
-
-
Method Detail
-
createFieldDefinition
public VWExposedFieldDefinition createFieldDefinition(java.lang.String theName, int theType, int theLength) throws VWException
Create an exposed field by input of a field name and data type. Use the exposed field to create index definitions.- Specified by:
createFieldDefinitionin interfaceIVWTableDefinition- Parameters:
theName- Name of the exposed field
An exposed field name:- Must be alphanumeric (an underscore is acceptable anywhere after the first letter in the name).
- May begin with F_ (to allow the user to expose a system field)
theType- Integer value that represents the type of the data, as follows:
Arrays of any of these types are not acceptable.Value Data type 1 VWFieldType.FIELD_TYPE_INT2 VWFieldType.FIELD_TYPE_STRING4 VWFieldType.FIELD_TYPE_BOOLEAN8 VWFieldType.FIELD_TYPE_FLOAT16 VWFieldType.FIELD_TYPE_TIMEtheLength- If the data type is String, this is the number of bytes (length) of data stored; otherwise, for all other data types, this is zero (0).- Returns:
- A VWExposedFieldDefinition object for one of the following: log, queue, or roster.
- Throws:
VWException
-
deleteFieldDefinition
public void deleteFieldDefinition(java.lang.String theName) throws VWExceptionDelete an exposed field from one of the following: log, queue, or roster.- Specified by:
deleteFieldDefinitionin interfaceIVWTableDefinition- Parameters:
theName- Name of the exposed field to be deleted from the log, queue, or roster- Throws:
VWException- Thrown whenever the system does not find the name.
-
createIndexDefinition
public abstract VWIndexDefinition createIndexDefinition(java.lang.String theName, java.lang.String[] theFieldNames) throws VWException
Creates an index definition for one of following table types: log, queue, or roster.- Specified by:
createIndexDefinitionin interfaceIVWTableDefinition- Parameters:
theName- The name of the index, specified as follows:- Alphanumeric
- Does not start with underscore ("_") or "F_"
theFieldNames- An array of exposed field names (either system or user exposed). At least one field name is required. Additional array members will result in a concatenated index.- Returns:
- A VWIndexDefinition object for the index definition created.
- Throws:
VWException- Causes include:- Error in name specification.
- Undefined field names in input.
-
deleteIndexDefinition
public void deleteIndexDefinition(java.lang.String theName) throws VWExceptionDelete an index from one of the following: log, queue, or roster.- Specified by:
deleteIndexDefinitionin interfaceIVWTableDefinition- Parameters:
theName- Name of the index to be deleted from the log, queue, or roster- Throws:
VWException- Thrown whenever the system does not find the index.
-
getFields
public VWExposedFieldDefinition[] getFields() throws VWException
Get an array of exposed field definitions for this table definition.- Specified by:
getFieldsin interfaceIVWTableDefinition- Returns:
- Array of exposed field definitions
Null if there is no exposed field definition - Throws:
VWException
-
getIndexes
public VWIndexDefinition[] getIndexes() throws VWException
Gets an array of index definitions for one of the following table types: log, queue, or roster.- Specified by:
getIndexesin interfaceIVWTableDefinition- Returns:
- An array of the VWIndexDefinition objects, or null if no index field definition is found.
- Throws:
VWException
-
getName
public java.lang.String getName()
Gets the name for one of the following: log, queue, or roster. If a translation source exists, the authored name is translated.Note: The translation is done only at runtime, so will not appear in design-time applications (such as the Process Designer or Configuration Console).
- Specified by:
getNamein interfaceIVWTableDefinition- Returns:
- A String containing the translated name of the log, queue, or roster, if a translation source exists; otherwise the authored name is returned.
-
getReadSecurity
public java.lang.String[] getReadSecurity()
Returns a String array of users and/or groups who have read access.- Returns:
- readSecurity Array of users and/or groups who have read access
-
getReadSecurityPx
public VWParticipant[] getReadSecurityPx() throws VWException
Returns an array of VWParticipant objects that specifies users and/or groups who have read access.- Returns:
- readSecurity Array of users and/or groups who have read access.
- Throws:
VWException
-
getServerId
public int getServerId()
Get the server ID location for one of the following: log, queue, or roster.- Returns:
- the server id
-
setServerId
public void setServerId(int theNewServerId) throws VWExceptionSet the server ID location for one of the following: log, queue, or roster. The system validates the server ID only upon transfer of the information to the VWService.- Parameters:
theNewServerId- New server ID- Throws:
VWException- Thrown if theNewServerId input is invalid.
-
getWriteSecurity
public java.lang.String[] getWriteSecurity()
Returns a String array of users and/or groups who have write access.- Returns:
- An array of users and/or groups who have write access to this log definition.
-
getWriteSecurityPx
public VWParticipant[] getWriteSecurityPx() throws VWException
Returns an array of VWParticipant objects that specifies users and/or groups who have write access.- Returns:
- An array of VWParticipant of users and/or groups who have write access.
- Throws:
VWException
-
getDescription
public java.lang.String getDescription()
Get the description for this table definition.- Specified by:
getDescriptionin interfaceIVWTableDefinition- Returns:
- Description for this table definition
-
setDescription
public void setDescription(java.lang.String theDescription)
Set the description for this table definition.- Specified by:
setDescriptionin interfaceIVWTableDefinition- Parameters:
theDescription- Description for this table definition
-
toString
public java.lang.String toString()
Get the string version of the table definition.- Specified by:
toStringin interfaceIVWTableDefinition- Overrides:
toStringin classjava.lang.Object- Returns:
- Table name
-
optionalSystemFields
public static VWExposedFieldDefinition[] optionalSystemFields(int theType) throws VWException
Gets optional exposed workflow system fields of type roster, queue, or log. These system fields are not required.- Parameters:
theType- Type of collection on which the optional system field is exposed, as follows:- IVWCommandServer.QUERYTYPE_LOG
- IVWCommandServer.QUERYTYPE_QUEUE
- IVWCommandServer.QUERYTYPE_ROSTER
- Returns:
- Exposed field definitions of optional workflow system fields
- Throws:
VWException
-
hasFieldName
public boolean hasFieldName(java.lang.String fieldName) throws VWExceptionDetermine whether a specified log, queue, or roster field exists.- Parameters:
fieldName- Name of the log, queue, or roster field- Returns:
- True if the data field exists
- Throws:
VWException- Thrown if the field name parameter is null.
-
clone
public java.lang.Object clone()
Creates a clone of thisVWTableDefinitionobject.- Overrides:
clonein classjava.lang.Object- Returns:
- A clone of this instance.
-
getLocalizedString
public static java.lang.String getLocalizedString(int theConfigType) throws VWExceptionGets a localized string representation of the config type (roster, queue, or log).- Parameters:
theConfigType- An integer value associated with the config type.- Returns:
- The localized version of the config type.
- Throws:
VWException- Thrown if the config type value specified in the theConfigType parameter is invalid.
-
isValid
public static boolean isValid(int theConfigType)
Validates the config type (a process engine table type) as a valid type.- Parameters:
theConfigType- The integer value associated with the config type (roster, queue, or log) to be validated.- Returns:
trueif the config type value specified in the theConfigType parameter is valid; otherwise, this method returnsfalse.
-
-