gate.util.spring
Class SetParameterResourceCustomiser

java.lang.Object
  extended by gate.util.spring.SetParameterResourceCustomiser
All Implemented Interfaces:
ResourceCustomiser

public class SetParameterResourceCustomiser
extends Object
implements ResourceCustomiser

ResourceCustomiser that sets a parameter on the resource being customised. When used to customise Controllers, it can optionally take a "prName" property. In this case it will set the parameter on the first PR with that name in the controller, rather than the controller itself


Field Summary
private  String paramName
           
private  String prName
           
private  Object value
           
 
Constructor Summary
SetParameterResourceCustomiser()
           
 
Method Summary
 void customiseResource(Resource res)
           
 void setParamName(String paramName)
           
 void setPrName(String prName)
           
 void setValue(Object value)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

paramName

private String paramName

value

private Object value

prName

private String prName
Constructor Detail

SetParameterResourceCustomiser

public SetParameterResourceCustomiser()
Method Detail

customiseResource

public void customiseResource(Resource res)
                       throws Exception
Specified by:
customiseResource in interface ResourceCustomiser
Throws:
Exception

setParamName

public void setParamName(String paramName)

setValue

public void setValue(Object value)

setPrName

public void setPrName(String prName)