Sweet Home 3D 4.0

com.eteks.sweethome3d.swing
Class NullableSpinner.NullableSpinnerDateModel

java.lang.Object
  extended by javax.swing.AbstractSpinnerModel
      extended by javax.swing.SpinnerDateModel
          extended by com.eteks.sweethome3d.swing.NullableSpinner.NullableSpinnerDateModel
All Implemented Interfaces:
Serializable, SpinnerModel
Enclosing class:
NullableSpinner

public static class NullableSpinner.NullableSpinnerDateModel
extends SpinnerDateModel

Spinner date model that accepts null values.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.AbstractSpinnerModel
listenerList
 
Constructor Summary
NullableSpinner.NullableSpinnerDateModel()
           
 
Method Summary
 Object getNextValue()
           
 Object getPreviousValue()
           
 Object getValue()
           
 boolean isNullable()
          Returns true if this spinner model is nullable.
 void setNullable(boolean nullable)
          Sets whether this spinner model is nullable.
 void setValue(Object value)
          Sets model value.
 
Methods inherited from class javax.swing.SpinnerDateModel
getCalendarField, getDate, getEnd, getStart, setCalendarField, setEnd, setStart
 
Methods inherited from class javax.swing.AbstractSpinnerModel
addChangeListener, fireStateChanged, getChangeListeners, getListeners, removeChangeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NullableSpinner.NullableSpinnerDateModel

public NullableSpinner.NullableSpinnerDateModel()
Method Detail

getNextValue

public Object getNextValue()
Specified by:
getNextValue in interface SpinnerModel
Overrides:
getNextValue in class SpinnerDateModel

getPreviousValue

public Object getPreviousValue()
Specified by:
getPreviousValue in interface SpinnerModel
Overrides:
getPreviousValue in class SpinnerDateModel

getValue

public Object getValue()
Specified by:
getValue in interface SpinnerModel
Overrides:
getValue in class SpinnerDateModel

setValue

public void setValue(Object value)
Sets model value. This method is overridden to store whether current value is null or not (super class setValue doesn't accept null value).

Specified by:
setValue in interface SpinnerModel
Overrides:
setValue in class SpinnerDateModel

isNullable

public boolean isNullable()
Returns true if this spinner model is nullable.


setNullable

public void setNullable(boolean nullable)
Sets whether this spinner model is nullable.


Sweet Home 3D 4.0

© Copyrights 2006-2013 eTeks - All rights reserved
Distributed under GNU General Public License