Package javolution.text

Examples of javolution.text.CharArray.toLong()


         *         the default value if the attribute is not found.
         */
        public long getAttribute(String name, long defaultValue)
                throws XMLStreamException {
            CharArray value = getAttribute(name);
            return (value != null) ? value.toLong() : defaultValue;
        }

        /**
         * Returns the specified <code>float</code> attribute.
         *
 
View Full Code Here


         *         the default value if the attribute is not found.
         */
        public long getAttribute(String name, long defaultValue)
                throws XMLStreamException {
            CharArray value = getAttribute(name);
            return (value != null) ? value.toLong() : defaultValue;
        }

        /**
         * Returns the specified <code>float</code> attribute.
         *
 
View Full Code Here

        return value != null ? Integer.valueOf( value.toInt() ) : defaultValue;
    }

    private Long getAttribute( final InputElement input, final String name, final Long defaultValue ) throws XMLStreamException {
        final CharArray value = input.getAttribute( name );
        return value != null ? Long.valueOf( value.toLong() ) : defaultValue;
    }

    private Short getAttribute( final InputElement input, final String name, final Short defaultValue ) throws XMLStreamException {
        final CharArray value = input.getAttribute( name );
        return value != null ? Short.valueOf( TypeFormat.parseShort( value ) ) : defaultValue;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.