Joda System API

org.joda.property.impl.type
Class DefaultBooleanPrimitiveProperty

java.lang.Object
  |
  +--org.joda.property.impl.AbstractModelElement
        |
        +--org.joda.property.impl.AbstractProperty
              |
              +--org.joda.property.impl.type.AbstractBooleanicProperty
                    |
                    +--org.joda.property.impl.type.DefaultBooleanPrimitiveProperty
All Implemented Interfaces:
BooleanicProperty, BooleanPrimitiveProperty, DataProperty, InitializableProperty, ModelElement, Property, Property.Internal, java.io.Serializable

public class DefaultBooleanPrimitiveProperty
extends AbstractBooleanicProperty
implements BooleanPrimitiveProperty

Default implementation of a boolean property.

Data is stored in the associated PropertyData object as a Boolean object. This is immutable so can be directly returned.

Author:
Stephen Colebourne
See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class org.joda.property.Property
Property.Internal
 
Field Summary
 
Fields inherited from interface org.joda.property.type.BooleanPrimitiveProperty
DEFAULT_TYPE
 
Constructor Summary
DefaultBooleanPrimitiveProperty()
          Constructor
 
Method Summary
 boolean get()
          Get the property's value as a boolean.
protected  java.lang.Boolean getInternal()
          Ensure the get only returns valid booleans
 java.lang.Class getPropertyType()
          Get the type of the property - boolean.
protected  void setInternal(java.lang.Boolean newValue)
          Set the property value as a valid boolean
 
Methods inherited from class org.joda.property.impl.type.AbstractBooleanicProperty
booleanValue, convertObjectToBoolean, isFalse, isTrue, negate, set, set, toBoolean, toObject
 
Methods inherited from class org.joda.property.impl.AbstractProperty
addPropertyChangeListener, bean, checkArgumentNotNull, checkModifiable, checkValueNotNull, checkValueNotNull, cloneDeep, convertObject, createClonedProperty, data, equals, equalsValue, firePropertyChange, firePropertyChange, getContentName, getContentType, getPropertyName, getThis, hashCode, initBeanCreated, initPropertyCreated, isModifiable, isNull, isReadOnly, populateClonedProperty, removePropertyChangeListener, setModifiable, setReadOnly, toDataString, toString
 
Methods inherited from class org.joda.property.impl.AbstractModelElement
getAttribute, getAttributeCount, getAttributeMap, setAttribute
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.joda.property.type.BooleanicProperty
booleanValue, isFalse, isTrue, negate, set, toBoolean
 
Methods inherited from interface org.joda.property.type.DataProperty
toDataString
 
Methods inherited from interface org.joda.property.Property
addPropertyChangeListener, bean, equals, equalsValue, firePropertyChange, getContentName, getContentType, getPropertyName, hashCode, isModifiable, isNull, isReadOnly, removePropertyChangeListener, set, setModifiable, setReadOnly, toObject, toString
 
Methods inherited from interface org.joda.property.ModelElement
getAttribute, getAttributeCount, getAttributeMap, setAttribute
 

Constructor Detail

DefaultBooleanPrimitiveProperty

public DefaultBooleanPrimitiveProperty()
Constructor

Method Detail

getInternal

protected java.lang.Boolean getInternal()
Ensure the get only returns valid booleans

Overrides:
getInternal in class AbstractBooleanicProperty
Returns:
the stored value

setInternal

protected void setInternal(java.lang.Boolean newValue)
Set the property value as a valid boolean

Overrides:
setInternal in class AbstractBooleanicProperty
Parameters:
newValue - the value to store

getPropertyType

public java.lang.Class getPropertyType()
Get the type of the property - boolean.

Specified by:
getPropertyType in interface Property
Returns:
the property type

get

public boolean get()
Description copied from interface: BooleanPrimitiveProperty
Get the property's value as a boolean.

Specified by:
get in interface BooleanPrimitiveProperty
Returns:
the property value as a boolean
See Also:
BooleanProperty#get()

Joda System API

Copyright © 2001-2003 Stephen Colebourne. All Rights Reserved.