com.tensegrity.composite.coordinate
Class ScaleUtilities

java.lang.Object
  extended bycom.tensegrity.composite.coordinate.ScaleUtilities

public final class ScaleUtilities
extends java.lang.Object

This class provides some general functionalities needed to work with Scales.

Version:
$Id: ScaleUtilities.java,v 1.7 2004/03/17 12:01:47 MichaelKegel Exp $
Author:
MichaelKegel

Method Summary
static MutableScale convertToMutableScale(Scale scale)
          Returns a MutableScale holding the same values as the given immutable Scale.
static MutableScale convertToMutableScaleCopy(Scale scale)
          Returns a MutableScale holding the same values as the given immutable Scale.
static java.lang.String getCanonicalDescription(java.lang.String type, double minimum, double maximum)
          Returns the canonical description of a Scale.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

convertToMutableScale

public static final MutableScale convertToMutableScale(Scale scale)
Returns a MutableScale holding the same values as the given immutable Scale.

Parameters:
scale - the Scale to copy the values from.
Returns:
a mutable version of the given Scale.

convertToMutableScaleCopy

public static final MutableScale convertToMutableScaleCopy(Scale scale)
Returns a MutableScale holding the same values as the given immutable Scale. This function ensures that the returned MutableScale is another instance than the given one.

Parameters:
scale - the Scale to copy the values from.
Returns:
a mutable version of the given Scale.

getCanonicalDescription

public static final java.lang.String getCanonicalDescription(java.lang.String type,
                                                             double minimum,
                                                             double maximum)
Returns the canonical description of a Scale.

Parameters:
type - the type of the Scale
minimum - the minimum value for the scale
maximum - the maximum value for the scale
Returns:
String the canonical description of the Scale


Copyright © 2005 Tensegrity Software GmbH. All Rights Reserved. Date of creation: 09.06.2006.