*/
private PluginConfiguration parsePluginConfiguration( XmlPullParser parser, boolean strict, InputSource source )
throws IOException, XmlPullParserException
{
String tagName = parser.getName();
PluginConfiguration pluginConfiguration = new PluginConfiguration();
InputLocation _location;
_location = new InputLocation( parser.getLineNumber(), parser.getColumnNumber(), source );
pluginConfiguration.setLocation( "", _location );
for ( int i = parser.getAttributeCount() - 1; i >= 0; i-- )
{
String name = parser.getAttributeName( i );
String value = parser.getAttributeValue( i );
if ( name.indexOf( ':' ) >= 0 )
{
// just ignore attributes with non-default namespace (for example: xmlns:xsi)
}
else
{
checkUnknownAttribute( parser, name, tagName, strict );
}
}
java.util.Set parsed = new java.util.HashSet();
while ( ( strict ? parser.nextTag() : nextTag( parser ) ) == XmlPullParser.START_TAG )
{
if ( checkFieldWithDuplicate( parser, "pluginManagement", null, parsed ) )
{
pluginConfiguration.setPluginManagement( parsePluginManagement( parser, strict, source ) );
}
else if ( checkFieldWithDuplicate( parser, "plugins", null, parsed ) )
{
java.util.List plugins = new java.util.ArrayList/*<Plugin>*/();
pluginConfiguration.setPlugins( plugins );
while ( parser.nextTag() == XmlPullParser.START_TAG )
{
if ( "plugin".equals( parser.getName() ) )
{
plugins.add( parsePlugin( parser, strict, source ) );