com.iparelan.util
Class IntegerUnmarshallingStrategy

java.lang.Object
  extended by com.iparelan.util.UtilObject
      extended by com.iparelan.util.IntegerUnmarshallingStrategy
All Implemented Interfaces:
UnmarshallingStrategy<Integer>

@Copyright(value="Copyright © 2008, Iparelan Solutions, LLC. All rights reserved.")
public final class IntegerUnmarshallingStrategy
extends UtilObject
implements UnmarshallingStrategy<Integer>

A strategy for parsing an Integer value that is stored as a String.

Version:
July 2008
Author:
Greg Mattes

Field Summary
 
Fields inherited from class com.iparelan.util.UtilObject
LOGGER, MSGS, UTILITIES_LOGGER_NAME
 
Fields inherited from interface com.iparelan.util.UnmarshallingStrategy
FILE, INTEGER
 
Constructor Summary
IntegerUnmarshallingStrategy()
           
 
Method Summary
 String toString()
           
 Integer unmarshall(String marshalled)
          Parses the specified String as value of type T and produces the resultant object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IntegerUnmarshallingStrategy

public IntegerUnmarshallingStrategy()
Method Detail

unmarshall

@Nullable
public Integer unmarshall(@Nullable
                                   String marshalled)
                   throws NumberFormatException
Description copied from interface: UnmarshallingStrategy
Parses the specified String as value of type T and produces the resultant object.

Specified by:
unmarshall in interface UnmarshallingStrategy<Integer>
Parameters:
marshalled - The value to be unmarshalled from a String to a T. May be null, in which case null is produced.
Returns:
The unmarshalled value of marshalled. null is considered to be the unmarshalled value of null.
Throws:
NumberFormatException

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2008 Iparelan Solutions, LLC. All rights reserved.