Save This Page
Home » groovy-src-1.6.3 » groovy » lang » [javadoc | source]
groovy.lang
public class: Binding [javadoc | source]
java.lang.Object
   groovy.lang.GroovyObjectSupport
      groovy.lang.Binding

All Implemented Interfaces:
    GroovyObject

Direct Known Subclasses:
    ObjectGraphBuilder, ServletBinding, FactoryBuilderSupport

Represents the variable bindings of a script which can be altered from outside the script object or created outside of a script and passed into it.
Constructor:
 public Binding() 
 public Binding(Map variables) 
 public Binding(String[] args) 
    A helper constructor used in main(String[]) method calls
    Parameters:
    args - are the command line arguments from a main()
Method from groovy.lang.Binding Summary:
getProperty,   getVariable,   getVariables,   setProperty,   setVariable
Methods from groovy.lang.GroovyObjectSupport:
getMetaClass,   getProperty,   invokeMethod,   setMetaClass,   setProperty
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from groovy.lang.Binding Detail:
 public Object getProperty(String property) 
    Overloaded to make variables appear as bean properties or via the subscript operator
 public Object getVariable(String name) 
 public Map getVariables() 
 public  void setProperty(String property,
    Object newValue) 
    Overloaded to make variables appear as bean properties or via the subscript operator
 public  void setVariable(String name,
    Object value) 
    Sets the value of the given variable