Examples of AttributeBuilder


Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

            members.add(createStageInputsMethod());
            members.add(createStageOutputsMethod());
            members.addAll(createShuffleMethods());
            return factory.newClassDeclaration(
                    createJavadoc(),
                    new AttributeBuilder(factory)
                        .annotation(t(TraceLocation.class), createTraceLocationElements())
                        .Public()
                        .Final()
                        .toAttributes(),
                    name,
View Full Code Here

Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

            statements.add(new ExpressionBuilder(factory, list)
                .toReturnStatement());

            return factory.newMethodDeclaration(
                    null,
                    new AttributeBuilder(factory)
                        .annotation(t(Override.class))
                        .Protected()
                        .toAttributes(),
                    t(List.class, t(StageInput.class)),
                    factory.newSimpleName(AbstractStageClient.METHOD_STAGE_INPUTS),
View Full Code Here

Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

            return factory.newClassDeclaration(
                    new JavadocBuilder(factory)
                        .text("ステージ{0}の処理を担当するコンバイナープログラム。",
                                shuffle.getStageBlock().getStageNumber())
                        .toJavadoc(),
                    new AttributeBuilder(factory)
                        .annotation(t(SuppressWarnings.class), v("deprecation"))
                        .Public()
                        .Final()
                        .toAttributes(),
                    name,
View Full Code Here

Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

            statements.add(new ExpressionBuilder(factory, list)
                .toReturnStatement());

            return factory.newMethodDeclaration(
                    null,
                    new AttributeBuilder(factory)
                        .annotation(t(Override.class))
                        .Protected()
                        .toAttributes(),
                    t(List.class, t(StageOutput.class)),
                    factory.newSimpleName(AbstractStageClient.METHOD_STAGE_OUTPUTS),
View Full Code Here

Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

                SimpleName shuffleName = names.create("shuffle");
                shuffleNames.put(segment, shuffleName);
                Name shuffleTypeName = segment.getCompiled().getCombineOutputType().getQualifiedName();
                fields.add(factory.newFieldDeclaration(
                        null,
                        new AttributeBuilder(factory)
                            .Private()
                            .toAttributes(),
                        importer.toType(shuffleTypeName),
                        shuffleName,
                        null));
            }

            // rendezvous
            for (ReduceUnit unit : reduceUnits) {
                if (unit.canCombine() == false) {
                    continue;
                }
                Fragment first = unit.getFragments().get(0);
                SimpleName rendezvousName = names.create("combine");
                rendezvousNames.put(first, rendezvousName);
                fields.add(factory.newFieldDeclaration(
                        null,
                        new AttributeBuilder(factory)
                            .Private()
                            .toAttributes(),
                        importer.toType(first.getCompiled().getQualifiedName()),
                        rendezvousName,
                        null));
View Full Code Here

Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

                String methodName,
                Type returnType,
                Expression expression) {
            return factory.newMethodDeclaration(
                    null,
                    new AttributeBuilder(factory)
                        .annotation(t(Override.class))
                        .Protected()
                        .toAttributes(),
                    returnType,
                    factory.newSimpleName(methodName),
View Full Code Here

Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

                    .toStatement());
            }

            return factory.newMethodDeclaration(
                    null,
                    new AttributeBuilder(factory)
                        .annotation(t(Override.class))
                        .Public()
                        .toAttributes(),
                    Collections.<TypeParameterDeclaration>emptyList(),
                    t(void.class),
View Full Code Here

Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

                    .assignFrom(Models.toNullLiteral(factory))
                    .toStatement());
            }
            return factory.newMethodDeclaration(
                    null,
                    new AttributeBuilder(factory)
                        .annotation(t(Override.class))
                        .Public()
                        .toAttributes(),
                    Collections.<TypeParameterDeclaration>emptyList(),
                    t(void.class),
View Full Code Here

Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

                        .toExpression(),
                    cases));

            return factory.newMethodDeclaration(
                    null,
                    new AttributeBuilder(factory)
                        .annotation(t(Override.class))
                        .Protected()
                        .toAttributes(),
                    importer.resolve(factory.newParameterizedType(
                            Models.toType(factory, Rendezvous.class),
View Full Code Here

Examples of com.asakusafw.utils.java.model.util.AttributeBuilder

            importer.resolvePackageMember(name);
            return factory.newClassDeclaration(
                    new JavadocBuilder(factory)
                        .text("Mapper for input \"{0}\" in prologue phase.", slot.getName())
                        .toJavadoc(),
                    new AttributeBuilder(factory)
                        .annotation(importer.toType(TraceLocation.class), createTraceLocationElements())
                        .Public()
                        .toAttributes(),
                    name,
                    Collections.<TypeParameterDeclaration>emptyList(),
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.