Package com.facebook.swift.generator.template

Examples of com.facebook.swift.generator.template.StructContext


    @Override
    public void visit(final Visitable visitable) throws IOException
    {
        final ThriftException exception = ThriftException.class.cast(visitable);
        final StructContext exceptionContext = contextGenerator.structFromThrift(exception);

        for (final ThriftField field : exception.getFields()) {
            exceptionContext.addField(contextGenerator.fieldFromThrift(field));
        }

        render(exceptionContext, "exception");
    }
View Full Code Here


    @Override
    public void visit(final Visitable visitable) throws IOException
    {
        final Struct struct = Struct.class.cast(visitable);
        final StructContext structContext = contextGenerator.structFromThrift(struct);

        for (final ThriftField field : struct.getFields()) {
            structContext.addField(contextGenerator.fieldFromThrift(field));
        }

        render(structContext, "struct");
    }
View Full Code Here

    @Override
    public void visit(final Visitable visitable) throws IOException
    {
        final Union union = Union.class.cast(visitable);
        final StructContext unionContext = contextGenerator.structFromThrift(union);

        for (final ThriftField field : union.getFields()) {
            unionContext.addField(contextGenerator.fieldFromThrift(field));
        }

        render(unionContext, "union");
    }
View Full Code Here

TOP

Related Classes of com.facebook.swift.generator.template.StructContext

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.