All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.tinkerpop.frames.annotations.AnnotationHandler Maven / Gradle / Ivy

Go to download

Windup Frames is an extension of the upstream Frames project, with tools to ease debugging and integration within windup.

There is a newer version: 4.0.1.Final
Show newest version
package com.tinkerpop.frames.annotations;

import com.tinkerpop.blueprints.Direction;
import com.tinkerpop.blueprints.Element;
import com.tinkerpop.frames.FramedGraph;
import com.tinkerpop.frames.modules.MethodHandler;

import java.lang.annotation.Annotation;
import java.lang.reflect.Method;

/**
 * Allows handling of method on frames. Only the first annotation handler found is called.
 * Instances of this class should be threadsafe.
 * 
 * @param  The type of annotation handled.
 * @deprecated Use {@link MethodHandler} instead
 */
public interface AnnotationHandler {
    /**
     * @return The annotation type that this handler responds to. 
     */
    public Class getAnnotationType();

    /**
     * @param annotation The annotation
     * @param method The method being called on the frame.
     * @param arguments The arguments to the method.
     * @param framedGraph The graph being called. 
     * @param element The underlying element.
     * @param direction The direction of the edge.
     * @return A return value for the method.
     */
    public Object processElement(final T annotation, final Method method, final Object[] arguments, final FramedGraph framedGraph, final Element element, final Direction direction);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy