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

com.tinkerpop.frames.modules.MethodHandler 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.modules;

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

import com.tinkerpop.blueprints.Element;
import com.tinkerpop.frames.FramedGraph;

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

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




© 2015 - 2025 Weber Informatics LLC | Privacy Policy