1 15 package org.apache.tapestry.parse; 16 17 import org.apache.hivemind.impl.BaseLocatable; 18 import org.apache.tapestry.bean.BindingBeanInitializer; 19 import org.apache.tapestry.spec.IBeanSpecification; 20 21 26 class BeanSetPropertySetter extends BaseLocatable 27 { 28 private IBeanSpecification _beanSpecification; 29 30 private BindingBeanInitializer _initializer; 31 32 private String _bindingReference; 33 34 private String _prefix; 35 36 BeanSetPropertySetter(IBeanSpecification beanSpecification, BindingBeanInitializer initializer, 37 String prefix, String expression) 38 { 39 _beanSpecification = beanSpecification; 40 _initializer = initializer; 41 _prefix = prefix; 42 _bindingReference = expression; 43 } 44 45 void applyBindingReference(String bindingReference) 46 { 47 String fullBindingReference = _prefix == null ? bindingReference : _prefix 48 + bindingReference; 49 50 _initializer.setBindingReference(fullBindingReference); 51 52 _beanSpecification.setLocation(getLocation()); 53 _beanSpecification.addInitializer(_initializer); 54 } 55 56 public String getBindingReference() 57 { 58 return _bindingReference; 59 } 60 61 } | Popular Tags |