1 22 package org.jboss.joinpoint.plugins; 23 24 import org.jboss.joinpoint.spi.FieldSetJoinpoint; 25 import org.jboss.reflect.spi.FieldInfo; 26 27 32 public class BasicFieldSetJoinPoint extends BasicTargettedJoinPoint implements FieldSetJoinpoint 33 { 34 35 protected FieldInfo fieldInfo; 36 37 38 protected Object value; 39 40 45 public BasicFieldSetJoinPoint(FieldInfo fieldInfo) 46 { 47 this.fieldInfo = fieldInfo; 48 } 49 50 public FieldInfo getFieldInfo() 51 { 52 return fieldInfo; 53 } 54 55 60 public Object getValue() 61 { 62 return value; 63 } 64 65 public void setValue(Object value) 66 { 67 this.value = value; 68 } 69 70 public Object dispatch() throws Throwable 71 { 72 return fieldInfo.set(target, value); 73 } 74 75 public String toHumanReadableString() 76 { 77 return "SET " + fieldInfo.toString(); 78 } 79 } 80 | Popular Tags |