com.jaxfront.core.type
Interface ISimpleType

All Known Implementing Classes:
EditingType, SimpleType

public interface ISimpleType


Field Summary
static java.lang.String EMPTY_STRING
           
static java.lang.String SIMPLE_CONTENT_TEXT
           
 
Method Summary
 void actAs(java.lang.String extendedType, short dataType)
           
 void actAsBoolean()
          Defines that the primitive data type of this type is Boolean.
 void actAsColor()
          Defines that the primitive data type of this type is Color.
 void actAsDate()
          Defines that the primitive data type of this type is a date.
 void actAsDateTime()
          Defines that the primitive data type of this type is a date.
 void actAsDouble()
          Defines that the primitive data type of this type is Integer.
 void actAsInt()
          Defines that the primitive data type of this type is int.
 void actAsInteger()
          Defines that the primitive data type of this type is Integer.
 void actAsPassword()
          Defines that the primitive data type of this type is a date.
 void actAsString()
          Defines that the primitive data type of this type is String.
 void actAsVisualizer()
          Defines that the primitive data type of this type is Visualizer.
 void bind(Document DOM, org.w3c.dom.Element instanceElement)
          Binds an existing W3C element and its value(s) to the underlying W3C element.
 void bind(Document DOM, org.w3c.dom.Element instanceElement, boolean bindOnlyAvailable)
           
 void bind(java.lang.Object trigger, Type type)
          Binds an existing JAXFront type and its value(s) to myself.
 void checkDuplicateID(java.lang.String newValue)
           
 void checkDuplicateKey(java.lang.String newValue)
           
 java.util.List checkForDuplicateID()
           
 void checkKeyExist()
           
 void checkKeyExist(java.lang.String keyValue)
           
 java.lang.Object clone()
          Clones this type.
 int compareValue(SimpleType with)
           
 Type deepClone(Document dom, boolean cloneChoices, boolean includingData)
          Creates a deep clone of this type and all its referenced types.
 Type deepClone(Document dom, boolean cloneChoices, boolean includingData, boolean includeEditingType, SchemaNode schemaNode, org.w3c.dom.Element element)
           
 Type deepClone(Document dom, boolean cloneChoices, boolean includingData, SchemaNode schemaNode, org.w3c.dom.Element element)
           
 void domChanged(DOMChangeEvent event)
           
 ListType evaluateKeyHolderList()
           
 KeyContainer evaluatePossibleKeyContainer()
           
 Type evaluatePossibleKeyType()
           
 Type getChild(java.lang.String name)
           
 Type getChild(java.lang.String name, java.lang.String nameSpace)
           
 java.lang.String getCodeSetHelp()
           
 java.lang.String getCodeSetParam()
           
 java.lang.String getDefaultNullValue()
           
 java.lang.String getDefaultValue()
          Gets the default value of this type according to the schema element.
 Type getDirectChild(java.lang.String name)
           
 Type getDirectChild(java.lang.String name, java.lang.String namespace)
           
 java.util.List getDirectChildren()
          Gets a list of all child types.
 java.util.List getDirectChildren(java.lang.String name)
          Gets a list of child types with a given name.
 java.lang.String getDisplayValue()
          Returns this type as a String representation for JTables.
 java.lang.String[] getEnumeration()
          Returns the enumeration of a type as String[].
 java.lang.String getFixedValue()
          Gets the fixed value of this type according to the schema element.
 KeyRefDefinition getKeyRefDefinition()
           
 java.lang.Object getMathValueTyped()
          Return the effective type object for the formula expression math evaluator.
 double getMaxExclValue()
           
 double getMaxInclValue()
           
 long getMaxLength()
          Return the maximum length of this type.
 double getMinExclValue()
           
 double getMinInclValue()
           
 long getMinLength()
          Return the minimum length of this type.
 java.lang.String getName()
          Gets the tag name of the resulting W3C DOM.
 java.lang.String getPlainValue()
          Get's the value of this type without any modifications!
 int getPrimitiveDataType()
          Gets the primitive data type (as defined in the XML Schema) of this type.
 java.lang.String getReferencedKeyName()
           
 Type getReferencedKeyType()
           
 SchemaSimpleType getSimpleSchemaType()
           
 int getTotalDigit()
           
 java.lang.String getUserDefaultValue()
          Gets the value of this type.
 java.lang.String getValue()
          Gets the value of this type.
 boolean hasEmptyContent(boolean validationContext)
           
 boolean hasEmptyContent(boolean checkSerializeDefaults, boolean checkDefaultValue)
           
 boolean hasRegularExpression()
          Returns true if this type holds a regular expression.
 boolean isAnyType()
          Returns true if the content of this type can be any type.
 boolean isBoolean()
          Returns if the primitive data type of this type is Boolean.
 boolean isChoice()
          Returns if this type belongs to a choice.
 boolean isColor()
          Returns if the primitive data type of this type is Color.
 boolean isDate()
          Returns if the primitive data type of this type is Date.
 boolean isDateTime()
          Returns if the primitive data type of this type is DateTime.
 boolean isDuration()
          Returns if the primitive data type of this type is Duration.
 boolean isFloatingNumber()
          Return the effective type object for the formula expression math evaluator.
 boolean isKey()
           
 boolean isKeyRef()
           
 boolean isNumber()
          Returns if the primitive data type of this type is a number like Float, Double or Decimal.
 boolean isPassword()
           
 boolean isSimple()
          Returns true if this is a leaf in the tree.
 boolean isSimpleContent()
          Returns if this type has simple content.
 boolean isString()
          Returns if the primitive data type of this type is String.
 boolean isTime()
          Returns if the primitive data type of this type is Date.
 boolean isUsingDefaultValue()
           
 boolean isUsingDefaultValue(boolean checkXuiDefault)
          Return true if type is using a default value.
 boolean isVisualizer()
          Returns if the primitive data type of this type is Visualizer.
 void markAsDirtyXPath()
           
 void release()
           
 boolean remove()
          Removes this type from the JAXFront DOM.
 void serialize(java.lang.StringBuffer sb, int indent, boolean writeName, boolean recursive, boolean serializeEmptyContent)
          Serializes the current subTree to a StringBuffer
 void setIsAttribute(boolean isAttribute)
           
 void setValue(java.lang.Object eventSource, java.lang.String newValue, boolean isTemporary)
           
 void setValue(java.lang.Object eventSource, java.lang.String newValue, boolean isTemporary, boolean localeConversion)
           
 void setValue(java.lang.Object eventSource, java.lang.String newValue, boolean isTemporary, boolean localeConversion, java.util.Stack callStack)
           
 void setValue(java.lang.String newValue)
          Sets a new value of this type.
 void setValue(java.lang.String newValue, boolean isTemporary)
           
 java.lang.String toString()
          Returns this type as a String representation.
 java.lang.String translateToCodeSetValue()
          Returns the codeset decription value if this type is using a codeset enumeration otherwise return the normal value.
 void validate()
           
 void validate(boolean domIsValidating)
           
 

Field Detail

EMPTY_STRING

static final java.lang.String EMPTY_STRING
See Also:
Constant Field Values

SIMPLE_CONTENT_TEXT

static final java.lang.String SIMPLE_CONTENT_TEXT
See Also:
Constant Field Values
Method Detail

actAs

void actAs(java.lang.String extendedType,
           short dataType)

actAsBoolean

void actAsBoolean()
Defines that the primitive data type of this type is Boolean.


actAsColor

void actAsColor()
Defines that the primitive data type of this type is Color.


actAsDate

void actAsDate()
Defines that the primitive data type of this type is a date.


actAsDateTime

void actAsDateTime()
Defines that the primitive data type of this type is a date.


actAsDouble

void actAsDouble()
Defines that the primitive data type of this type is Integer.


actAsInt

void actAsInt()
Defines that the primitive data type of this type is int.


actAsInteger

void actAsInteger()
Defines that the primitive data type of this type is Integer.


actAsPassword

void actAsPassword()
Defines that the primitive data type of this type is a date.


actAsString

void actAsString()
Defines that the primitive data type of this type is String.


actAsVisualizer

void actAsVisualizer()
Defines that the primitive data type of this type is Visualizer.


bind

void bind(Document DOM,
          org.w3c.dom.Element instanceElement)
Binds an existing W3C element and its value(s) to the underlying W3C element.

Parameters:
DOM - the current document to which this type belongs
instanceElement - the element to bind

bind

void bind(Document DOM,
          org.w3c.dom.Element instanceElement,
          boolean bindOnlyAvailable)

bind

void bind(java.lang.Object trigger,
          Type type)
Binds an existing JAXFront type and its value(s) to myself.

Parameters:
type - the JAXFront type to bind

checkDuplicateID

void checkDuplicateID(java.lang.String newValue)
                      throws ValidationException
Throws:
ValidationException

checkDuplicateKey

void checkDuplicateKey(java.lang.String newValue)
                       throws ValidationException
Throws:
ValidationException

checkForDuplicateID

java.util.List checkForDuplicateID()
                                   throws ValidationException
Throws:
ValidationException

checkKeyExist

void checkKeyExist()
                   throws ValidationException
Throws:
ValidationException

checkKeyExist

void checkKeyExist(java.lang.String keyValue)
                   throws ValidationException
Throws:
ValidationException

clone

java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Clones this type.

Returns:
a clone of this type
Throws:
java.lang.CloneNotSupportedException - if this type cannot be cloned

compareValue

int compareValue(SimpleType with)

deepClone

Type deepClone(Document dom,
               boolean cloneChoices,
               boolean includingData)
               throws java.lang.CloneNotSupportedException
Creates a deep clone of this type and all its referenced types.

Parameters:
dom - the current dom to which this type belongs
Returns:
the cloned type
Throws:
java.lang.CloneNotSupportedException

deepClone

Type deepClone(Document dom,
               boolean cloneChoices,
               boolean includingData,
               boolean includeEditingType,
               SchemaNode schemaNode,
               org.w3c.dom.Element element)
               throws java.lang.CloneNotSupportedException
Throws:
java.lang.CloneNotSupportedException

deepClone

Type deepClone(Document dom,
               boolean cloneChoices,
               boolean includingData,
               SchemaNode schemaNode,
               org.w3c.dom.Element element)
               throws java.lang.CloneNotSupportedException
Throws:
java.lang.CloneNotSupportedException

domChanged

void domChanged(DOMChangeEvent event)
See Also:
DOMChangeListener.domChanged(com.jaxfront.core.dom.DOMChangeEvent)

evaluateKeyHolderList

ListType evaluateKeyHolderList()

evaluatePossibleKeyContainer

KeyContainer evaluatePossibleKeyContainer()

evaluatePossibleKeyType

Type evaluatePossibleKeyType()

getChild

Type getChild(java.lang.String name)
See Also:
Type.getChild(java.lang.String)

getChild

Type getChild(java.lang.String name,
              java.lang.String nameSpace)
See Also:
Type.getChild(java.lang.String)

getCodeSetHelp

java.lang.String getCodeSetHelp()

getCodeSetParam

java.lang.String getCodeSetParam()

getDefaultNullValue

java.lang.String getDefaultNullValue()

getDefaultValue

java.lang.String getDefaultValue()
Gets the default value of this type according to the schema element.

Returns:
the default value of this type

getDirectChild

Type getDirectChild(java.lang.String name)
See Also:
Type.getDirectChild(java.lang.String)

getDirectChild

Type getDirectChild(java.lang.String name,
                    java.lang.String namespace)
See Also:
Type.getDirectChild(java.lang.String,java.lang.String)

getDirectChildren

java.util.List getDirectChildren()
Gets a list of all child types.

Returns:
null

getDirectChildren

java.util.List getDirectChildren(java.lang.String name)
Gets a list of child types with a given name.

Parameters:
name - the name of the child(s)
Returns:
null

getDisplayValue

java.lang.String getDisplayValue()
Returns this type as a String representation for JTables.

Returns:
this type as a String representation

getEnumeration

java.lang.String[] getEnumeration()
Returns the enumeration of a type as String[].

Returns:
String[] the enumeration of a type as String[]

getFixedValue

java.lang.String getFixedValue()
Gets the fixed value of this type according to the schema element.

Returns:
the fixed value of this type

getKeyRefDefinition

KeyRefDefinition getKeyRefDefinition()

getMathValueTyped

java.lang.Object getMathValueTyped()
Return the effective type object for the formula expression math evaluator.


getMaxExclValue

double getMaxExclValue()

getMaxInclValue

double getMaxInclValue()

getMaxLength

long getMaxLength()
Return the maximum length of this type.


getMinExclValue

double getMinExclValue()

getMinInclValue

double getMinInclValue()

getMinLength

long getMinLength()
Return the minimum length of this type.


getName

java.lang.String getName()
Gets the tag name of the resulting W3C DOM.

Returns:
the tag name of the resulting W3C DOM

getPlainValue

java.lang.String getPlainValue()
Get's the value of this type without any modifications!

Returns:
the value of this type

getPrimitiveDataType

int getPrimitiveDataType()
Gets the primitive data type (as defined in the XML Schema) of this type.

Returns:
the primitive data type of this type

getReferencedKeyName

java.lang.String getReferencedKeyName()

getReferencedKeyType

Type getReferencedKeyType()

getSimpleSchemaType

SchemaSimpleType getSimpleSchemaType()

getTotalDigit

int getTotalDigit()

getUserDefaultValue

java.lang.String getUserDefaultValue()
Gets the value of this type.

Returns:
the value of this type

getValue

java.lang.String getValue()
Gets the value of this type.

Returns:
the value of this type

hasEmptyContent

boolean hasEmptyContent(boolean validationContext)

hasEmptyContent

boolean hasEmptyContent(boolean checkSerializeDefaults,
                        boolean checkDefaultValue)

hasRegularExpression

boolean hasRegularExpression()
Returns true if this type holds a regular expression.


isAnyType

boolean isAnyType()
Returns true if the content of this type can be any type.

Returns:

isBoolean

boolean isBoolean()
Returns if the primitive data type of this type is Boolean.

Returns:
true, if the primitive data type of this type is Boolean, false otherwise

isChoice

boolean isChoice()
Returns if this type belongs to a choice.

Returns:
true, if this type belongs to a choice, false otherwise

isColor

boolean isColor()
Returns if the primitive data type of this type is Color.

Returns:
true, if the primitive data type of this type is Color, false otherwise

isDate

boolean isDate()
Returns if the primitive data type of this type is Date.

Returns:
true, if the primitive data type of this type is Date, false otherwise

isDateTime

boolean isDateTime()
Returns if the primitive data type of this type is DateTime.

Returns:
true, if the primitive data type of this type is DateTime, false otherwise

isDuration

boolean isDuration()
Returns if the primitive data type of this type is Duration.

Returns:
true, if the primitive data type of this type is Duration, false otherwise

isFloatingNumber

boolean isFloatingNumber()
Return the effective type object for the formula expression math evaluator.


isKey

boolean isKey()
See Also:
Type.isKey()

isKeyRef

boolean isKeyRef()
See Also:
Type.isKeyRef()()

isNumber

boolean isNumber()
Returns if the primitive data type of this type is a number like Float, Double or Decimal.

Returns:
true, if the primitive data type of this type is a number, false otherwise

isPassword

boolean isPassword()

isSimple

boolean isSimple()
Returns true if this is a leaf in the tree.

Returns:
true

isSimpleContent

boolean isSimpleContent()
Returns if this type has simple content.

Returns:
true, if this type has simple content, false otherwise

isString

boolean isString()
Returns if the primitive data type of this type is String.

Returns:
true, if the primitive data type of this type is String, false otherwise

isTime

boolean isTime()
Returns if the primitive data type of this type is Date.

Returns:
true, if the primitive data type of this type is Date, false otherwise

isUsingDefaultValue

boolean isUsingDefaultValue()

isUsingDefaultValue

boolean isUsingDefaultValue(boolean checkXuiDefault)
Return true if type is using a default value.

Returns:
the value of this type

isVisualizer

boolean isVisualizer()
Returns if the primitive data type of this type is Visualizer.

Returns:
true, if the primitive data type of this type is Visualizer, false otherwise

markAsDirtyXPath

void markAsDirtyXPath()

release

void release()
See Also:
Type.release()

remove

boolean remove()
               throws ListModificationException
Removes this type from the JAXFront DOM.

Throws:
ListModificationException

serialize

void serialize(java.lang.StringBuffer sb,
               int indent,
               boolean writeName,
               boolean recursive,
               boolean serializeEmptyContent)
Serializes the current subTree to a StringBuffer

Parameters:
sb - a StringBuffer into which the subTree will be serialized
indent - size of indent
writeName - true, if the name of the type should be serialized, false otherwise
recursive - true, if all containing types should be serialized

setIsAttribute

void setIsAttribute(boolean isAttribute)

setValue

void setValue(java.lang.Object eventSource,
              java.lang.String newValue,
              boolean isTemporary)

setValue

void setValue(java.lang.Object eventSource,
              java.lang.String newValue,
              boolean isTemporary,
              boolean localeConversion)

setValue

void setValue(java.lang.Object eventSource,
              java.lang.String newValue,
              boolean isTemporary,
              boolean localeConversion,
              java.util.Stack callStack)

setValue

void setValue(java.lang.String newValue)
Sets a new value of this type.

Parameters:
newValue - a new value

setValue

void setValue(java.lang.String newValue,
              boolean isTemporary)

toString

java.lang.String toString()
Returns this type as a String representation.

Overrides:
toString in class java.lang.Object
Returns:
this type as a String representation

translateToCodeSetValue

java.lang.String translateToCodeSetValue()
Returns the codeset decription value if this type is using a codeset enumeration otherwise return the normal value.


validate

void validate()

validate

void validate(boolean domIsValidating)