wt.units.service
Class StandardUnitsService

java.lang.Object
  extended bywt.services.StandardManager
      extended bywt.units.service.StandardUnitsService
All Implemented Interfaces:
Manager, NetFactor, Serializable, UnitsService

public class StandardUnitsService
extends StandardManager
implements UnitsService, Serializable

Implements IBAMeasurementSystemQueryService

Use the newStandardUnitsService static factory method(s), not the StandardUnitsService constructor, to construct instances of this class. Instances must be constructed using the static factory(s), in order to ensure proper initialization of the instance.



Supported API: false

Extendable: false

See Also:
Serialized Form

Field Summary
private static String CLASSNAME
           
private  int hashtableSize
           
private static String RESOURCE
           
private  Unit theUnit
           
private  UnitDBService theUnitDBService
           
 
Fields inherited from class wt.services.StandardManager
 
Fields inherited from interface wt.services.Manager
MANAGER_SERVICE, STARTUP_AUTOMATIC, STARTUP_MANUAL, STATUS_EMERGENCY_SHUTDOWN, STATUS_EMERGENCY_SHUTTING_DOWN, STATUS_SHUTDOWN, STATUS_SHUTDOWN_ERRORS, STATUS_SHUTDOWN_FAILURE, STATUS_SHUTTING_DOWN, STATUS_STARTED, STATUS_STARTED_ERRORS, STATUS_STARTING_UP, STATUS_STARTUP_FAILURE
 
Constructor Summary
StandardUnitsService()
           
 
Method Summary
 MeasurementSystemDefaultView createMeasurementSystem(MeasurementSystemDefaultView measurementSystemDefaultView)
          Creates a new Measurement System.
 QuantityOfMeasureDefaultView createQuantityOfMeasure(QuantityOfMeasureDefaultView quantityOfMeasureDefaultView)
          Creates the QuantityOfMeasure object given its lite version QuantityOfMeasureDefaultView object.
 void deleteMeasurementSystem(MeasurementSystemDefaultView measurementSystemDefaultView)
          Deletes this measurement system given its name.
 void deleteQuantityOfMeasure(QuantityOfMeasureDefaultView quantityOfMeasureDefaultView)
          Deletes the QuantityOfMeasure object given its name.
 String getConceptualClassname()
          Deprecated.  
 MeasurementSystemDefaultView getMeasurementSystemDefaultView(String name)
          Gets a measurement system by its name.
 MeasurementSystemDefaultView[] getMeasurementSystemDefaultViews()
          Gets all Measurement Systems .
 String[] getMeasurementSystemNames()
          Gets all the measurement system names in persistence store.
 QuantityOfMeasureDefaultView getQuantityOfMeasureDefaultView(String name)
          Gets a lightweight QuantityOfMeasure object given its name.
 QuantityOfMeasureDefaultView[] getQuantityOfMeasureDefaultViews()
          Gets all the quantity of measures from datastore.
 String[] getQuantityOfMeasureNames()
          Gets all QuantityOfMeasure names.
static StandardUnitsService newStandardUnitsService()
          Default factory for the class.
 MeasurementSystemDefaultView refreshMeasurementSystemDefaultView(MeasurementSystemDefaultView measurementSystemDefaultView)
          Refresh the current fMeasurementSystemDefaultView by reloading its state from datastore.
 QuantityOfMeasureDefaultView refreshQuantityOfMeasureDefaultView(QuantityOfMeasureDefaultView quantityOfMeasureDefaultView)
          Refresh the current QuantityOfMeasureDefaultView by reloading its state from datastore.
 MeasurementSystemDefaultView updateMeasurementSystem(MeasurementSystemDefaultView measurementSystemDefaultView)
          Updates a Measurement System by saving the current object to datastore.
 QuantityOfMeasureDefaultView updateQuantityOfMeasure(QuantityOfMeasureDefaultView quantityOfMeasureDefaultView)
          Update the QuantityOfMeasure by saving its state to datastore.
 
Methods inherited from class wt.services.StandardManager
emergencyShutdown, emergencyShutdownComplete, emergencyShuttingDown, getClassInfo, getManagerService, getManagerStatus, getName, getStartupType, init, initialize, initialize, isStarted, newStandardManager, newStandardManager, performEmergencyShutdownProcess, performShutdownProcess, performStartupProcess, registerEvents, setManagerService, shutdown, shutdownFailure, shutdownSuccess, shuttingDown, started, startedErrors, startingUp, startup, startupFailure, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

theUnit

private final Unit theUnit

theUnitDBService

private final UnitDBService theUnitDBService

hashtableSize

private final int hashtableSize
See Also:
Constant Field Values
Constructor Detail

StandardUnitsService

public StandardUnitsService()
Method Detail

getConceptualClassname

public String getConceptualClassname()
Deprecated.  

Returns the conceptual (modeled) name for the class.

Supported API: false

Specified by:
getConceptualClassname in interface NetFactor
Overrides:
getConceptualClassname in class StandardManager
Returns:
String

newStandardUnitsService

public static StandardUnitsService newStandardUnitsService()
                                                    throws WTException
Default factory for the class.

Supported API: false

Returns:
StandardUnitsService
Throws:
WTException

createMeasurementSystem

public MeasurementSystemDefaultView createMeasurementSystem(MeasurementSystemDefaultView measurementSystemDefaultView)
                                                     throws RemoteException,
                                                            IncompatibleUnitsException,
                                                            UnitFormatException,
                                                            NotAuthorizedException,
                                                            WTException
Creates a new Measurement System.

Supported API: false

Specified by:
createMeasurementSystem in interface UnitsService
Parameters:
measurementSystemDefaultView -
Returns:
MeasurementSystemDefaultView
Throws:
RemoteException
IncompatibleUnitsException
UnitFormatException
NotAuthorizedException
WTException

createQuantityOfMeasure

public QuantityOfMeasureDefaultView createQuantityOfMeasure(QuantityOfMeasureDefaultView quantityOfMeasureDefaultView)
                                                     throws RemoteException,
                                                            IncompatibleUnitsException,
                                                            UnitFormatException,
                                                            NotAuthorizedException,
                                                            WTException
Creates the QuantityOfMeasure object given its lite version QuantityOfMeasureDefaultView object.

Supported API: false

Specified by:
createQuantityOfMeasure in interface UnitsService
Parameters:
quantityOfMeasureDefaultView -
Returns:
QuantityOfMeasureDefaultView
Throws:
RemoteException
IncompatibleUnitsException
UnitFormatException
NotAuthorizedException
WTException

deleteMeasurementSystem

public void deleteMeasurementSystem(MeasurementSystemDefaultView measurementSystemDefaultView)
                             throws RemoteException,
                                    IncompatibleUnitsException,
                                    UnitFormatException,
                                    NotAuthorizedException,
                                    WTException
Deletes this measurement system given its name.

Supported API: false

Specified by:
deleteMeasurementSystem in interface UnitsService
Parameters:
measurementSystemDefaultView -
Throws:
RemoteException
IncompatibleUnitsException
UnitFormatException
NotAuthorizedException
WTException

deleteQuantityOfMeasure

public void deleteQuantityOfMeasure(QuantityOfMeasureDefaultView quantityOfMeasureDefaultView)
                             throws RemoteException,
                                    IncompatibleUnitsException,
                                    UnitFormatException,
                                    NotAuthorizedException,
                                    WTException
Deletes the QuantityOfMeasure object given its name.

Supported API: false

Specified by:
deleteQuantityOfMeasure in interface UnitsService
Parameters:
quantityOfMeasureDefaultView -
Throws:
RemoteException
IncompatibleUnitsException
UnitFormatException
NotAuthorizedException
WTException

getMeasurementSystemNames

public String[] getMeasurementSystemNames()
                                   throws RemoteException,
                                          WTException
Gets all the measurement system names in persistence store. Returns null if no query results is returned for the requesting principal.

Supported API: false

Specified by:
getMeasurementSystemNames in interface UnitsService
Returns:
String[]
Throws:
RemoteException
WTException

getMeasurementSystemDefaultView

public MeasurementSystemDefaultView getMeasurementSystemDefaultView(String name)
                                                             throws RemoteException,
                                                                    WTException
Gets a measurement system by its name. Returns null if no query results is returned.

Supported API: false

Specified by:
getMeasurementSystemDefaultView in interface UnitsService
Parameters:
name -
Returns:
MeasurementSystemDefaultView
Throws:
RemoteException
WTException

getMeasurementSystemDefaultViews

public MeasurementSystemDefaultView[] getMeasurementSystemDefaultViews()
                                                                throws RemoteException,
                                                                       WTException
Gets all Measurement Systems . Returns null if no query results.

Supported API: false

Specified by:
getMeasurementSystemDefaultViews in interface UnitsService
Returns:
MeasurementSystemDefaultView[]
Throws:
RemoteException
WTException

getQuantityOfMeasureDefaultView

public QuantityOfMeasureDefaultView getQuantityOfMeasureDefaultView(String name)
                                                             throws RemoteException,
                                                                    WTException
Gets a lightweight QuantityOfMeasure object given its name.

Supported API: false

Specified by:
getQuantityOfMeasureDefaultView in interface UnitsService
Parameters:
name -
Returns:
QuantityOfMeasureDefaultView
Throws:
RemoteException
WTException

getQuantityOfMeasureDefaultViews

public QuantityOfMeasureDefaultView[] getQuantityOfMeasureDefaultViews()
                                                                throws RemoteException,
                                                                       WTException
Gets all the quantity of measures from datastore.

Supported API: false

Specified by:
getQuantityOfMeasureDefaultViews in interface UnitsService
Returns:
QuantityOfMeasureDefaultView[]
Throws:
RemoteException
WTException

getQuantityOfMeasureNames

public String[] getQuantityOfMeasureNames()
                                   throws RemoteException,
                                          WTException
Gets all QuantityOfMeasure names.

Supported API: false

Specified by:
getQuantityOfMeasureNames in interface UnitsService
Returns:
String[]
Throws:
RemoteException
WTException

refreshMeasurementSystemDefaultView

public MeasurementSystemDefaultView refreshMeasurementSystemDefaultView(MeasurementSystemDefaultView measurementSystemDefaultView)
                                                                 throws RemoteException,
                                                                        WTException
Refresh the current fMeasurementSystemDefaultView by reloading its state from datastore.

Supported API: false

Specified by:
refreshMeasurementSystemDefaultView in interface UnitsService
Parameters:
measurementSystemDefaultView -
Returns:
MeasurementSystemDefaultView
Throws:
RemoteException
WTException

refreshQuantityOfMeasureDefaultView

public QuantityOfMeasureDefaultView refreshQuantityOfMeasureDefaultView(QuantityOfMeasureDefaultView quantityOfMeasureDefaultView)
                                                                 throws RemoteException,
                                                                        WTException
Refresh the current QuantityOfMeasureDefaultView by reloading its state from datastore.

Supported API: false

Specified by:
refreshQuantityOfMeasureDefaultView in interface UnitsService
Parameters:
quantityOfMeasureDefaultView -
Returns:
QuantityOfMeasureDefaultView
Throws:
RemoteException
WTException

updateMeasurementSystem

public MeasurementSystemDefaultView updateMeasurementSystem(MeasurementSystemDefaultView measurementSystemDefaultView)
                                                     throws RemoteException,
                                                            IncompatibleUnitsException,
                                                            UnitFormatException,
                                                            NotAuthorizedException,
                                                            WTException
Updates a Measurement System by saving the current object to datastore.

Supported API: false

Specified by:
updateMeasurementSystem in interface UnitsService
Parameters:
measurementSystemDefaultView -
Returns:
MeasurementSystemDefaultView
Throws:
RemoteException
IncompatibleUnitsException
UnitFormatException
NotAuthorizedException
WTException

updateQuantityOfMeasure

public QuantityOfMeasureDefaultView updateQuantityOfMeasure(QuantityOfMeasureDefaultView quantityOfMeasureDefaultView)
                                                     throws RemoteException,
                                                            IncompatibleUnitsException,
                                                            UnitFormatException,
                                                            NotAuthorizedException,
                                                            WTException
Update the QuantityOfMeasure by saving its state to datastore.

Supported API: false

Specified by:
updateQuantityOfMeasure in interface UnitsService
Parameters:
quantityOfMeasureDefaultView -
Returns:
QuantityOfMeasureDefaultView
Throws:
RemoteException
IncompatibleUnitsException
UnitFormatException
NotAuthorizedException
WTException