Package org.apache.jsieve

Examples of org.apache.jsieve.NumberArgument


   
    public void testASTargumentNumber() throws Exception {
        int number = 17;
        mock.expects(once()).method("argument").with(eq(number));
        ASTargument argument = new ASTargument(SieveParserTreeConstants.JJTARGUMENTS);
        argument.setValue(new NumberArgument(new Token(0, "17")));
        subject.start(argument);
        subject.end(argument);
    }
View Full Code Here


    public void start(ASTargument node) throws HaltTraversalException {
        final Object value = node.getValue();
        if (value == null) {
            LOG.debug("Ignoring null argument");
        } else if (value instanceof NumberArgument) {
            final NumberArgument numberArgument = (NumberArgument) value;
            Integer integer = numberArgument.getInteger();
            if (integer == null) {
                LOG.debug("Ignoring null numeric argument");
            } else {
                final int number = integer.intValue();
                handler.argument(number);
View Full Code Here

TOP

Related Classes of org.apache.jsieve.NumberArgument

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.