net.vidageek.mirror.get.dsl
Interface GetterHandler

All Known Implementing Classes:
DefaultGetterHandler

public interface GetterHandler


Method Summary
 Object field(Field field)
          This part of the DSL controls which field is going to have it's value read.
 Object field(String fieldName)
          Convenience method for field(Field)
 

Method Detail

field

Object field(String fieldName)
Convenience method for field(Field)

Parameters:
fieldName - Name of the field that is going to be reflected.
Throws:
IllegalArgumentException - if fieldName is null or empty
See Also:
DefaultGetterHandler.field(Field)

field

Object field(Field field)
This part of the DSL controls which field is going to have it's value read.

Parameters:
field - Field object representing the field from which the value is going to be read.
Returns:
The value of the field represented by this field.
Throws:
IllegalArgumentException - if field is null or if field does not exists in this class/object
IllegalStateException - if you are trying to access an instance field without providing an object.
See Also:
ReflectionElementReflectionProvider.setAccessible(), FieldReflectionProvider.getValue()


Copyright © 2011 VidaGeek.net. All Rights Reserved.