Java Doc for EnumeratedParameter.java in  » 6.0-JDK-Modules » Java-Advanced-Imaging » javax » media » jai » 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 » 6.0 JDK Modules » Java Advanced Imaging » javax.media.jai 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   javax.media.jai.EnumeratedParameter

All known Subclasses:   javax.media.jai.operator.MinFilterShape,  javax.media.jai.operator.TransposeType,  javax.media.jai.operator.MosaicType,  javax.media.jai.operator.CompositeDestAlpha,  javax.media.jai.operator.ColorQuantizerType,  javax.media.jai.operator.ShearDir,  javax.media.jai.operator.MedianFilterShape,  javax.media.jai.operator.MaxFilterShape,  javax.media.jai.operator.DFTDataNature,  javax.media.jai.operator.DFTScalingType,
EnumeratedParameter
public class EnumeratedParameter implements Serializable(Code)
This class provides a mechanism by which enumerated parameters may be added to subclasses of OperationDescriptorImpl while retaining the ability to perform introspection on the allowable range of values of the enumeration. An example of an enumerated parameter is the type parameter of the "Transpose" operation which is defined in TransposeDescriptor to accept only the values defined by the FLIP_* and ROTATE_* fields of the descriptor.

This class may be used to create enumerated parameters in an OperationDescriptor as follows:

  • For each constrained-value parameter create a final class extending EnumeratedParameter. This class should consist of only a package private constructor with a single String parameter called name and a single statement invoking the superclass constructor with name as the parameter.
  • Define the class of the parameter in question to be the subclass of EnumeratedParameter which was created for it in in the previous step.
  • For each possible value of the parameter, define in the OperationDescriptor of the operator a public static final field of type equal to the class defined in the first step. Each field should be assigned an instance of the subclass defined in the first step. The name and value used for each of these EnumeratedParameter subclass instances should be distinct for each distinct field or an error will occur.
With respect to TransposeDescriptor, the three steps above would be to 1) create a final class TransposeType in the javax.media.jai.operator package; 2) define the type of the "type" parameter as TransposeType.class; and 3) define a static final field of class TransposeType for each of the enumerated values with each field being initialized to an instance of TransposeType with name equal to the name of the field and value to its integral (enumerated) value.
See Also:   OperationDescriptorImpl
See Also:   javax.media.jai.operator.TransposeDescriptor
since:
   JAI 1.1



Constructor Summary
public  EnumeratedParameter(String name, int value)
     Constructs an EnumeratedParameter with the indicated name and value.

Method Summary
public  booleanequals(Object o)
     Returns true if and only if the parameter is an instance of the class on which this method is invoked and has either the same name or the same value.
public  StringgetName()
     Returns the name assigned to this EnumeratedParameter when it was constructed.
public  intgetValue()
     Returns the value assigned to this EnumeratedParameter when it was constructed.
public  inthashCode()
     Returns a hash code value for the object.
public  StringtoString()
    


Constructor Detail
EnumeratedParameter
public EnumeratedParameter(String name, int value)(Code)
Constructs an EnumeratedParameter with the indicated name and value.




Method Detail
equals
public boolean equals(Object o)(Code)
Returns true if and only if the parameter is an instance of the class on which this method is invoked and has either the same name or the same value.



getName
public String getName()(Code)
Returns the name assigned to this EnumeratedParameter when it was constructed.



getValue
public int getValue()(Code)
Returns the value assigned to this EnumeratedParameter when it was constructed.



hashCode
public int hashCode()(Code)
Returns a hash code value for the object.



toString
public String toString()(Code)
Returns a String representation of this EnumeratedParameter as a concatentation of the form
 [class name]:[parameter name]=[parameter value]
 
For example, for an instance of a subclass org.foobar.jai.EnumParam with name "SomeValue" and value "2" the returned String would be
 org.foobar.jai.EnumParam:SomeValue=2
 



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.