public final class ClassConfiguration extends Object
Modifier and Type | Class and Description |
---|---|
protected class |
ClassConfiguration.PropertyInfo
Class used to contain the property information if the property is readable, writeable and the
methods that implement the get and set functions.
|
Constructor and Description |
---|
ClassConfiguration(String classname,
String implementingClass,
String jsConstructor,
String extendedClass,
String htmlClass,
boolean jsObject)
Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
addConstant(String name)
Add the constant to the configuration.
|
void |
addFunction(String name)
Add the function to the configuration
|
void |
addProperty(String name,
boolean readable,
boolean writeable)
Add the property to the configuration
|
List |
constants()
Return the constant list.
|
boolean |
equals(Object obj)
Test for value equality of the 2 objects
|
Set |
functionKeys()
Return the set of keys for the defined functions
|
String |
getClassName() |
String |
getExtendedClass() |
Method |
getFunctionMethod(String functionName)
Gets the method that implements the given function
|
String |
getHtmlClassname() |
Method |
getJsConstructor()
Gets the JavaScript constructor method in
getLinkedClass() |
Class |
getLinkedClass()
Gets the class of the Javascript host object
|
protected ClassConfiguration.PropertyInfo |
getPropertyInfo(String propertyName)
Return the PropertyInfo for the given property name
|
Method |
getPropertyReadMethod(String propertyName)
Gets the method that implements the getter for the named property
|
Method |
getPropertyWriteMethod(String propertyName)
Gets the method that implements the setter for the named property
|
int |
hashCode()
Currently, this is the hashcode for the name.
|
boolean |
isJsObject() |
Set |
propertyKeys()
Return the set of keys for the defined properties.
|
void |
setBrowser(String propertyName,
String browserName)
Set the browser information for this named property
|
void |
setExtendedClass(String extendedClass) |
public ClassConfiguration(String classname, String implementingClass, String jsConstructor, String extendedClass, String htmlClass, boolean jsObject) throws ClassNotFoundException
classname
- the name of the configuration class this entry is forimplementingClass
- - the fully qualified name of the class implementing this functionalityjsConstructor
- the constructor of method implementingClass
extendedClass
- - The name of the class that this class extendshtmlClass
- The name of the html class that this object supportsjsObject
- boolean flag for if this object is a JavaScript objectClassNotFoundException
- - If the implementing class is not foundpublic String getClassName()
public void addProperty(String name, boolean readable, boolean writeable)
name
- - Name of the propertyreadable
- - Flag for if the property is readablewriteable
- - Flag for if the property is writeablepublic void addConstant(String name)
name
- - Name of the configuration.public Set propertyKeys()
public Set functionKeys()
public List constants()
public void addFunction(String name)
name
- - Name of the functionpublic void setBrowser(String propertyName, String browserName) throws IllegalStateException
propertyName
- - Name of the property to setbrowserName
- - Browser name to setIllegalStateException
- - Property does not existpublic String getExtendedClass()
public void setExtendedClass(String extendedClass)
extendedClass
- The extendedClass to set.protected ClassConfiguration.PropertyInfo getPropertyInfo(String propertyName)
propertyName
- Name of propertypublic boolean equals(Object obj)
public int hashCode()
public Method getPropertyReadMethod(String propertyName)
propertyName
- The name of the propertypublic Method getPropertyWriteMethod(String propertyName)
propertyName
- The name of the propertypublic Method getFunctionMethod(String functionName)
functionName
- The name of the propertypublic Class getLinkedClass()
public Method getJsConstructor()
getLinkedClass()
public String getHtmlClassname()
public boolean isJsObject()
Copyright © 2002-2012 Gargoyle Software Inc.. All Rights Reserved.