public class Binding extends GroovyObjectSupport
Constructor and Description |
---|
Binding() |
Binding(java.util.Map variables) |
Binding(java.lang.String[] args)
A helper constructor used in main(String[]) method calls
|
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
getProperty(java.lang.String property)
Overloaded to make variables appear as bean properties or via the subscript operator
|
java.lang.Object |
getVariable(java.lang.String name) |
java.util.Map |
getVariables() |
void |
setProperty(java.lang.String property,
java.lang.Object newValue)
Overloaded to make variables appear as bean properties or via the subscript operator
|
void |
setVariable(java.lang.String name,
java.lang.Object value)
Sets the value of the given variable
|
getMetaClass, invokeMethod, setMetaClass
public Binding()
public Binding(java.util.Map variables)
public Binding(java.lang.String[] args)
args
- are the command line arguments from a main()public java.lang.Object getVariable(java.lang.String name)
name
- the name of the variable to lookuppublic void setVariable(java.lang.String name, java.lang.Object value)
name
- the name of the variable to setvalue
- the new value for the given variablepublic java.util.Map getVariables()
public java.lang.Object getProperty(java.lang.String property)
getProperty
in interface GroovyObject
getProperty
in class GroovyObjectSupport
public void setProperty(java.lang.String property, java.lang.Object newValue)
setProperty
in interface GroovyObject
setProperty
in class GroovyObjectSupport