Package prefuse.data

Examples of prefuse.data.DataTypeException


            if ( val instanceof Number ) {
                setLong(((Number)val).longValue(), row);
            } else if ( val instanceof String ) {
                setString((String)val, row);
            } else {
                throw new DataTypeException(val.getClass());
            }
        } else {
            throw new DataTypeException("Column does not accept null values");
        }
    }
View Full Code Here


            if ( val instanceof Number ) {
                setDouble(((Number)val).doubleValue(), row);
            } else if ( val instanceof String ) {
                setString((String)val, row);
            } else {
                throw new DataTypeException(val.getClass());
            }
        } else {
            throw new DataTypeException("Column does not accept null values");
        }
    }
View Full Code Here

        else if ( type == byte.class
                    || type == short.class
                    || type == char.class
                    || type == void.class )
        {
            throw new DataTypeException(type);
        }
        else
        {
            return new ObjectColumn(type, nrows, nrows, defaultValue);
        }
View Full Code Here

            if ( val instanceof Number ) {
                setInt(((Number)val).byteValue(), row);
            } else if ( val instanceof String ) {
                setString((String)val, row);
            } else {
                throw new DataTypeException(val.getClass());
            }
        } else {
            throw new DataTypeException("Column does not accept null values");
        }
    }
View Full Code Here

            } else if ( val instanceof Number ) {
                setLong(((Number)val).longValue(), row);
            } else if ( val instanceof String ) {
                setString((String)val, row);
            } else {
                throw new DataTypeException(val.getClass());
            }
        } else {
            throw new DataTypeException("Column does not accept null values");
        }
    }
View Full Code Here

     */
    public int getInt(int row) throws DataTypeException {
        if ( canGetInt() ) {
            return ((Integer)get(row)).intValue();
        } else {
            throw new DataTypeException(int.class);
        }
    }
View Full Code Here

     */
    public void setInt(int val, int row) throws DataTypeException {
        if ( canSetInt() ) {
            set(new Integer(val), row);
        } else {
            throw new DataTypeException(int.class);
        }
    }
View Full Code Here

     */
    public long getLong(int row) throws DataTypeException {
        if ( canGetLong() ) {
            return ((Long)get(row)).longValue();
        } else {
            throw new DataTypeException(long.class);
        }
    }
View Full Code Here

     */
    public void setLong(long val, int row) throws DataTypeException {
        if ( canSetLong() ) {
            set(new Long(val), row);
        } else {
            throw new DataTypeException(long.class);
        }
    }
View Full Code Here

     */
    public float getFloat(int row) throws DataTypeException {
        if ( canGetFloat() ) {
            return ((Float)get(row)).floatValue();
        } else {
            throw new DataTypeException(float.class);
        }
    }
View Full Code Here

TOP

Related Classes of prefuse.data.DataTypeException

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.