org.dasein.attributes.types
Class BooleanFactory

java.lang.Object
  extended by org.dasein.attributes.DataTypeFactory<Boolean>
      extended by org.dasein.attributes.types.BooleanFactory
All Implemented Interfaces:
Serializable

public class BooleanFactory
extends DataTypeFactory<Boolean>

Represents a true/false value.

Last modified: $Date: 2009/01/30 23:01:49 $

Version:
$Revision: 1.4 $
Author:
George Reese
See Also:
Serialized Form

Nested Class Summary
static class BooleanFactory.BooleanAttribute
           Implements the rules around a boolean value.
 
Nested classes/interfaces inherited from class org.dasein.attributes.DataTypeFactory
DataTypeFactory.Constraint
 
Field Summary
static String TYPE_NAME
          The name of this type is 'boolean'.
 
Constructor Summary
BooleanFactory()
          Constructs a new factory instance for boolean attributes.
 
Method Summary
 Translator<String> getDisplayName()
          Provides a multi-lingual display name for this data type.
 DataType<Boolean> getType(boolean ml, boolean mv, boolean req, String... params)
          Technically, you can have a multi-lingual or multi-valued boolean, but why would you?
 DataType<Boolean> getType(String grp, Number idx, boolean ml, boolean mv, boolean req, String... params)
          Technically, you can have a multi-lingual or multi-valued boolean, but why would you?
 String getTypeName()
           
 
Methods inherited from class org.dasein.attributes.DataTypeFactory
getConstraint, getConstraints, getDisplayValue, getDisplayValue, getInstance, getStringValue, getTypes
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TYPE_NAME

public static final String TYPE_NAME
The name of this type is 'boolean'.

See Also:
Constant Field Values
Constructor Detail

BooleanFactory

public BooleanFactory()
Constructs a new factory instance for boolean attributes.

Method Detail

getDisplayName

public Translator<String> getDisplayName()
Description copied from class: DataTypeFactory
Provides a multi-lingual display name for this data type.

Specified by:
getDisplayName in class DataTypeFactory<Boolean>
Returns:
a display name for this data type

getTypeName

public String getTypeName()
Specified by:
getTypeName in class DataTypeFactory<Boolean>
Returns:
the type name, 'boolean'

getType

public DataType<Boolean> getType(boolean ml,
                                 boolean mv,
                                 boolean req,
                                 String... params)
Technically, you can have a multi-lingual or multi-valued boolean, but why would you?

Specified by:
getType in class DataTypeFactory<Boolean>
Parameters:
ml - true if the boolean is multi-lingual
mv - true if the boolean can support multiple values
req - true if the boolean is required
params - unused
Returns:
a boolean instance

getType

public DataType<Boolean> getType(String grp,
                                 Number idx,
                                 boolean ml,
                                 boolean mv,
                                 boolean req,
                                 String... params)
Technically, you can have a multi-lingual or multi-valued boolean, but why would you?

Specified by:
getType in class DataTypeFactory<Boolean>
Parameters:
ml - true if the boolean is multi-lingual
mv - true if the boolean can support multiple values
req - true if the boolean is required
params - unused
grp - the group of the data type.
idx - the index of the data type.
Returns:
a boolean instance


Copyright © 2011 enStratus Networks LLC. All Rights Reserved.