org.qtitools.qti.node.content.xhtml.object
Class Param

java.lang.Object
  extended by org.qtitools.qti.node.AbstractNode
      extended by org.qtitools.qti.node.AbstractObject
          extended by org.qtitools.qti.node.content.xhtml.object.Param
All Implemented Interfaces:
java.io.Serializable, ObjectFlow, XmlNode, XmlObject, Validatable

public class Param
extends AbstractObject
implements ObjectFlow

Attribute : name [1]: string The name of the parameter, as interpreted by the object. Attribute : value [1]: string The value to pass to the object for the named parameter. This value is subject to template variable expansion. If the value is the name of A template variable that was declared with the paramVariable set to true then the template variable's value is passed to the object as the value for the given parameter. When expanding A template variable as A parameter value, types other than identifiers, strings and uris must be converted to strings. Numeric types are converted to strings using the "%i" or "%G" formats as appropriate (see printedVariable for A discussion of numeric formatting). Values of base-type boolean are expanded to one of the strings "true" or "false". Values of base-type point are expanded to two space-separated integers in the order horizontal coordinate, vertical coordinate, using "%i" format. Values of base-type pair and directedPair are converted to A string consisting of the two identifiers, space separated. Values of base-type duration are converted using "%G" format. Values of base-type file cannot be used in parameter expansion. If the valuetype is REF the template variable must be of base-type uri. Attribute : valuetype [1]: paramType = DATA This specification supports the use of DATA and REF but not OBJECT. Attribute : type [0..1]: mimeType Used to provide A type for values valuetype REF.

Author:
Jonathon Hare
See Also:
Serialized Form

Field Summary
static java.lang.String ATTR_NAME_NAME
          Name of name attribute in xml schema.
static java.lang.String ATTR_TYPE_NAME
          Name of type attribute in xml schema.
static java.lang.String ATTR_VALUE_NAME
          Name of value attribute in xml schema.
static java.lang.String ATTR_VALUETYPE_NAME
          Name of valuetype attribute in xml schema.
static java.lang.String CLASS_TAG
          Name of this class in xml schema.
 
Fields inherited from interface org.qtitools.qti.node.content.basic.ObjectFlow
DISPLAY_NAME
 
Fields inherited from interface org.qtitools.qti.node.XmlNode
INDENT, NEW_LINE, SIMPLE_NAME_INNER_SEPARATOR, SIMPLE_NAMES_SEPARATOR
 
Constructor Summary
Param(XmlObject parent)
          Constructs object.
 
Method Summary
 java.lang.String getClassTag()
          Gets QTI class name of this node.
 java.lang.String getName()
          Gets value of name attribute.
 java.lang.String getType()
          Gets value of type attribute.
 java.lang.String getValue()
          Gets value of value attribute.
 ParamType getValuetype()
          Gets value of valuetype attribute.
 void setName(java.lang.String name)
          Sets new value of name attribute.
 void setType(java.lang.String type)
          Sets new value of type attribute.
 void setValue(java.lang.String value)
          Sets new value of value attribute.
 void setValuetype(ParamType valuetype)
          Sets new value of valuetype attribute.
 
Methods inherited from class org.qtitools.qti.node.AbstractObject
getParent, getParentItem, getParentResult, getParentTest, setParent
 
Methods inherited from class org.qtitools.qti.node.AbstractNode
attrToXmlString, bodyToXmlString, getAttributes, getFullName, getIndent, getNode, getNode, getNode, getNodeGroups, getParentRoot, getSimpleName, getSourceFile, getSourceNode, getSourceString, getSourceUrl, hasChildNodes, load, load, load, load, loadAttributes, readChild, readChildren, setParent, setSourceFile, setSourceNode, setSourceString, setSourceUrl, toXmlString, toXmlString, validate, validateAttributes, validateChildren
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.qtitools.qti.node.XmlNode
getAttributes, getFullName, getNodeGroups, getParent, getParentRoot, getSimpleName, getSourceFile, getSourceNode, getSourceString, getSourceUrl, hasChildNodes, load, load, load, load, setSourceFile, setSourceNode, setSourceString, setSourceUrl, toXmlString, toXmlString
 
Methods inherited from interface org.qtitools.qti.validation.Validatable
validate
 

Field Detail

CLASS_TAG

public static java.lang.String CLASS_TAG
Name of this class in xml schema.


ATTR_NAME_NAME

public static final java.lang.String ATTR_NAME_NAME
Name of name attribute in xml schema.

See Also:
Constant Field Values

ATTR_VALUE_NAME

public static final java.lang.String ATTR_VALUE_NAME
Name of value attribute in xml schema.

See Also:
Constant Field Values

ATTR_VALUETYPE_NAME

public static final java.lang.String ATTR_VALUETYPE_NAME
Name of valuetype attribute in xml schema.

See Also:
Constant Field Values

ATTR_TYPE_NAME

public static final java.lang.String ATTR_TYPE_NAME
Name of type attribute in xml schema.

See Also:
Constant Field Values
Constructor Detail

Param

public Param(XmlObject parent)
Constructs object.

Parameters:
parent - parent of constructed object
Method Detail

getClassTag

public java.lang.String getClassTag()
Description copied from interface: XmlNode
Gets QTI class name of this node.

QTI class name has very important role during loading/saving nodes.

For example: Java class name is AssessmentTest; QTI class name is assessmentTest.

Specified by:
getClassTag in interface XmlNode
Specified by:
getClassTag in class AbstractNode
Returns:
QTI class name of this node

getName

public java.lang.String getName()
Gets value of name attribute.

Returns:
value of name attribute
See Also:
setName(java.lang.String)

setName

public void setName(java.lang.String name)
Sets new value of name attribute.

Parameters:
name - new value of name attribute
See Also:
getName()

getValue

public java.lang.String getValue()
Gets value of value attribute.

Returns:
value of value attribute
See Also:
setValue(java.lang.String)

setValue

public void setValue(java.lang.String value)
Sets new value of value attribute.

Parameters:
value - new value of value attribute
See Also:
getValue()

getValuetype

public ParamType getValuetype()
Gets value of valuetype attribute.

Returns:
value of valuetype attribute
See Also:
setValuetype(org.qtitools.qti.value.ParamType)

setValuetype

public void setValuetype(ParamType valuetype)
Sets new value of valuetype attribute.

Parameters:
valuetype - new value of valuetype attribute
See Also:
getValuetype()

getType

public java.lang.String getType()
Gets value of type attribute.

Returns:
value of type attribute
See Also:
setType(java.lang.String)

setType

public void setType(java.lang.String type)
Sets new value of type attribute.

Parameters:
type - new value of type attribute
See Also:
getType()


Copyright © 2009. All Rights Reserved.