All Packages  Class Hierarchy  This Package  Previous  Next  Index

Interface aid.cbr.tools.core.cbrcase.IndiceType

public interface IndiceType
Defines the interface of type information access about a simple indice. The goal of this interface is not to represent types in a generic way, but it defines only the useful information for doing case base reasoning with CBR*Tools. In addition, we have taken into account primitive types (int and float) dyrectly into the interface for better performance and avoid the use of wrappers.

Version:
$Revision$, $Date$
Author:
M. Jaczynski

Method Index

 o enum()
Returns the list of elements defining this type.
 o floatEnum()
Returns the list of elements defining this type.
 o getMaxFloatValue()
Returns the maximum value of this type.
 o getMaxIntValue()
Returns the maximum value of this type.
 o getMaxValue()
Returns the maximum value of this type.
 o getMinFloatValue()
Returns the minimum value of this type

Precondiftons:

 this.isBounded()==true
 this.isFloat()==true
 
 o getMinIntValue()
Returns the minimum value of this type

Precondiftons:

 this.isInt()==true
 this.isBounded()==true
 
 o getMinValue()
Returns the minimum value of this type

Precondiftons:

 this.isBounded()==true
 
 o getUndefFloatValue()
Returns the value used to indiquate that a value is undefined in this type.
 o getUndefIntValue()
Returns the value used to indiquate that a value is undefined in this type.
 o getUndefValue()
Returns the value used to indiquate that a value is undefined in this type.
 o getUnknownFloatValue()
Returns the value used to represents an unknown value.
 o getUnknownIntValue()
Returns the value used to represents an unknown value.
 o getUnknownValue()
Returns the value used to represents an unknown value.
 o greatherThan(Object, Object)
Defines the ordering function.
 o intEnum()
Returns the list of elements defining this type.
 o isBounded()
Indiquates if this type has upper and lower bounds.
 o isDefined(Object)
Tests if a given value is undefined in this type.
 o isEnumerated()
Indiquates if this type is defined by extension.
 o isFloat()
Indiquates if this type represents the primitive float type.
 o isFloatDefined(float)
Tests if a given value is undefined in this type.
 o isFloatUnknown(float)
Tests if a given value is unknown for this type.
 o isInt()
Indiquates if this type represents the primitive int type.
 o isIntDefined(int)
Tests if a given value is undefined in this type.
 o isIntUnknown(int)
Tests if a given value is unknown for this type.
 o isObject()
Indiquates if this this stores its elements as objects.
 o isOrdered()
Indiquates if the type is ordered i.e.
 o isUnknown(Object)
Tests if a given value is unknown for this type.
 o isValidFloatValue(float)
Indiquates if a float value is an element of this type.
 o isValidIntValue(int)
Indiquates if a int value is an element of this type.
 o isValidValue(Object)
Indiquates if a value is an element of this type.

Methods

 o isOrdered
 public abstract boolean isOrdered()
Indiquates if the type is ordered i.e. defines a function to order elements.

Returns:
true<\code> if the type is ordered false<\code> otherwise
 o greatherThan
 public abstract boolean greatherThan(Object o1,
                                      Object o2)
Defines the ordering function.

Precondiftons:

 this.isOrdered()==true
 

Parameters:
o1 - the first object
o2 - the second object
Returns:
true<\code> if o1 < o2 false<\code> otherwise
 o isValidValue
 public abstract boolean isValidValue(Object o)
Indiquates if a value is an element of this type.

Parameters:
o - the object
Returns:
true<\code> if the object is element of this type or if it is undefined or unknown false<\code> otherwise
 o isValidFloatValue
 public abstract boolean isValidFloatValue(float f)
Indiquates if a float value is an element of this type.

Precondiftons:

 this.isFloat()==true
 

Parameters:
f - the float value
Returns:
true<\code> if the value is element of this type or if it is undefined or unknown false<\code> otherwise
 o isValidIntValue
 public abstract boolean isValidIntValue(int i)
Indiquates if a int value is an element of this type.

Precondiftons:

 this.isInt()==true
 

Parameters:
i - the value
Returns:
true<\code> if the value is element of this type or if it is undefined or unknown false<\code> otherwise
 o isBounded
 public abstract boolean isBounded()
Indiquates if this type has upper and lower bounds.

Precondiftons:

 this.isOrdered()==true
 

Returns:
true<\code> if this type has bounds false<\code> otherwise
 o getMinValue
 public abstract Object getMinValue()
Returns the minimum value of this type

Precondiftons:

 this.isBounded()==true
 

Returns:
Returns the minimum value of this type.
 o getMinIntValue
 public abstract int getMinIntValue()
Returns the minimum value of this type

Precondiftons:

 this.isInt()==true
 this.isBounded()==true
 

Returns:
the minimum
 o getMinFloatValue
 public abstract float getMinFloatValue()
Returns the minimum value of this type

Precondiftons:

 this.isBounded()==true
 this.isFloat()==true
 

Returns:
the minimum
 o getMaxValue
 public abstract Object getMaxValue()
Returns the maximum value of this type.

Precondiftons:

 this.isBounded()==true
 

Returns:
the minimum
 o getMaxIntValue
 public abstract int getMaxIntValue()
Returns the maximum value of this type.

Precondiftons:

 this.isBounded()==true
 this.isInt()==true
 

Returns:
the minimum
 o getMaxFloatValue
 public abstract float getMaxFloatValue()
Returns the maximum value of this type.

Precondiftons:

 this.isBounded()==true
 this.isFloat()==true
 

Returns:
the minimum
 o isEnumerated
 public abstract boolean isEnumerated()
Indiquates if this type is defined by extension.

Returns:
true<\code> if the type is defined by extension false<\code> otherwise
 o enum
 public abstract List enum()
Returns the list of elements defining this type.

Precondiftons:

 this.isEnumerated()==true
 

Returns:
the list of elements
 o intEnum
 public abstract int[] intEnum()
Returns the list of elements defining this type.

Precondiftons:

 this.isEnumerated()==true
 this.isInt()==true
 

Returns:
the list of elements
 o floatEnum
 public abstract float[] floatEnum()
Returns the list of elements defining this type.

Precondiftons:

 this.isEnumerated()==true
 this.isFloat()==true
 

Returns:
the list of elements
 o getUnknownValue
 public abstract Object getUnknownValue()
Returns the value used to represents an unknown value.

Returns:
the unknown value
 o getUnknownIntValue
 public abstract int getUnknownIntValue()
Returns the value used to represents an unknown value.

Precondiftons:

 this.isInt()==true
 

Returns:
the unknown value
 o getUnknownFloatValue
 public abstract float getUnknownFloatValue()
Returns the value used to represents an unknown value.

Precondiftons:

 this.isInt()==true
 

Returns:
the unknown value
 o isUnknown
 public abstract boolean isUnknown(Object value)
Tests if a given value is unknown for this type.

Parameters:
value - the value
Returns:
true<\code> if the value is unknown false<\code> otherwise
 o isIntUnknown
 public abstract boolean isIntUnknown(int i)
Tests if a given value is unknown for this type.

Precondiftons:

 this.isInt()==true
 

Parameters:
i - the int value
Returns:
true<\code> if the value is unknown false<\code> otherwise
 o isFloatUnknown
 public abstract boolean isFloatUnknown(float f)
Tests if a given value is unknown for this type.

Precondiftons:

 this.isFloat()==true
 

Parameters:
f - the float value
Returns:
true<\code> if the value is unknown false<\code> otherwise
 o getUndefValue
 public abstract Object getUndefValue()
Returns the value used to indiquate that a value is undefined in this type.

Returns:
the undefined value
 o getUndefIntValue
 public abstract int getUndefIntValue()
Returns the value used to indiquate that a value is undefined in this type.

Precondiftons:

 this.isInt()==true
 

Returns:
the undefined value
 o getUndefFloatValue
 public abstract float getUndefFloatValue()
Returns the value used to indiquate that a value is undefined in this type.

Precondiftons:

 this.isFloat()==true
 

Returns:
the undefined value
 o isDefined
 public abstract boolean isDefined(Object v)
Tests if a given value is undefined in this type.

Parameters:
v - the value
Returns:
true<\code> if the value is undefined false<\code> otherwise
 o isIntDefined
 public abstract boolean isIntDefined(int i)
Tests if a given value is undefined in this type.

Precondiftons:

 this.isInt()==true
 

Parameters:
i - the int value
Returns:
true<\code> if the value is undefined false<\code> otherwise
 o isFloatDefined
 public abstract boolean isFloatDefined(float f)
Tests if a given value is undefined in this type.

Precondiftons:

 this.isFloat()==true
 

Parameters:
f - the float value
Returns:
true<\code> if the value is undefined false<\code> otherwise
 o isObject
 public abstract boolean isObject()
Indiquates if this this stores its elements as objects.

Invariant:

 this.isObject()==true implies this.isFloat()==false && isInt()==false
 

Returns:
true<\code> if objects are used false<\code> otherwise
 o isFloat
 public abstract boolean isFloat()
Indiquates if this type represents the primitive float type.

Invariant:

 this.isObject()==true implies to this.isFloat()==false && isInt()==false
 

Returns:
true<\code> if this type is the primitive float type false<\code> otherwise
 o isInt
 public abstract boolean isInt()
Indiquates if this type represents the primitive int type.

Invariant:

 this.isInt()==true implies this.isFloat()==false && isObject()==false
 

Returns:
true<\code> if this type is the int primitive type false<\code> otherwise

All Packages  Class Hierarchy  This Package  Previous  Next  Index