Examples of JIntLiteral


Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

      JsonObject jsonObject = new JsonObject(sourceInfo,
          program.getJavaScriptObject());
      // Start at 1; 0 is Object and always true.
      for (int i = 1; i < nextQueryId; ++i) {
        if (yesArray[i] != null) {
          JIntLiteral labelExpr = program.getLiteralInt(i);
          JIntLiteral valueExpr = program.getLiteralInt(1);
          jsonObject.propInits.add(new JsonPropInit(sourceInfo, labelExpr,
              valueExpr));
        }
      }
View Full Code Here

Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

          // override the type of the called method with the target cast type
          JMethodCall call = new JMethodCall(x.getSourceInfo(), null, method,
              toType);
          call.addArg(curExpr);
          if (!isJsoCast) {
            JIntLiteral qId = program.getLiteralInt(queryIds.get(refType));
            call.addArg(qId);
          }
          replaceExpr = call;
        }
      } else {
View Full Code Here

Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

          method = program.getIndexedMethod("Cast.instanceOf");
        }
        JMethodCall call = new JMethodCall(x.getSourceInfo(), null, method);
        call.addArg(x.getExpr());
        if (!isJsoCast) {
          JIntLiteral qId = program.getLiteralInt(queryIds.get(toType));
          call.addArg(qId);
        }
        ctx.replaceMe(call);
      }
    }
View Full Code Here

Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

      // create a sparse lookup object
      JsonObject jsonObject = new JsonObject(program);
      for (int i = 0; i < nextQueryId; ++i) {
        if (yesArray[i] != null) {
          JIntLiteral labelExpr = program.getLiteralInt(i);
          JIntLiteral valueExpr = program.getLiteralInt(1);
          jsonObject.propInits.add(new JsonPropInit(program, labelExpr,
              valueExpr));
        }
      }
View Full Code Here

Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

          JMethod method = program.getSpecialMethod("Cast.dynamicCast");
          // override the type of the called method with the target cast type
          JMethodCall call = new JMethodCall(program, x.getSourceInfo(), null,
              method, toType);
          Integer boxedInt = (Integer) queryIds.get(refType);
          JIntLiteral qId = program.getLiteralInt(boxedInt.intValue());
          call.getArgs().add(curExpr);
          call.getArgs().add(qId);
          replaceExpr = call;
        }
      } else {
View Full Code Here

Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

      } else {
        JMethod method = program.getSpecialMethod("Cast.instanceOf");
        JMethodCall call = new JMethodCall(program, x.getSourceInfo(), null,
            method);
        Integer boxedInt = (Integer) queryIds.get(x.getTestType());
        JIntLiteral qId = program.getLiteralInt(boxedInt.intValue());
        call.getArgs().add(x.getExpr());
        call.getArgs().add(qId);
        ctx.replaceMe(call);
      }
    }
View Full Code Here

Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

      // Create a sparse lookup object.
      JsonObject jsonObject = new JsonObject(program);
      // Start at 1; 0 is Object and always true.
      for (int i = 1; i < nextQueryId; ++i) {
        if (yesArray[i] != null) {
          JIntLiteral labelExpr = program.getLiteralInt(i);
          JIntLiteral valueExpr = program.getLiteralInt(1);
          jsonObject.propInits.add(new JsonPropInit(program, labelExpr,
              valueExpr));
        }
      }
View Full Code Here

Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

          // override the type of the called method with the target cast type
          JMethodCall call = new JMethodCall(program, x.getSourceInfo(), null,
              method, toType);
          call.getArgs().add(curExpr);
          if (!isJsoCast) {
            JIntLiteral qId = program.getLiteralInt(queryIds.get(refType));
            call.getArgs().add(qId);
          }
          replaceExpr = call;
        }
      } else {
View Full Code Here

Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

            ? "Cast.instanceOfJso" : "Cast.instanceOf");
        JMethodCall call = new JMethodCall(program, x.getSourceInfo(), null,
            method);
        call.getArgs().add(x.getExpr());
        if (!isJsoCast) {
          JIntLiteral qId = program.getLiteralInt(queryIds.get(toType));
          call.getArgs().add(qId);
        }
        ctx.replaceMe(call);
      }
    }
View Full Code Here

Examples of com.google.gwt.dev.jjs.ast.JIntLiteral

      JLiteral classLit = x.getLeafTypeClassLiteral();
      JExpression castableTypeMap = getOrCreateCastMap(sourceInfo, arrayType);
      JRuntimeTypeReference arrayElementRuntimeTypeReference =
          getElementRuntimeTypeReference(sourceInfo, arrayType);
      JType elementType = arrayType.getElementType();
      JIntLiteral elementTypeCategory = getTypeCategoryLiteral(elementType);
      JExpression dim = x.dims.get(0);
      call.addArgs(classLit, castableTypeMap, arrayElementRuntimeTypeReference, dim,
          elementTypeCategory, program.getLiteralInt(arrayType.getDims()));
      ctx.replaceMe(call);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.