You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by si...@apache.org on 2011/05/13 08:17:12 UTC
svn commit: r1102571 -
/commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/binder/BeanPropertySetterBuilder.java
Author: simonetripodi
Date: Fri May 13 06:17:12 2011
New Revision: 1102571
URL: http://svn.apache.org/viewvc?rev=1102571&view=rev
Log:
first checkin of BeanPropertySetterBuilder class
Added:
commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/binder/BeanPropertySetterBuilder.java (with props)
Added: commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/binder/BeanPropertySetterBuilder.java
URL: http://svn.apache.org/viewvc/commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/binder/BeanPropertySetterBuilder.java?rev=1102571&view=auto
==============================================================================
--- commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/binder/BeanPropertySetterBuilder.java (added)
+++ commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/binder/BeanPropertySetterBuilder.java Fri May 13 06:17:12 2011
@@ -0,0 +1,58 @@
+/* $Id$
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.commons.digester3.binder;
+
+import org.apache.commons.digester3.BeanPropertySetterRule;
+
+/**
+ * Builder chained when invoking {@link LinkedRuleBuilderImpl#setBeanProperty()}.
+ */
+public final class BeanPropertySetterBuilder
+ extends AbstractBackToLinkedRuleBuilder<BeanPropertySetterRule>
+{
+
+ private String propertyName;
+
+ BeanPropertySetterBuilder( String keyPattern, String namespaceURI, RulesBinder mainBinder,
+ LinkedRuleBuilder mainBuilder )
+ {
+ super( keyPattern, namespaceURI, mainBinder, mainBuilder );
+ }
+
+ /**
+ * Sets the name of property to set.
+ *
+ * @param propertyName The name of property to set
+ * @return this builder instance
+ */
+ public BeanPropertySetterBuilder withName( /* @Nullable */String propertyName )
+ {
+ this.propertyName = propertyName;
+ return this;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ protected BeanPropertySetterRule createRule()
+ {
+ return new BeanPropertySetterRule(this.propertyName);
+ }
+
+}
Propchange: commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/binder/BeanPropertySetterBuilder.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/binder/BeanPropertySetterBuilder.java
------------------------------------------------------------------------------
svn:keywords = Date Author Id Revision HeadURL
Propchange: commons/sandbox/digester3/trunk/src/main/java/org/apache/commons/digester3/binder/BeanPropertySetterBuilder.java
------------------------------------------------------------------------------
svn:mime-type = text/plain