Package org.codehaus.dna

Examples of org.codehaus.dna.ConfigurationException


            return m_value;
        }
        else
        {
            final String message = "No value specified";
            throw new ConfigurationException( message, getPath(), getLocation() );
        }
    }
View Full Code Here


        }
        catch( final NumberFormatException nfe )
        {
            final String message =
                "Unable to parse " + getValue() + " as an integer";
            throw new ConfigurationException( message, getPath(), getLocation(), nfe );
        }
    }
View Full Code Here

        }
        catch( final NumberFormatException nfe )
        {
            final String message =
                "Unable to parse " + getValue() + " as a Long";
            throw new ConfigurationException( message, getPath(), getLocation(), nfe );
        }
    }
View Full Code Here

        }
        catch( final NumberFormatException nfe )
        {
            final String message =
                "Unable to parse " + getValue() + " as a Long";
            throw new ConfigurationException( message, getPath(), getLocation(), nfe );
        }
    }
View Full Code Here

        }
        else
        {
            final String message =
                "Attribute named " + name + " not specified.";
            throw new ConfigurationException( message, getPath(), getLocation() );
        }
    }
View Full Code Here

        }
        catch( final NumberFormatException nfe )
        {
            final String message =
                "Unable to parse " + value + " as an Integer.";
            throw new ConfigurationException( message, getPath(), getLocation() );
        }
    }
View Full Code Here

        }
        catch( final NumberFormatException nfe )
        {
            final String message =
                "Unable to parse " + value + " as a Long.";
            throw new ConfigurationException( message, getPath(), getLocation() );
        }
    }
View Full Code Here

        }
        catch( final NumberFormatException nfe )
        {
            final String message =
                "Unable to parse " + value + " as a Float.";
            throw new ConfigurationException( message, getPath(), getLocation() );
        }
    }
View Full Code Here

    {
        final String message = "myMessage";
        final String path = "/my/path";
        final String location = "mylocation.xml:20";
        final Throwable cause = new Throwable();
        final ConfigurationException exception =
            new ConfigurationException( message, path, location, cause );

        assertEquals( "message", message, exception.getMessage() );
        assertEquals( "path", path, exception.getPath() );
        assertEquals( "location", location, exception.getLocation() );
        assertEquals( "cause", cause, exception.getCause() );
    }
View Full Code Here

    {
        final String message = "myMessage";
        final String path = "/my/path";
        final String location = "mylocation.xml:20";
        final Throwable cause = null;
        final ConfigurationException exception =
            new ConfigurationException( message, path, location, cause );

        assertEquals( "message", message, exception.getMessage() );
        assertEquals( "path", path, exception.getPath() );
        assertEquals( "location", location, exception.getLocation() );
        assertEquals( "cause", cause, exception.getCause() );
    }
View Full Code Here

TOP

Related Classes of org.codehaus.dna.ConfigurationException

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.