org.jboss.jca.common.metadata.jbossra.jbossra20
Class RaConfigProperty<T>

java.lang.Object
  extended by org.jboss.jca.common.metadata.jbossra.jbossra20.RaConfigProperty<T>
Type Parameters:
T - generic type of this property. See #buildRaConfigProperty(String, String, String, OverrideElementAttribute)) for build right implementation
All Implemented Interfaces:
Serializable, JCAMetadata

public class RaConfigProperty<T>
extends Object
implements JCAMetadata

Author:
Stefano Maestri
See Also:
Serialized Form

Nested Class Summary
static class RaConfigProperty.Tag
          A Tag.
 
Method Summary
static RaConfigProperty<?> buildRaConfigProperty(String name, String value, String type, OverrideElementAttribute overrideElementAttribute)
          Static method to build actualised implementation of this generic class.
 boolean equals(Object obj)
          
 String getName()
           
 OverrideElementAttribute getOverrideElementAttribute()
          override-element-attribute metadata getter
 String getTypeName()
          typeName getter
 T getValue()
           
 int hashCode()
          
 String toString()
          
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Method Detail

buildRaConfigProperty

public static RaConfigProperty<?> buildRaConfigProperty(String name,
                                                        String value,
                                                        String type,
                                                        OverrideElementAttribute overrideElementAttribute)
                                                 throws NumberFormatException
Static method to build actualised implementation of this generic class. According to jboss-ra_2_0.xsd value values are: java.lang.Boolean java.lang.String java.lang.Integer java.lang.Double java.lang.Byte java.lang.Short java.lang.Long java.lang.Float java.lang.Character In case passed type is one of above ones a correct actualised RaConfigProperty is returned. TypeName field will be set accordly In case the passed type isn't one of above ones (possible for jboss-ra_1_0.xsd) an RaConfigProperty is returned and typeName will be set as passed parameter type.

Parameters:
name - name of the property
value - value of the property.
type - the full qualified name of the class to be actualised
overrideElementAttribute - the override-element attribute. Possible value are defined in the enumeration; if it is null the default RESOURCEADAPTER is used
Returns:
the actualised instance
Throws:
NumberFormatException - in case passed value isn't assignable to type class

getName

public String getName()
Returns:
name

getValue

public T getValue()
Returns:
value

hashCode

public int hashCode()

Overrides:
hashCode in class Object
See Also:
Object.hashCode()

equals

public boolean equals(Object obj)

Overrides:
equals in class Object
See Also:
Object.equals(java.lang.Object)

toString

public String toString()

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

getTypeName

public String getTypeName()
typeName getter

Returns:
the typeName

getOverrideElementAttribute

public OverrideElementAttribute getOverrideElementAttribute()
override-element-attribute metadata getter

Returns:
the enum instance OverrideElementAttribute


Copyright © 2008 Red Hat Middleware LLC (http://www.jboss.com/)