Package macromedia.asc.util

Examples of macromedia.asc.util.IntNumberConstant


        if (!force && isInt) {
            // value is integral.  See if it fits in a smaller type
            long ival = dval.longValue();
            if ((Integer.MIN_VALUE <= ival) && (ival <= Integer.MAX_VALUE)) {
                ppType[0] = cx.intType();
                return new IntNumberConstant((int)ival);
            }
            else if ((0 <= ival) && (ival <= MAXUINT)) {
                ppType[0] = cx.uintType();
                return new UintNumberConstant(ival);
            }
View Full Code Here


        if (!force && isInt) {
            // value is integral.  See if it fits in a smaller type
            long ival = (long)sum;
            if ((Integer.MIN_VALUE <= ival) && (ival <= Integer.MAX_VALUE)) {
                ppType[0] = cx.intType();
                return new IntNumberConstant((int)ival);
            }
            // don't make it uint unless ES4
            else if (cx.statics.es4_numerics && (0 <= ival) && (ival <= MAXUINT)) {
                ppType[0] = cx.uintType();
                return new UintNumberConstant(ival);
View Full Code Here

           
        if (forceType) {
            ppType[0] = ftype; // either int or uint at this point
            if (ftype == cx.intType()) {
                if (!(result instanceof IntNumberConstant))
                    result = new IntNumberConstant(result.intValue());
            }
            else { // ftype == cx.uintType()
                if (!(result instanceof UintNumberConstant))
                    result = new UintNumberConstant(result.uintValue());
            }
View Full Code Here

        FindProperty("Vector", new Namespaces(cx.getNamespace("__AS3__.vec")), true/*is_strict*/, false /*is_qualified*/, false /*is_attribute*/);
        node.type.evaluate(cx, this);

        int n_elements = (null == node.elementlist)? 0:node.elementlist.size();
       
        PushNumber(new IntNumberConstant(n_elements), cx.intType().getTypeId());
        InvokeClosure(true /* construct */,1);
       
        if (node.elementlist != null)
        {
          Namespaces elements_nss  = new Namespaces();
          elements_nss.add(cx.publicNamespace());
         
          for (int i = 0, size = node.elementlist.items.size(); i < size; i++)
            {
              Node item = node.elementlist.items.get(i);
              //  Keep the new Vector on the stack
              Dup();
             
              //  Push the index
              PushNumber(new IntNumberConstant(i), cx.intType().getTypeId());
             
              //  Push the value
                item.evaluate(cx, this);
               
                //  setproperty with null operand => use indexed access
View Full Code Here

        // Prep for finally block if present
        if (node.finallyblock != null)
        {
            // Jump index
            PushNumber(new IntNumberConstant(-1), TYPE_int);

            CatchClausesBegin();

            exceptionState.finallyPresent = true;
            node.finallyblock.default_catch.evaluate(cx, this);
View Full Code Here

        }


        if (isFinallyPresent())
        {
            PushNumber(new IntNumberConstant(-1), TYPE_int);
        }


        PopScope();
        freeTemp(temp_activation_reg);
View Full Code Here

        FindProperty("Vector", new Namespaces(cx.getNamespace("__AS3__.vec")), true/*is_strict*/, false /*is_qualified*/, false /*is_attribute*/);
        node.type.evaluate(cx, this);

        int n_elements = (null == node.elementlist)? 0:node.elementlist.size();
       
        PushNumber(new IntNumberConstant(n_elements), cx.intType().getTypeId());
        InvokeClosure(true /* construct */,1);
       
        if (node.elementlist != null)
        {
          Namespaces elements_nss  = new Namespaces();
          elements_nss.add(cx.publicNamespace());
         
          for (int i = 0, size = node.elementlist.items.size(); i < size; i++)
            {
              Node item = node.elementlist.items.get(i);
              //  Keep the new Vector on the stack
              Dup();
             
              //  Push the index
              PushNumber(new IntNumberConstant(i), cx.intType().getTypeId());
             
              //  Push the value
                item.evaluate(cx, this);
               
                //  setproperty with null operand => use indexed access
View Full Code Here

        // Prep for finally block if present
        if (node.finallyblock != null)
        {
            // Jump index
            PushNumber(new IntNumberConstant(-1), TYPE_int);

            CatchClausesBegin();

            exceptionState.finallyPresent = true;
            node.finallyblock.default_catch.evaluate(cx, this);
View Full Code Here

        }


        if (isFinallyPresent())
        {
            PushNumber(new IntNumberConstant(-1), TYPE_int);
        }


        PopScope();
        freeTemp(temp_activation_reg);
View Full Code Here

        if (!force && isInt) {
            // value is integral.  See if it fits in a smaller type
            long ival = dval.longValue();
            if ((Integer.MIN_VALUE <= ival) && (ival <= Integer.MAX_VALUE)) {
                ppType[0] = cx.intType();
                return new IntNumberConstant((int)ival);
            }
            else if ((0 <= ival) && (ival <= MAXUINT)) {
                ppType[0] = cx.uintType();
                return new UintNumberConstant(ival);
            }
View Full Code Here

TOP

Related Classes of macromedia.asc.util.IntNumberConstant

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.