Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## groovy.model
Class ClosureModel

    java.lang.Object
      groovy.model.ClosureModel

All Implemented Interfaces:
  NestedValueModel, ValueModel

    public class ClosureModel

extends Object
implements ValueModel, NestedValueModel

Represents a value model using a closure to extract the value from some source model and an optional write closure for updating the value.

Version:
  $Revision: 7922 $
Author:
  James Strachan

Constructor Summary
`ClosureModel(ValueModel sourceModel, Closure readClosure)`
`ClosureModel(ValueModel sourceModel, Closure readClosure, Closure writeClosure)`
`ClosureModel(ValueModel sourceModel, Closure readClosure, Closure writeClosure, Class type)`

Method Summary
`ValueModel` | `getSourceModel()`
`Class` | `getType()`
`Object` | `getValue()`
`boolean` | `isEditable()`
`void` | `setValue(Object value)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ClosureModel

    public ClosureModel(ValueModel sourceModel,
                        Closure readClosure)

### ClosureModel

    public ClosureModel(ValueModel sourceModel,
                        Closure readClosure,
                        Closure writeClosure)

### ClosureModel

    public ClosureModel(ValueModel sourceModel,
                        Closure readClosure,
                        Closure writeClosure,
                        Class type)

Method Detail

### getSourceModel

    public ValueModel getSourceModel()

  Specified by:
    `getSourceModel` in interface `NestedValueModel`

### getValue

    public Object getValue()

  Specified by:
    `getValue` in interface `ValueModel`

### setValue

    public void setValue(Object value)

  Specified by:
    `setValue` in interface `ValueModel`

### getType

    public Class getType()

  Specified by:
    `getType` in interface `ValueModel`

### isEditable

    public boolean isEditable()

  Specified by:
    `isEditable` in interface `ValueModel`

Overview | Package | Class | Tree | Deprecated | Index | Help
| Copyright © 2003-2008 The Codehaus. All rights reserved.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD