Java Doc for Capacity.java in  » Science » Cougaar12_4 » org » cougaar » planning » ldm » measure » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » Science » Cougaar12_4 » org.cougaar.planning.ldm.measure 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   org.cougaar.planning.ldm.measure.AbstractMeasure
      org.cougaar.planning.ldm.measure.Capacity

Capacity
public class Capacity extends AbstractMeasure (Code)
A generic Scalar per Duration class that can be interpreted in a variety of ways depending on context.



Constructor Summary
public  Capacity(Scalar quantity, Duration period)
     Construct a capacity object which represents a Scalar Measure (e.g.
public  Capacity(String s)
     String constructor.
public  Capacity(Scalar quantity)
     Construct an "instantaneous" capacity object - e.g.

Method Summary
public  Measureadd(Measure other)
    
public  Durationdivide(Rate other)
    
public  booleanequals(Object o)
    
public  Measurefloor(int unit)
    
public  intgetCommonUnit()
    
public  intgetMaxUnit()
    
public  intgetNativeUnit()
    
public  doublegetNativeValue()
    
public  DurationgetPeriod()
    
public  ScalargetQuantity()
    
public  doublegetRate(int quantityUnits, int periodUnits)
     compute the figure that the capacity represents.
public  StringgetUnitName(int i)
    
public  doublegetValue(int unit)
    
public  inthashCode()
    
public  booleanisInstantaneous()
    
public  Measuremultiply(Measure other)
    
public  Measurenegate()
    
public  Measurescale(double scale)
    
public  Measuresubtract(Measure other)
    
public  StringtoString()
    
public  MeasurevalueOf(double value)
    
public  MeasurevalueOf(double value, int unit)
    


Constructor Detail
Capacity
public Capacity(Scalar quantity, Duration period)(Code)
Construct a capacity object which represents a Scalar Measure (e.g. Volume, Distance, etc) divided by a Duration (time). Example: Miles per hour, hours per day, gallons per second. May also be used



Capacity
public Capacity(String s)(Code)
String constructor. Allowed syntax is: "Scalarmeasure=ValueUnits Duration=ValueUnits" Example: "Count=20units Duration=1weeks" For instantaneous: "Count=20units"



Capacity
public Capacity(Scalar quantity)(Code)
Construct an "instantaneous" capacity object - e.g. the capactity of "holding 10000 Gallons" or "having 48 Het-equivalents".




Method Detail
add
public Measure add(Measure other)(Code)
TODO : fill in
Parameters:
  other -



divide
public Duration divide(Rate other)(Code)
TODO : fill in
Parameters:
  other -



equals
public boolean equals(Object o)(Code)



floor
public Measure floor(int unit)(Code)



getCommonUnit
public int getCommonUnit()(Code)
an illegal value, since Capacity is a tuple *



getMaxUnit
public int getMaxUnit()(Code)



getNativeUnit
public int getNativeUnit()(Code)



getNativeValue
public double getNativeValue()(Code)



getPeriod
public Duration getPeriod()(Code)
the denominator of the Capacty *



getQuantity
public Scalar getQuantity()(Code)
the numerator of the Capacity *



getRate
public double getRate(int quantityUnits, int periodUnits)(Code)
compute the figure that the capacity represents. E.g. Capacity cap = new Capacity(new Volume("10 liters"), new Duration("1 seconds")); double rate = cap.getCapacity(Volume.GALLONS, Duration.HOURS); Note that to get the quantityUnits correct, you need to know what the concrete type of the quantity is.
exception:
  UnknownUnitException - if a bad unit in either argument.
exception:
  NullPointerException - if duration is null.



getUnitName
public String getUnitName(int i)(Code)
null, since Capacity is a tuple *



getValue
public double getValue(int unit)(Code)



hashCode
public int hashCode()(Code)



isInstantaneous
public boolean isInstantaneous()(Code)
is this a representation of instantaneous capacity? *



multiply
public Measure multiply(Measure other)(Code)
TODO : fill in
Parameters:
  other -



negate
public Measure negate()(Code)



scale
public Measure scale(double scale)(Code)



subtract
public Measure subtract(Measure other)(Code)
TODO : fill in
Parameters:
  other -



toString
public String toString()(Code)



valueOf
public Measure valueOf(double value)(Code)



valueOf
public Measure valueOf(double value, int unit)(Code)



Methods inherited from org.cougaar.planning.ldm.measure.AbstractMeasure
public Measure apply(UnaryOperator op)(Code)(Java Doc)
public Measure apply(BinaryOperator op, Measure other)(Code)(Java Doc)
public int compareTo(Object o)(Code)(Java Doc)
final protected static int indexOfType(String s)(Code)(Java Doc)
public Measure max(Measure other)(Code)(Java Doc)
public Measure min(Measure other)(Code)(Java Doc)
public static AbstractMeasure newMeasure(String s, int unit)(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.