org.jomc.model
Class Property

Package class diagram package Property
java.lang.Object
  extended by org.jomc.model.ModelObject
      extended by org.jomc.model.Property
All Implemented Interfaces:
Cloneable, Inheritable

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public class Property
extends ModelObject
implements Cloneable, Inheritable

Model of a property. The 'Property' type defines attributes 'name', 'type', 'value', 'final' and 'override'. Attribute 'name' holds the name uniquely identifying the property in a set of properties. Attribute 'type' holds an identifier of the type of the property. Attribute 'value' holds the properties value.

Java class for Property complex type.

The following schema fragment specifies the expected content contained within this class.

 <complexType name="Property">
   <complexContent>
     <extension base="{http://jomc.org/model}ModelObject">
       <sequence>
         <any processContents='lax' namespace='##other' minOccurs="0"/>
       </sequence>
       <attribute name="name" use="required" type="{http://jomc.org/model}Identifier" />
       <attribute name="type" type="{http://jomc.org/model}Identifier" />
       <attribute name="value" type="{http://jomc.org/model}String" />
       <attribute name="final" type="{http://jomc.org/model}Flag" default="false" />
       <attribute name="override" type="{http://jomc.org/model}Flag" default="false" />
     </extension>
   </complexContent>
 </complexType>
 


Field Summary
protected  Boolean _final
           
protected  Object any
           
protected  String name
           
protected  Boolean override
           
protected  String type
           
protected  String value
           
 
Fields inherited from class org.jomc.model.ModelObject
authors, createDate, deprecated, documentation, MODEL_PUBLIC_ID, modelVersion
 
Constructor Summary
Property()
          Creates a new Property instance.
Property(Property o)
          Creates a new Property instance by deeply copying a given Property instance.
 
Method Summary
 Property clone()
          Creates and returns a deep copy of this object.
 Object getAny()
          Object value of this property or null.
 Object getJavaValue(ClassLoader classLoader)
          Gets the Java value of the property.
 String getName()
          Name of this property.
 String getType()
          Type of this property or null.
 String getValue()
          String value of this property or null.
 boolean isFinal()
          true, if this property is the final node in an inheritance hierarchy.
 boolean isOverride()
          true, if this property is intended to override a super property.
 void setAny(Object value)
          Sets the value of the any property.
 void setFinal(Boolean value)
          Sets the value of the final property.
 void setName(String value)
          Sets the value of the name property.
 void setOverride(Boolean value)
          Sets the value of the override property.
 void setType(String value)
          Sets the value of the type property.
 void setValue(String value)
          Sets the value of the value property.
 
Methods inherited from class org.jomc.model.ModelObject
getAnyElement, getAnyElement, getAnyElements, getAnyElements, getAnyObject, getAnyObjects, getAuthors, getCreateDate, getDocumentation, getModelVersion, isDeprecated, setAuthors, setCreateDate, setDeprecated, setDocumentation, setModelVersion
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

any

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
protected Object any

name

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
protected String name

type

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
protected String type

value

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
protected String value

_final

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
protected Boolean _final

override

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
protected Boolean override
Constructor Detail

Property

public Property()
Creates a new Property instance.


Property

public Property(Property o)
Creates a new Property instance by deeply copying a given Property instance.

Parameters:
o - The instance to copy.
Throws:
NullPointerException - if o is null.
Method Detail

getAny

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public Object getAny()
Object value of this property or null.

Returns:
possible object is Object Element

setAny

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public void setAny(Object value)
Sets the value of the any property.

Parameters:
value - allowed object is Object Element

getName

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public String getName()
Name of this property.

Returns:
possible object is String

setName

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public void setName(String value)
Sets the value of the name property.

Parameters:
value - allowed object is String

getType

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public String getType()
Type of this property or null.

Returns:
possible object is String

setType

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public void setType(String value)
Sets the value of the type property.

Parameters:
value - allowed object is String

getValue

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public String getValue()
String value of this property or null.

Returns:
possible object is String

setValue

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public void setValue(String value)
Sets the value of the value property.

Parameters:
value - allowed object is String

isFinal

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public boolean isFinal()
true, if this property is the final node in an inheritance hierarchy.

Specified by:
isFinal in interface Inheritable
Returns:
possible object is Boolean

setFinal

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public void setFinal(Boolean value)
Sets the value of the final property.

Parameters:
value - allowed object is Boolean

isOverride

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public boolean isOverride()
true, if this property is intended to override a super property.

Specified by:
isOverride in interface Inheritable
Returns:
possible object is Boolean

setOverride

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public void setOverride(Boolean value)
Sets the value of the override property.

Parameters:
value - allowed object is Boolean

clone

@Generated(value="com.sun.tools.xjc.Driver",
           date="2012-04-01T02:39:59+02:00",
           comments="JAXB RI vhudson-jaxb-ri-2.1-2")
public Property clone()
Creates and returns a deep copy of this object.

Overrides:
clone in class ModelObject
Returns:
A deep copy of this object.

getJavaValue

public Object getJavaValue(ClassLoader classLoader)
                    throws PropertyException
Gets the Java value of the property.

The Java value of the property is computed based on the following rules:

  1. If property any is set, the Java value is computed based on the object returned by method getAny() by possibly unwrapping any JAXBElement instances. If that object declares a
    public Object getJavaValue( ClassLoader )
    method, the value returned by this method is the object returned by a call to that method using reflection. If that object does not declare such a method, the value returned by this method is that (possibly unwrapped) object.
  2. If property value is set, the Java value is computed based on the values of properties type and value. If property type is not set or equals java.lang.String, the value returned by this method is the string value returned by method getValue(). If property type equals a name of a Java primitive type, an instance of the wrapper class corresponding to that primitive type name is returned instantiated by passing the value of property value to the public constructor taking a single java.lang.String argument of that wrapper class. For all other values of property type an instance of a class with a name equal to the value of property type is returned instantiated by passing the value of property value to the public constructor taking a single java.lang.String argument of that class.
  3. If properties any and value are both null, this method returns null.

Parameters:
classLoader - The class loader to use for getting the Java value; null to use the platform's bootstrap class loader.
Returns:
The Java value of the property or null.
Throws:
PropertyException - if getting the Java value of the property fails unexpectedly.


Copyright © 2005-2012 The JOMC Project. All Rights Reserved.Get JOMC at SourceForge.net. Fast, secure and Free Open Source software downloads
Please note that this documentation is maintained by non-native english speaking authors. As such, you may encounter phrases or wordings which seem imprecise or may even have a totally different meaning to native english speaking readers than what the individual author was trying to express. If you are a native english speaking reader and find any such phrases or wordings we kindly ask you to send an email to the corresponding author and help us improve this documentation in order to avoid misunderstandings. You will find the authors' email addresses at the top of each class. Please accept our apologies for any inconvenience caused.