com.abra.j2xb.beans.propertyEditors
Class MOFloatPropertyEditor

java.lang.Object
  extended by com.abra.j2xb.beans.propertyEditors.MONumberPropertyEditor
      extended by com.abra.j2xb.beans.propertyEditors.MOFloatPropertyEditor
All Implemented Interfaces:
MOPropertyEditor

public class MOFloatPropertyEditor
extends MONumberPropertyEditor

Since:
JDK1.5
Version:
1.0, May 1, 2008
Author:
Yoav Abrahami

Constructor Summary
MOFloatPropertyEditor()
           
 
Method Summary
 int compareValues(java.lang.Object num_a, java.lang.Object num_b)
           
 java.lang.Object fromString(java.lang.Class<?> propertyType, java.lang.String value)
          decodes the property value from string. this string can be used in annotations as the property default value.
protected  java.lang.String getNumberTypeName()
           
 MoXmlBaseSimpleType getXmlDefaultSimpleType(MoXmlBaseSimpleType xmlSimpleType)
          gets the base XML encoding type, used as the element base type in an XML schema
 boolean isCompatibleSimpleType(MoXmlBaseSimpleType xmlSimpleType)
           
 java.lang.String toString(java.lang.Class<?> propertyType, java.lang.Object value)
          encodes the property value to string.
 
Methods inherited from class com.abra.j2xb.beans.propertyEditors.MONumberPropertyEditor
fromXmlValue, getEnumerations, supportsNumberValidations, supportsStringValidations, toXmlValue, validateStringEncoding
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MOFloatPropertyEditor

public MOFloatPropertyEditor()
Method Detail

compareValues

public int compareValues(java.lang.Object num_a,
                         java.lang.Object num_b)

getNumberTypeName

protected java.lang.String getNumberTypeName()
Specified by:
getNumberTypeName in class MONumberPropertyEditor

fromString

public java.lang.Object fromString(java.lang.Class<?> propertyType,
                                   java.lang.String value)
Description copied from interface: MOPropertyEditor
decodes the property value from string. this string can be used in annotations as the property default value.

Parameters:
propertyType - the class of the propery value
value - - the string value
Returns:
the property value

toString

public java.lang.String toString(java.lang.Class<?> propertyType,
                                 java.lang.Object value)
Description copied from interface: MOPropertyEditor
encodes the property value to string.

Parameters:
propertyType - the class of the propery value
value - - the property value
Returns:
string encoding

isCompatibleSimpleType

public boolean isCompatibleSimpleType(MoXmlBaseSimpleType xmlSimpleType)
Parameters:
xmlSimpleType - simple type to check if compatible with the property editor
Returns:
returns if the simple type is compatible with this property editor

getXmlDefaultSimpleType

public MoXmlBaseSimpleType getXmlDefaultSimpleType(MoXmlBaseSimpleType xmlSimpleType)
Description copied from interface: MOPropertyEditor
gets the base XML encoding type, used as the element base type in an XML schema

Parameters:
xmlSimpleType - an xml simple type. can be MoXmlBaseSimpleType.xmlNotSpecified
Returns:
the XML type


Copyright © 2008. All Rights Reserved.