com.rubecula.jquantity
Class Constants

java.lang.Object
  extended bycom.rubecula.jquantity.Constants
All Implemented Interfaces:
Identifiable, LookupableFactoryInterface

public class Constants
extends java.lang.Object
implements LookupableFactoryInterface

Class to create Lookupable objects for the JQuantity framework.

Since:
V_0_5
Version:
$Revision: 1.1 $
Author:
Robin Hillyard

Field Summary
private static LookupTable $Table
          This is the static final lookup table of fundamental constants defined for the JQuantity framework.
 
Constructor Summary
Constants()
           
 
Method Summary
 Lookupable createLookupable()
          Create a Lookupable which stores fundamental physical constants.
 Lookupable createLookupable(java.lang.String filename)
          /** Method to create a Lookupable instance which is based on a file, useful for application-specific values.
 java.lang.String getIdentifier()
          Method to get the specific identifier for an object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

$Table

private static final LookupTable $Table
This is the static final lookup table of fundamental constants defined for the JQuantity framework. See the static initialization and/or createLookupable() for more details.

Constructor Detail

Constants

public Constants()
Method Detail

createLookupable

public Lookupable createLookupable()

Create a Lookupable which stores fundamental physical constants.
In particular, this method returns the (static) table of constants which JQuantity builds for handling expressions.

The constants (all instances of JQuantity) defined have the following keys:

Specified by:
createLookupable in interface LookupableFactoryInterface
Returns:
a table of key-lookupable Presentable values.
See Also:
LookupableFactoryInterface.createLookupable()

createLookupable

public Lookupable createLookupable(java.lang.String filename)
                            throws java.io.FileNotFoundException
Description copied from interface: LookupableFactoryInterface
/** Method to create a Lookupable instance which is based on a file, useful for application-specific values.

Specified by:
createLookupable in interface LookupableFactoryInterface
Parameters:
filename -
Returns:
a Lookupable object.
Throws:
java.io.FileNotFoundException - if filename cannot be found.

getIdentifier

public java.lang.String getIdentifier()
Description copied from interface: Identifiable
Method to get the specific identifier for an object.

Specified by:
getIdentifier in interface Identifiable
Returns:
the identifier.