com.jgoodies.binding.value
Class ConverterFactory.LongConverter

java.lang.Object
  extended by com.jgoodies.binding.value.ConverterFactory.LongConverter
All Implemented Interfaces:
BindingConverter
Enclosing class:
ConverterFactory

public static final class ConverterFactory.LongConverter
extends Object
implements BindingConverter

Converts Longs using a given multiplier.


Method Summary
 Object sourceValue(Object targetValue)
          Converts a Long using the multiplier and sets it as new value.
 Object targetValue(Object sourceValue)
          Converts the subject's value and returns a corresponding Long using the multiplier.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

targetValue

public Object targetValue(Object sourceValue)
Converts the subject's value and returns a corresponding Long using the multiplier.

Specified by:
targetValue in interface BindingConverter
Parameters:
sourceValue - the subject's value
Returns:
the converted sourceValue
Throws:
ClassCastException - if the subject value is not of type Long

sourceValue

public Object sourceValue(Object targetValue)
Converts a Long using the multiplier and sets it as new value.

Specified by:
sourceValue in interface BindingConverter
Parameters:
targetValue - the Long object that shall be converted
Returns:
the converted value
Throws:
ClassCastException - if the new value is not of type Long


Copyright © 2002-2013 JGoodies Software GmbH. All Rights Reserved.