Package org.jboss.errai.codegen

Examples of org.jboss.errai.codegen.Statement.generate()


    final Statement internedStatement = context.intern(this);

    if (internedStatement != null) {
      boolean permissiveMode = GenUtil.isPermissiveMode();
      GenUtil.setPermissiveMode(true);
      String s = internedStatement.generate(context);
      GenUtil.setPermissiveMode(permissiveMode);
      return s;
    }
    else {
      return getCanonicalString(context);
View Full Code Here


      final MetaClass type = defParms[i].getType();
      final Statement s = Cast.to(type, Stmt.loadVariable(parameterArrayVarName, i));
      params.add(new Statement() {
        @Override
        public String generate(Context context) {
          return s.generate(context);
        }

        @Override
        public MetaClass getType() {
          return type;
View Full Code Here

      final MetaClass type = defParms[i].getType();
      final Statement s = Cast.to(type, Stmt.loadVariable(parameterArrayVarName, i));
      params.add(new Statement() {
        @Override
        public String generate(Context context) {
          return s.generate(context);
        }

        @Override
        public MetaClass getType() {
          return type;
View Full Code Here

      if (element.getClass().isArray()) {
        generateInitialization(context, buf, element);
      }
      else {
        Statement statement = GenUtil.generate(context, element);
        String statementExpr = statement.generate(context);
        GenUtil.assertAssignableTypes(statement.getType(), componentType);
        buf.append(statementExpr);
      }
      if (i + 1 < length) {
        buf.append(", ");
View Full Code Here

      if (element.getClass().isArray()) {
        generateInitialization(context, buf, element);
      }
      else {
        Statement statement = GenUtil.generate(context, element);
        String statementExpr = statement.generate(context);
        GenUtil.assertAssignableTypes(statement.getType(), componentType);
        buf.append(statementExpr);
      }
      if (i + 1 < length) {
        buf.append(", ");
View Full Code Here

      if (element.getClass().isArray()) {
        generateInitialization(context, buf, element);
      }
      else {
        Statement statement = GenUtil.generate(context, element);
        String statementExpr = statement.generate(context);
        GenUtil.assertAssignableTypes(context, statement.getType(), componentType);
        buf.append(statementExpr);
      }
      if (i + 1 < length) {
        buf.append(", ");
View Full Code Here

      final MetaClass type = defParms[i].getType().asBoxed();
      final Statement s = Cast.to(type, Stmt.loadVariable(parameterArrayVarName, i));
      params.add(new Statement() {
        @Override
        public String generate(Context context) {
          return s.generate(context);
        }

        @Override
        public MetaClass getType() {
          return type;
View Full Code Here

  @Override
  public String generate(final Context context) {
    final Statement internedStatement = context.intern(this);

    if (internedStatement != null) {
      return internedStatement.generate(context);
    }
    else {
      return getCanonicalString(context);
    }
  }
View Full Code Here

      final MetaClass type = defParms[i].getType();
      final Statement s = Cast.to(type, Stmt.loadVariable(parameterArrayVarName, i));
      params.add(new Statement() {
        @Override
        public String generate(Context context) {
          return s.generate(context);
        }

        @Override
        public MetaClass getType() {
          return type;
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.