git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@271744 13f79535-47bb-0310-9956-ffa450edef68master
@@ -9,21 +9,18 @@ package org.apache.myrmidon.components.configurer; | |||||
/** | /** | ||||
* A default configuration state implementation. Keeps track of which | * A default configuration state implementation. Keeps track of which | ||||
* of the object's properties have been set. Also keeps track of the | |||||
* objects created by the creator methods, but not yet set by the adder | |||||
* methods. | |||||
* of the object's properties have been set. | |||||
* | * | ||||
* @author Adam Murdoch | * @author Adam Murdoch | ||||
* @version $Revision$ $Date$ | * @version $Revision$ $Date$ | ||||
*/ | */ | ||||
class DefaultConfigurationState | |||||
implements ConfigurationState | |||||
class ConfigurationState | |||||
{ | { | ||||
private final int[] m_propertyCount; | private final int[] m_propertyCount; | ||||
private final ObjectConfigurer m_configurer; | private final ObjectConfigurer m_configurer; | ||||
private final Object m_object; | private final Object m_object; | ||||
public DefaultConfigurationState( final ObjectConfigurer configurer, | |||||
public ConfigurationState( final ObjectConfigurer configurer, | |||||
final Object object, | final Object object, | ||||
final int propertyCount ) | final int propertyCount ) | ||||
{ | { |
@@ -251,7 +251,7 @@ class DefaultObjectConfigurer | |||||
public ConfigurationState startConfiguration( Object object ) | public ConfigurationState startConfiguration( Object object ) | ||||
throws ConfigurationException | throws ConfigurationException | ||||
{ | { | ||||
return new DefaultConfigurationState( this, object, m_allProps.size() ); | |||||
return new ConfigurationState( this, object, m_allProps.size() ); | |||||
} | } | ||||
/** | /** | ||||
@@ -262,7 +262,7 @@ class DefaultObjectConfigurer | |||||
throws ConfigurationException | throws ConfigurationException | ||||
{ | { | ||||
// Make sure there are no pending created objects | // Make sure there are no pending created objects | ||||
final DefaultConfigurationState defState = (DefaultConfigurationState)state; | |||||
final ConfigurationState defState = (ConfigurationState)state; | |||||
return defState.getObject(); | return defState.getObject(); | ||||
} | } | ||||
@@ -63,7 +63,7 @@ class DefaultPropertyConfigurer | |||||
public void addValue( final ConfigurationState state, final Object value ) | public void addValue( final ConfigurationState state, final Object value ) | ||||
throws ConfigurationException | throws ConfigurationException | ||||
{ | { | ||||
final DefaultConfigurationState defState = (DefaultConfigurationState)state; | |||||
final ConfigurationState defState = (ConfigurationState)state; | |||||
// Check the property count | // Check the property count | ||||
if( defState.getPropertyCount( m_propIndex ) >= m_maxCount ) | if( defState.getPropertyCount( m_propIndex ) >= m_maxCount ) | ||||