Package com.tinkerpop.frames.structures

Examples of com.tinkerpop.frames.structures.FramedVertexIterable


        }
    }

    public Object processVertex(final Adjacency adjacency, final Method method, final Object[] arguments, final FramedGraph framedGraph, final Vertex vertex) {
        if (ClassUtilities.isGetMethod(method)) {
            final FramedVertexIterable r = new FramedVertexIterable(framedGraph, vertex.getVertices(adjacency.direction(), adjacency.label()),
                    ClassUtilities.getGenericClass(method));
            if (ClassUtilities.returnsIterable(method)) {
                return r;
            } else {
                return r.iterator().hasNext() ? r.iterator().next() : null;
            }
        } else if (ClassUtilities.isAddMethod(method)) {
            Class<?> returnType = method.getReturnType();
            Vertex newVertex;
            Object returnValue = null;
View Full Code Here


                ((Pipe) result).setStarts(new SingleIterator<Element>(vertex));
            }

            if (annotation.frame()) {
                if (result instanceof Iterable) {
                    final FramedVertexIterable r = new FramedVertexIterable(framedGraph, (Iterable) result, ClassUtilities.getGenericClass(method));
                    return (ClassUtilities.returnsIterable(method)) ? r : r.iterator().hasNext() ? r.iterator().next() : null;
                } else if (ClassUtilities.returnsMap(method)) {
                    return new FramedVertexMap(framedGraph, (Map) result, ClassUtilities.getGenericClass(method));
                } else if (result instanceof Vertex) {
                    return framedGraph.frame((Vertex) result, ClassUtilities.getGenericClass(method));
                } else {
View Full Code Here

TOP

Related Classes of com.tinkerpop.frames.structures.FramedVertexIterable

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.