org.robokind.api.common.position
Interface NormalizableRange<T>

All Known Implementing Classes:
BooleanRange, DoubleRange, IntegerRange, NormalizableRange.DefaultRange

public interface NormalizableRange<T>

Author:
Matthew Stevenson

Nested Class Summary
static class NormalizableRange.DefaultRange
          Returns the maximum value of the NormalizableRange.
 
Field Summary
static NormalizableRange.DefaultRange NORMALIZED_RANGE
           
 
Method Summary
 T denormalizeValue(NormalizedDouble v)
          Denormalizes a NormalizedDouble to a value within this NormalizableRange.
 T getMax()
          Returns the minimum value of the NormalizableRange.
 T getMin()
           
 boolean isValid(T t)
          Returns true if t is within the NormalizableRange.
 NormalizedDouble normalizeValue(T t)
          Normalizes a value within the NormalizableRange.
 

Field Detail

NORMALIZED_RANGE

static final NormalizableRange.DefaultRange NORMALIZED_RANGE
Method Detail

isValid

boolean isValid(T t)
Returns true if t is within the NormalizableRange.

Parameters:
t - value to check
Returns:
true if t is within the NormalizableRange

normalizeValue

NormalizedDouble normalizeValue(T t)
Normalizes a value within the NormalizableRange.

Parameters:
t - value to normalize
Returns:
value within the NormalizableRange, null if t is out of range

denormalizeValue

T denormalizeValue(NormalizedDouble v)
Denormalizes a NormalizedDouble to a value within this NormalizableRange.

Parameters:
v - value to denormalize
Returns:
non-normalized value within the NormalizableRange

getMin

T getMin()

getMax

T getMax()
Returns the minimum value of the NormalizableRange.

Returns:
minimum value of the NormalizableRange


Copyright © 2011-2013. All Rights Reserved.