Class AAttributeValue<D>
- java.lang.Object
-
- ai.libs.jaicore.ml.core.dataset.attribute.AAttributeValue<D>
-
- Type Parameters:
D- The domain of values.
- All Implemented Interfaces:
IAttributeValue<D>,java.io.Serializable
- Direct Known Subclasses:
BooleanAttributeValue,CategoricalAttributeValue,MultiValueAttributeValue,NumericAttributeValue,TimeSeriesAttributeValue
public abstract class AAttributeValue<D> extends java.lang.Object implements IAttributeValue<D>
An abstract class for attribute values implementing basic functionality to store its value as well as getter and setters.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedAAttributeValue(IAttributeType<D> type)Constructor creating a new attribute value for a certain type.protectedAAttributeValue(IAttributeType<D> type, D value)Constructor creating a new attribute value for a certain type together with a value.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)IAttributeType<D>getType()DgetValue()inthashCode()voidsetValue(D value)
-
-
-
Constructor Detail
-
AAttributeValue
protected AAttributeValue(IAttributeType<D> type)
Constructor creating a new attribute value for a certain type. The value remains unset.- Parameters:
type- The type of the attribute value.
-
AAttributeValue
protected AAttributeValue(IAttributeType<D> type, D value)
Constructor creating a new attribute value for a certain type together with a value.- Parameters:
type- The type of the attribute value.value- The value of this attribute.
-
-
Method Detail
-
getType
public IAttributeType<D> getType()
- Specified by:
getTypein interfaceIAttributeValue<D>- Returns:
- The attribute type of this attribute value.
-
getValue
public D getValue()
- Specified by:
getValuein interfaceIAttributeValue<D>- Returns:
- The value of this attribute value.
-
setValue
public void setValue(D value)
- Specified by:
setValuein interfaceIAttributeValue<D>- Parameters:
value- The value of this attribute value.
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
-