com.threerings.antidote.field
Class OptionalField<F extends ReferenceField>

java.lang.Object
  extended by com.threerings.antidote.field.BaseFieldWrapper<F>
      extended by com.threerings.antidote.field.OptionalField<F>
All Implemented Interfaces:
Field, FieldWrapper<F>, Mutable, RequiresValidation

public class OptionalField<F extends ReferenceField>
extends BaseFieldWrapper<F>

A FieldWrapper which wraps a Field which can be unset, e.g. null.


Constructor Summary
OptionalField(Class<? extends Field> clazz, Field parent)
           
OptionalField(F wrapped, Field parent)
           
OptionalField(String abstractName, Field parent)
           
 
Method Summary
 void validateWrappedField()
          Provide subclasses a chance to perform additional validation, including validation of the wrapped field.
 
Methods inherited from class com.threerings.antidote.field.BaseFieldWrapper
appendViolation, appendViolationList, getField, getFieldName, getLocation, getParent, isNotSet, isSet, setField, validate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OptionalField

public OptionalField(F wrapped,
                     Field parent)

OptionalField

public OptionalField(Class<? extends Field> clazz,
                     Field parent)

OptionalField

public OptionalField(String abstractName,
                     Field parent)
Method Detail

validateWrappedField

public void validateWrappedField()
Description copied from class: BaseFieldWrapper
Provide subclasses a chance to perform additional validation, including validation of the wrapped field.

Specified by:
validateWrappedField in class BaseFieldWrapper<F extends ReferenceField>


Copyright © 2007-2008 Three Rings Design, Inc. All Rights Reserved. Released under a BSD license.