Package org.hsqldb.types

Examples of org.hsqldb.types.Binary


                    if (!(o instanceof byte[])) {
                        throw Util.sqlException(
                            Trace.error(Trace.INVALID_CONVERSION));
                    }

                    o = new Binary((byte[]) o, !connection.isNetConn);
                    break;

                case Types.DATE :
                    if (o instanceof java.util.Date) {
                        long t = HsqlDateTime.getNormalisedDate(
View Full Code Here


        if (s.length() == 0) {
            return null;
        }

        return new Binary(Column.hexToByteArray(s), false);
    }
View Full Code Here

                    if (!(o instanceof byte[])) {
                        throw Util.sqlException(
                            Trace.error(Trace.INVALID_CONVERSION));
                    }

                    o = new Binary((byte[]) o, !connection.isNetConn);
                    break;

                case Types.DATE :
                    if (o instanceof java.util.Date) {
                        long t = HsqlDateTime.getNormalisedDate(
View Full Code Here

    protected Object readOther() throws IOException, HsqlException {
        return new JavaObject(readByteArray());
    }

    protected Binary readBinary(int type) throws IOException, HsqlException {
        return new Binary(readByteArray(), false);
    }
View Full Code Here

        if (s == null) {
            return null;
        }

        return new Binary(Column.hexToByteArray(s), false);
    }
View Full Code Here

        if (s.length() == 0) {
            return null;
        }

        return new Binary(Column.hexToByteArray(s), false);
    }
View Full Code Here

                case Types.VARBINARY :
                case Types.LONGVARBINARY :
                    if (o instanceof Binary) {
                        return o;
                    } else if (o instanceof byte[]) {
                        return new Binary((byte[]) o, false);
                    } else if (o instanceof String) {

                        /**
                         * @todo fredt - we need this for script processing only
                         *  handle the script separately and process normal
                         *  conversion according to rules in SQL
                         *  standard
                         */
                        return new Binary(
                            StringConverter.hexToByte((String) o), false);
                    }

                    throw Trace.error(Trace.INVALID_CONVERSION,
                                      Types.getTypeString(type));
View Full Code Here

                    if (!(o instanceof byte[])) {
                        throw Util.sqlException(
                            Trace.error(Trace.INVALID_CONVERSION));
                    }

                    o = new Binary((byte[]) o, !connection.isNetConn);
                    break;

                case Types.DATE :
                    if (o instanceof java.util.Date) {
                        long t = HsqlDateTime.getNormalisedDate(
View Full Code Here

        if (s.length() == 0) {
            return null;
        }

        return new Binary(Column.hexToByteArray(s), false);
    }
View Full Code Here

    protected Object readOther() throws IOException, HsqlException {
        return new JavaObject(readByteArray());
    }

    protected Binary readBinary(int type) throws IOException, HsqlException {
        return new Binary(readByteArray(), false);
    }
View Full Code Here

TOP

Related Classes of org.hsqldb.types.Binary

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.