Package org.codehaus.plexus.util.xml.pull

Examples of org.codehaus.plexus.util.xml.pull.XmlPullParserException


            {
                resourceDesc.setFiltered( getValueFilteredAttribute( resource.getAttribute( "filtered" ) ) );
            }
            catch ( IllegalArgumentException iae )
            {
                throw new XmlPullParserException( iae.getMessage() );
            }
        }

        if ( resource.getAttribute( "encoding" ) != null )
        {
            TemplateDescriptor resourceDesc = descriptor.getResourceDescriptor( resource.getValue() );

            try
            {
                resourceDesc.setEncoding( resource.getAttribute( "encoding" ) );
            }
            catch ( IllegalCharsetNameException icne )
            {
                throw new XmlPullParserException( resource.getAttribute( "encoding" ) + " is not a valid encoding." );
            }
            catch ( UnsupportedCharsetException uce )
            {
                throw new XmlPullParserException(
                    resource.getAttribute( "encoding" ) + " is not a supported encoding." );
            }
        }

        if ( resource.getValue().endsWith( ".properties" ) )
View Full Code Here


            {
                testSourceDesc.setEncoding( testSource.getAttribute( "encoding" ) );
            }
            catch ( IllegalCharsetNameException icne )
            {
                throw new XmlPullParserException( testSource.getAttribute( "encoding" ) + " is not a valid encoding." );
            }
            catch ( UnsupportedCharsetException uce )
            {
                throw new XmlPullParserException(
                    testSource.getAttribute( "encoding" ) + " is not a supported encoding." );
            }
        }
    }
View Full Code Here

            {
                testResourceDesc.setFiltered( getValueFilteredAttribute( testResource.getAttribute( "filtered" ) ) );
            }
            catch ( IllegalArgumentException iae )
            {
                throw new XmlPullParserException( iae.getMessage() );
            }
        }

        if ( testResource.getAttribute( "encoding" ) != null )
        {
            TemplateDescriptor testResourceDesc = descriptor.getTestResourceDescriptor( testResource.getValue() );

            try
            {
                testResourceDesc.setEncoding( testResource.getAttribute( "encoding" ) );

            }
            catch ( IllegalCharsetNameException icne )
            {
                throw new XmlPullParserException(
                    testResource.getAttribute( "encoding" ) + " is not a valid encoding." );
            }
            catch ( UnsupportedCharsetException uce )
            {
                throw new XmlPullParserException(
                    testResource.getAttribute( "encoding" ) + " is not a supported encoding." );
            }
        }

        if ( testResource.getValue().endsWith( ".properties" ) )
View Full Code Here

            {
                siteResourceDesc.setFiltered( getValueFilteredAttribute( siteResource.getAttribute( "filtered" ) ) );
            }
            catch ( IllegalArgumentException iae )
            {
                throw new XmlPullParserException( iae.getMessage() );
            }
        }
        if ( siteResource.getAttribute( "encoding" ) != null )
        {
            TemplateDescriptor siteResourceDesc = descriptor.getSiteResourceDescriptor( siteResource.getValue() );

            try
            {
                siteResourceDesc.setEncoding( siteResource.getAttribute( "encoding" ) );
            }
            catch ( IllegalCharsetNameException icne )
            {
                throw new XmlPullParserException(
                    siteResource.getAttribute( "encoding" ) + " is not a valid encoding." );
            }
            catch ( UnsupportedCharsetException uce )
            {
                throw new XmlPullParserException(
                    siteResource.getAttribute( "encoding" ) + " is not a supported encoding." );
            }
        }
        if ( siteResource.getValue().endsWith( ".properties" ) )
        {
View Full Code Here

                {
                    return dateParser.parse( s );
                }
                catch ( java.text.ParseException e )
                {
                    throw new XmlPullParserException( e.getMessage() );
                }
            }
        }
        return null;
    } //-- java.util.Date getDateValue(String, String, String, XmlPullParser)
View Full Code Here

            }
            catch ( NumberFormatException e )
            {
                if ( strict )
                {
                    throw new XmlPullParserException( "Unable to parse element '" + attribute + "', must be a floating point number", parser, null );
                }
            }
        }
        return 0;
    } //-- double getDoubleValue(String, String, XmlPullParser, boolean)
View Full Code Here

            }
            catch ( NumberFormatException e )
            {
                if ( strict )
                {
                    throw new XmlPullParserException( "Unable to parse element '" + attribute + "', must be a floating point number", parser, null );
                }
            }
        }
        return 0;
    } //-- float getFloatValue(String, String, XmlPullParser, boolean)
View Full Code Here

            }
            catch ( NumberFormatException e )
            {
                if ( strict )
                {
                    throw new XmlPullParserException( "Unable to parse element '" + attribute + "', must be an integer", parser, null );
                }
            }
        }
        return 0;
    } //-- int getIntegerValue(String, String, XmlPullParser, boolean)
View Full Code Here

            }
            catch ( NumberFormatException e )
            {
                if ( strict )
                {
                    throw new XmlPullParserException( "Unable to parse element '" + attribute + "', must be a long integer", parser, null );
                }
            }
        }
        return 0;
    } //-- long getLongValue(String, String, XmlPullParser, boolean)
View Full Code Here

    {
        if ( s == null )
        {
            if ( strict )
            {
                throw new XmlPullParserException( "Missing required value for attribute '" + attribute + "'", parser, null );
            }
        }
        return s;
    } //-- String getRequiredAttributeValue(String, String, XmlPullParser, boolean)
View Full Code Here

TOP

Related Classes of org.codehaus.plexus.util.xml.pull.XmlPullParserException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.