Oxygen XML Editor 11.2 Author API

ro.sync.ecss.extensions.api
Class ArgumentDescriptor

java.lang.Object
  extended by ro.sync.ecss.extensions.api.ArgumentDescriptor

public class ArgumentDescriptor
extends Object

Descriptor class for an author operation argument.


Field Summary
protected  String[] allowedValues
          The array containing the allowed values for the arguments with type TYPE_CONSTANTS_LIST.
protected  String defaultValue
          The default value of the argument.
protected  String description
          The string argument description.
protected  String name
          The argument name.
protected  int type
          The argument type, can be one of: TYPE_STRING, TYPE_FRAGMENT, TYPE_XPATH_EXPRESSION, TYPE_CONSTANT_LIST,
static int TYPE_CONSTANT_LIST
          List of constant strings argument type.
static int TYPE_FRAGMENT
          XML fragment argument type.
static int TYPE_STRING
          String argument type.
static int TYPE_XPATH_EXPRESSION
          Xpath expression argument type.
 
Constructor Summary
ArgumentDescriptor(String name, int type, String description)
          Constructor of the argument descriptor class.
ArgumentDescriptor(String name, int type, String description, String[] allowedValues, String defaultValue)
          Constructor of the argument descriptor class.
 
Method Summary
static String decodeType(int type)
          Returns a String description of the given argument type.
 String[] getAllowedValues()
           
 String getDefaultValue()
           
 String getDescription()
           
 String getName()
           
 int getType()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TYPE_STRING

public static final int TYPE_STRING
String argument type. The value is 0.

See Also:
Constant Field Values

TYPE_FRAGMENT

public static final int TYPE_FRAGMENT
XML fragment argument type. It is represented as a String The value is 1.

See Also:
Constant Field Values

TYPE_XPATH_EXPRESSION

public static final int TYPE_XPATH_EXPRESSION
Xpath expression argument type. It is represented as a String The value is 2.

See Also:
Constant Field Values

TYPE_CONSTANT_LIST

public static final int TYPE_CONSTANT_LIST
List of constant strings argument type. The value is 3.

See Also:
Constant Field Values

name

protected String name
The argument name.


type

protected int type
The argument type, can be one of: TYPE_STRING, TYPE_FRAGMENT, TYPE_XPATH_EXPRESSION, TYPE_CONSTANT_LIST,


description

protected String description
The string argument description.


allowedValues

protected String[] allowedValues
The array containing the allowed values for the arguments with type TYPE_CONSTANTS_LIST.


defaultValue

protected String defaultValue
The default value of the argument.

Constructor Detail

ArgumentDescriptor

public ArgumentDescriptor(String name,
                          int type,
                          String description)
Constructor of the argument descriptor class.

Parameters:
name - The name of the argument.
type - The type of the argument, one of: TYPE_STRING, TYPE_FRAGMENT, TYPE_XPATH_EXPRESSION, TYPE_CONSTANT_LIST,
description - The description of the argument.

ArgumentDescriptor

public ArgumentDescriptor(String name,
                          int type,
                          String description,
                          String[] allowedValues,
                          String defaultValue)
Constructor of the argument descriptor class.

Parameters:
name - The name of the argument.
type - The type of the argument, one of: TYPE_STRING, TYPE_FRAGMENT, TYPE_XPATH_EXPRESSION, TYPE_CONSTANT_LIST,
description - The description of the argument.
allowedValues - The allowed values for the defined argument.
defaultValue - The default value of the argument.
Method Detail

getName

public String getName()
Returns:
The name of the argument.

getType

public int getType()
Returns:
The type of the argument, one of: TYPE_STRING, TYPE_FRAGMENT, TYPE_XPATH_EXPRESSION, TYPE_CONSTANT_LIST,

getDescription

public String getDescription()
Returns:
The description of the argument.

decodeType

public static String decodeType(int type)
Returns a String description of the given argument type.

Parameters:
type - The argument type, one of: TYPE_STRING, TYPE_FRAGMENT, TYPE_XPATH_EXPRESSION, TYPE_CONSTANT_LIST,
Returns:
The type description, or null if the type is not valid.

getAllowedValues

public String[] getAllowedValues()
Returns:
The array with allowed values. Is used for TYPE_CONSTANTS_LIST arguments.

getDefaultValue

public String getDefaultValue()
Returns:
The default value of the argument.

toString

public String toString()
Overrides:
toString in class Object
See Also:
Object.toString()

Oxygen XML Editor 11.2 Author API

© Copyright SyncRO Soft SRL 2002 - 2010.