Package org.apache.axis.types

Examples of org.apache.axis.types.HexBinary


        if (arg instanceof HexBinary &&
            destClass == byte[].class) {
            return ((HexBinary) arg).getBytes();
        } else if (arg instanceof byte[] &&
                   destClass == HexBinary.class) {
            return new HexBinary((byte[]) arg);
        }

        // Convert between Calendar and Date
        if (arg instanceof Calendar && destClass == Date.class) {
            return ((Calendar) arg).getTime();
View Full Code Here


    {
        if (buf != null) {
            if (javaType == byte[].class) {
                value = HexBinary.decode(buf.toString());
            } else {
                value = new HexBinary(buf.toString());
            }
        }
        super.onEndElement(namespace,localName, context);
        if (value == null) value = new HexBinary("");
    }
View Full Code Here

                    new byte[0]);
    }

    public void testHex() throws Exception {
        deserialize("<result xsi:type=\"xsd:hexBinary\">50A9</result>",
                    new HexBinary("50A9"),true);
    }
View Full Code Here

                    new HexBinary("50A9"),true);
    }

    public void testHexNull() throws Exception {
        deserialize("<result xsi:type=\"xsd:hexBinary\"></result>",
                    new HexBinary(""),true);
    }
View Full Code Here

        if (arg instanceof HexBinary &&
            destClass == byte[].class) {
            return ((HexBinary) arg).getBytes();
        } else if (arg instanceof byte[] &&
                   destClass == HexBinary.class) {
            return new HexBinary((byte[]) arg);
        }

        // Convert between Calendar and Date
        if (arg instanceof Calendar && destClass == Date.class) {
            return ((Calendar) arg).getTime();
View Full Code Here

                }
            }
        }

        {
            HexBinary input = new HexBinary("3344");
            try {
                output = binding.echoHexBinary(input.getBytes());
                verify("echoHexBinary", input, output);
            } catch (Exception e) {
                if (!testMode) {
                    verify("echoHexBinary", input, e);
                } else {
                    throw e;
                }
            }
        }
        Calendar inputDate = Calendar.getInstance();
        inputDate.setTimeZone(TimeZone.getTimeZone("GMT"));
        inputDate.setTime(new Date());
        {
            try {
                output = binding.echoDate(inputDate);
                verify("echoDate", inputDate, output);
            } catch (Exception e) {
                if (!testMode) {
                    verify("echoDate", inputDate, e);
                } else {
                    throw e;
                }
            }
        }

        {
            BigDecimal input = new BigDecimal("3.14159");
            try {
                output = binding.echoDecimal(input);
                verify("echoDecimal", input, output);
            } catch (Exception e) {
                if (!testMode) {
                    verify("echoDecimal", input, e);
                } else {
                    throw e;
                }
            }
        }

        {
            Boolean input = Boolean.TRUE;
            try {
                output = new Boolean( binding.echoBoolean(input.booleanValue()));
                verify("echoBoolean", input, output);
            } catch (Exception e) {
                if (!testMode) {
                    verify("echoBoolean", input, e);
                } else {
View Full Code Here

        if (arg instanceof HexBinary &&
            destClass == byte[].class) {
            return ((HexBinary) arg).getBytes();
        } else if (arg instanceof byte[] &&
                   destClass == HexBinary.class) {
            return new HexBinary((byte[]) arg);
        }

        // Convert between Calendar and Date
        if (arg instanceof Calendar && destClass == Date.class) {
            return ((Calendar) arg).getTime();
View Full Code Here

                    new byte[0]);
    }

    public void testHex() throws Exception {
        deserialize("<result xsi:type=\"xsd:hexBinary\">50A9</result>",
                    new HexBinary("50A9"),true);
    }
View Full Code Here

                    new HexBinary("50A9"),true);
    }

    public void testHexNull() throws Exception {
        deserialize("<result xsi:type=\"xsd:hexBinary\"></result>",
                    new HexBinary(""),true);
    }
View Full Code Here

        if (arg instanceof HexBinary &&
            destClass == byte[].class) {
            return ((HexBinary) arg).getBytes();
        } else if (arg instanceof byte[] &&
                   destClass == HexBinary.class) {
            return new HexBinary((byte[]) arg);
        }

        // Convert between Calendar and Date
        if (arg instanceof Calendar && destClass == Date.class) {
            return ((Calendar) arg).getTime();
View Full Code Here

TOP

Related Classes of org.apache.axis.types.HexBinary

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.