Cytoscape 3.1.1 API

org.cytoscape.work.util
Class BoundedFloat

java.lang.Object
  extended by org.cytoscape.work.util.AbstractBounded<Float>
      extended by org.cytoscape.work.util.BoundedFloat

public final class BoundedFloat
extends AbstractBounded<Float>

A Float object which has low and up bounds.


Cytoscape Backwards Compatibility (Final Class): This class is final and therefore can't be extended by users. This means that we may add methods for minor version updates. Methods will only be removed for major version updates.

Module: work-api

To use this in your app, include the following dependency in your POM:

<dependency>
    <groupId>org.cytoscape</groupId>
    <artifactId>work-api</artifactId>
</dependency>

Constructor Summary
BoundedFloat(Float lower, Float initValue, Float upper, boolean lowerStrict, boolean upperStrict)
          Creates a new Bounded Float object.
 
Method Summary
 Float clamp(Float value)
          Clamp the value to be within the range.
 void setValue(String s)
          Set a new value to the BoundedFloat object.
 
Methods inherited from class org.cytoscape.work.util.AbstractBounded
addListener, getLowerBound, getUpperBound, getValue, isLowerBoundStrict, isUpperBoundStrict, removeListener, setBounds, setLowerBoundStrict, setUpperBoundStrict, setValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BoundedFloat

public BoundedFloat(Float lower,
                    Float initValue,
                    Float upper,
                    boolean lowerStrict,
                    boolean upperStrict)
Creates a new Bounded Float object.

Parameters:
lower - The lower bound value.
initValue - Initial of default value for the Float.
upper - The upper bound value.
lowerStrict - True means that the value cannot be equal to the lower bound.
upperStrict - True means that the value cannot be equal to the upper bound.
Method Detail

setValue

public void setValue(String s)
Set a new value to the BoundedFloat object.

Specified by:
setValue in class AbstractBounded<Float>
Parameters:
s - String converted into Float.

clamp

public Float clamp(Float value)
Clamp the value to be within the range.

Specified by:
clamp in class AbstractBounded<Float>

Cytoscape 3.1.1 API

Copyright 2011 Cytoscape Consortium. All rights reserved.