Process API

filenet.vw.api
Class VWValidationError

java.lang.Object
  extended by filenet.vw.api.VWValidationError

public final class VWValidationError
extends java.lang.Object

Use this class to access information about errors encountered during the workflow definition validation process.

Since:
VWWS3.10

Field Summary
static int VALIDATION_LEVEL_ERROR
          Value of 1. Indicates that a validation error will either cause the transfer to fail or cause a problem at runtime.
static int VALIDATION_LEVEL_WARNING
          Value of 2. Indicates that a validation error may possibly either cause the transfer to fail or cause a problem at runtime.
static int VALIDATION_TYPE_ANNOTATION
          Integer value 12. Specifies that the validation item is a text annotation definition.
static int VALIDATION_TYPE_FIELD
          Integer value 4. Specifies that the validation item is a field.
static int VALIDATION_TYPE_INSTRUCTION
          Integer value 7. Specifies that the validation item is a instruction.
static int VALIDATION_TYPE_MILESTONE
          Integer value 8. Specifies that the validation item is a milestone.
static int VALIDATION_TYPE_PARAMETER
          Integer value 3. Specifies that the validation item is a parameter.
static int VALIDATION_TYPE_PARTNERLINK
          Integer value 10. Specifies that the validation item is a partnerlink.
static int VALIDATION_TYPE_ROUTE
          Integer value 2. Specifies that the validation item is a route.
static int VALIDATION_TYPE_RULESET
          Integer value 9. Specifies that the validation item is a ruleset.
static int VALIDATION_TYPE_SCHEMA
          Integer value 11. Specifies that the validation item is a schema definition.
static int VALIDATION_TYPE_STEP
          Value of 1.
static int VALIDATION_TYPE_WORKFLOW
          Integer value 6. Specifies that the validation item is a workflow.
static int VALIDATION_TYPE_WORKFLOW_COLLECTION
          Integer value 13. Specifies that the validation item is a workflow collection.
 
Method Summary
static java.lang.String _get_FILE_AUTHOR()
          For FileNet internal use only, do not call.
static java.lang.String _get_FILE_DATE()
          For FileNet internal use only, do not call.
static java.lang.String _get_FILE_REVISION()
          For FileNet internal use only, do not call.
 int getErrorType()
          Retrieves the value in the errorType property of this validation error.
 int getId()
          Deprecated. Replaced by getStepId(), VWMapDefinition.getMapId(), and getSubStepId() in combination. Gets the value in the ID property of this validation error.
 java.lang.String getInfo()
          Retrieves detailed information regarding the validation error, such as the name of a field or a parameter.
 int getLevel()
          Gets the value of the level property of the current validation error.
 java.lang.String getMapName()
          Gets the value in the map name property of this instance.
 java.lang.String getMessage()
          Retrieves the value in the message property of this validation error.
 java.lang.String getName()
          Gets the name of the object that contains the error.
 int getStepId()
          Gets an integer representing the step ID property of the current validation error.
 int getSubStepId()
          Gets an integer representing the ID property of the object that caused the current validation error within the current step.
 java.lang.String toString()
          Returns a String representing this instance.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

VALIDATION_TYPE_STEP

public static final int VALIDATION_TYPE_STEP
Value of 1. Specifies that the validation item is a step.

See Also:
Constant Field Values

VALIDATION_TYPE_ROUTE

public static final int VALIDATION_TYPE_ROUTE
Integer value 2. Specifies that the validation item is a route.

See Also:
Constant Field Values

VALIDATION_TYPE_PARAMETER

public static final int VALIDATION_TYPE_PARAMETER
Integer value 3. Specifies that the validation item is a parameter.

See Also:
Constant Field Values

VALIDATION_TYPE_FIELD

public static final int VALIDATION_TYPE_FIELD
Integer value 4. Specifies that the validation item is a field.

See Also:
Constant Field Values

VALIDATION_TYPE_WORKFLOW

public static final int VALIDATION_TYPE_WORKFLOW
Integer value 6. Specifies that the validation item is a workflow.

See Also:
Constant Field Values

VALIDATION_TYPE_INSTRUCTION

public static final int VALIDATION_TYPE_INSTRUCTION
Integer value 7. Specifies that the validation item is a instruction.

See Also:
Constant Field Values

VALIDATION_TYPE_MILESTONE

public static final int VALIDATION_TYPE_MILESTONE
Integer value 8. Specifies that the validation item is a milestone.

See Also:
Constant Field Values

VALIDATION_TYPE_RULESET

public static final int VALIDATION_TYPE_RULESET
Integer value 9. Specifies that the validation item is a ruleset.

See Also:
Constant Field Values

VALIDATION_TYPE_PARTNERLINK

public static final int VALIDATION_TYPE_PARTNERLINK
Integer value 10. Specifies that the validation item is a partnerlink.

See Also:
Constant Field Values

VALIDATION_TYPE_SCHEMA

public static final int VALIDATION_TYPE_SCHEMA
Integer value 11. Specifies that the validation item is a schema definition.

See Also:
Constant Field Values

VALIDATION_TYPE_ANNOTATION

public static final int VALIDATION_TYPE_ANNOTATION
Integer value 12. Specifies that the validation item is a text annotation definition.

See Also:
Constant Field Values

VALIDATION_TYPE_WORKFLOW_COLLECTION

public static final int VALIDATION_TYPE_WORKFLOW_COLLECTION
Integer value 13. Specifies that the validation item is a workflow collection.

See Also:
Constant Field Values

VALIDATION_LEVEL_ERROR

public static final int VALIDATION_LEVEL_ERROR
Value of 1. Indicates that a validation error will either cause the transfer to fail or cause a problem at runtime.

See Also:
Constant Field Values

VALIDATION_LEVEL_WARNING

public static final int VALIDATION_LEVEL_WARNING
Value of 2. Indicates that a validation error may possibly either cause the transfer to fail or cause a problem at runtime. Warnings will usually be issued in situations where the validation algorithm does not have enough information to decide that a potential problem will cause an error. For example, a call made to a map that does not exist in the referenced workflow will generate a warning rather than an error, because it may be that the map is defined (as an instruction sheet) on the server side in a base WorkClass. In this case, the transfer would succeed.

See Also:
Constant Field Values
Method Detail

_get_FILE_DATE

public static java.lang.String _get_FILE_DATE()
For FileNet internal use only, do not call.


_get_FILE_AUTHOR

public static java.lang.String _get_FILE_AUTHOR()
For FileNet internal use only, do not call.


_get_FILE_REVISION

public static java.lang.String _get_FILE_REVISION()
For FileNet internal use only, do not call.


getName

public java.lang.String getName()
Gets the name of the object that contains the error.

Returns:
A String containing the name of the object in which the error occured.

getInfo

public java.lang.String getInfo()
Retrieves detailed information regarding the validation error, such as the name of a field or a parameter.

Returns:
A String containing the detailed error information, or null if no error occured.

getMessage

public java.lang.String getMessage()
Retrieves the value in the message property of this validation error.

Returns:
A String containing the value in the message property of this validation error.

getErrorType

public int getErrorType()
Retrieves the value in the errorType property of this validation error.

Returns:
An integer representing the contents of the errorType property of this validation error.

getLevel

public int getLevel()
Gets the value of the level property of the current validation error.

Returns:
An integer representing either VALIDATION_LEVEL_ERROR (1) or VALIDATION_LEVEL_WARNING (2).
See Also:
VALIDATION_LEVEL_ERROR, VALIDATION_LEVEL_WARNING

getId

public int getId()
Deprecated. Replaced by getStepId(), VWMapDefinition.getMapId(), and getSubStepId() in combination. Gets the value in the ID property of this validation error.

Returns:
An integer value that represents the contents of the ID property of this validation error. For compatibility, this method returns a Step ID, but the use of sub-maps in the workflow definition means that a Step ID alone is no longer sufficient to locate the object causing a validation error.

Note An error in a simple step requires the Step ID and the Map ID; an error in a compound step instruction requires a Map ID, a Step ID, and a sub-step ID.

See Also:
getStepId(), VWMapDefinition.getMapId(), getSubStepId()

getMapName

public java.lang.String getMapName()
Gets the value in the map name property of this instance. The map name can be used to get the map that has the error.

Returns:
A String containing the map name property of this instance, or null if the error type is VALIDATION_TYPE_FIELD. A valid map name will be returned if the error type is one of the following:

getStepId

public int getStepId()
Gets an integer representing the step ID property of the current validation error. The Map ID will be required in order to locate the invalid step.

If the error type is VALIDATION_TYPE_ANNOTATION, this method will return the annotation id. The Map ID will be required in order to locate the invalid annotation.>/p>

Returns:
An integer representing the step ID property of this validation error. The error type values that can be returned are as follows:
  • 1: VALIDATION_TYPE_STEP
  • 2: VALIDATION_TYPE_ROUTE.
  • 3: VALIDATION_TYPE_PARAMETER
  • 7: VALIDATION_TYPE_INSTRUCTION
  • -1: Other (undefined)
See Also:
VWMapDefinition.getMapId(), getSubStepId()

getSubStepId

public int getSubStepId()
Gets an integer representing the ID property of the object that caused the current validation error within the current step.

Locating the invalid substep object (a VWInstructionDefinition or a VWRouteDefinition) requires the Step ID and the Map ID. You can get these IDs with getStepID and VWMapDefinition.getMapId.

Returns:
The ID property of the substep object that caused the current validation error. This can be any one of the following:
  • 2: VALIDATION_TYPE_ROUTE
  • 7: VALIDATION_TYPE_INSTRUCTION
  • -1: Undefined
See Also:
getStepId(), VWMapDefinition.getMapId()

toString

public java.lang.String toString()
Returns a String representing this instance.

Overrides:
toString in class java.lang.Object
Returns:
A String containing a text representation of the validation error message. The string is formatted as follows:

<error type>:<error level>:<object name>:<additional information>:<map ID>:<step ID>:<instruction ID>:<error message>


Process API

© Copyright IBM Corporation 2002, 2008. All rights reserved.