Package org.apache.tapestry.ioc.util

Examples of org.apache.tapestry.ioc.util.BodyBuilder.end()


            previousStep = thisStep;
        }

        builder.addln("return %s;", previousStep);

        builder.end();

        if (writeOnly)
        {
            builder.clear();
            builder
View Full Code Here


        if (parameterType != wrapperType)
            builder.add(".%s()", ClassFabUtils.getUnwrapMethodName(parameterType.getName()));

        builder.addln(");");

        builder.end();

        classFab.addMethod(Modifier.PUBLIC, SET_SIGNATURE, builder.toString());

        return writeMethod;
    }
View Full Code Here

        // Fields yes, but no annotations, so nothing to really do.

        if (count == 0) return;

        builder.end();

        transformation.extendMethod(TransformConstants.CONTAINING_PAGE_DID_LOAD_SIGNATURE, builder
                .toString());
    }
View Full Code Here

        BodyBuilder builder = new BodyBuilder();
        builder.begin();
        builder.addln("%s.run();", name);
        builder.addln("return $_ + 1;");
        builder.end();

        ct.extendExistingMethod(sig, builder.toString());

        ct.finish();
View Full Code Here

        // If no matches

        if (assetSourceFieldName == null)
            return;

        builder.end();

        transformation.extendConstructor(builder.toString());

    }
}
View Full Code Here

        // In reverse order in a a subclass, invoke the super method last.

        if (_reverse && !model.isRootClass())
            builder.addln("super.%s($$);", _lifecycleMethodName);

        builder.end();

        // Let's see if this works; for base classes, we are adding an empty method the adding a
        // non-empty
        // method "on top of it".
View Full Code Here

            previousStep = thisStep;
        }

        builder.addln("return %s;", previousStep);

        builder.end();

        if (writeOnly)
        {
            builder.clear();
            builder
View Full Code Here

        if (parameterType != wrapperType)
            builder.add(".%s()", ClassFabUtils.getUnwrapMethodName(parameterType.getName()));

        builder.addln(");");

        builder.end();

        classFab.addMethod(Modifier.PUBLIC, SET_SIGNATURE, builder.toString());

        return writeMethod;
    }
View Full Code Here

        builder.addln("if ($1.isAborted()) return $_;");

        for (MethodSignature method : methods)
            addCodeForMethod(builder, method, transformation);

        builder.end();

        transformation.extendMethod(TransformConstants.HANDLE_COMPONENT_EVENT, builder.toString());
    }

    private void addCodeForMethod(BodyBuilder builder, MethodSignature method,
View Full Code Here

            previousStep = thisStep;
        }

        builder.addln("return %s;", previousStep);

        builder.end();

        if (writeOnly)
        {
            builder.clear();
            builder
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.