Tabnine Logo
InvocationChain.getHeadInterceptor
Code IndexAdd Tabnine to your IDE (free)

How to use
getHeadInterceptor
method
in
org.fabric3.spi.container.wire.InvocationChain

Best Java code snippets using org.fabric3.spi.container.wire.InvocationChain.getHeadInterceptor (Showing top 12 results out of 315)

origin: org.fabric3/fabric3-binding-ftp

  private Interceptor getInterceptor() {
    // lazy load the interceptor as it may not have been added when the instance was created in the wire attacher
    if (interceptor == null) {
      interceptor = wire.getInvocationChains().iterator().next().getHeadInterceptor();
    }
    return interceptor;
  }
}
origin: com.carecon.fabric3/fabric3-binding-zeromq

/**
 * Constructor.
 *
 * @param manager         the ZeroMQ Context manager
 * @param address         the address to receive messages on
 * @param chains          the invocation chains for dispatching invocations
 * @param socketType      the socket type as defined by ZeroMQ
 * @param metadata        metadata
 * @param executorService the executor for scheduling work
 * @param monitor         the monitor
 */
public AbstractReceiver(ContextManager manager,
            SocketAddress address,
            List<InvocationChain> chains,
            int socketType,
            ZeroMQMetadata metadata,
            ExecutorService executorService,
            MessagingMonitor monitor) {
  this.manager = manager;
  this.address = address;
  this.executorService = executorService;
  this.interceptors = new Interceptor[chains.size()];
  for (int i = 0, chainsSize = chains.size(); i < chainsSize; i++) {
    InvocationChain chain = chains.get(i);
    interceptors[i] = chain.getHeadInterceptor();
  }
  this.socketType = socketType;
  this.metadata = metadata;
  this.monitor = monitor;
}
origin: org.fabric3/fabric3-binding-ws-metro

public Object invoke(Packet packet, Method method, Object... args) throws InvocationTargetException {
  // the work context is populated by the current tubeline
  WorkContext workContext = (WorkContext) packet.invocationProperties.get(MetroConstants.WORK_CONTEXT);
  if (workContext == null) {
    // programming error
    throw new AssertionError("Work context not set");
  }
  Message input = MessageCache.getAndResetMessage();
  try {
    input.setWorkContext(workContext);
    input.setBody(args);
    Interceptor head = chains.get(method.getName()).getHeadInterceptor();
    Message ret = head.invoke(input);
    if (!ret.isFault()) {
      return ret.getBody();
    } else {
      Throwable th = (Throwable) ret.getBody();
      throw new InvocationTargetException(th);
    }
  } finally {
    input.reset();
  }
}
origin: com.carecon.fabric3/fabric3-binding-ws

public Object invoke(Packet packet, Method method, Object... args) throws InvocationTargetException {
  // the work context is populated by the current tubeline
  WorkContext workContext = (WorkContext) packet.invocationProperties.get(MetroConstants.WORK_CONTEXT);
  if (workContext == null) {
    // programming error
    throw new AssertionError("Work context not set");
  }
  Message input = MessageCache.getAndResetMessage();
  try {
    input.setWorkContext(workContext);
    input.setBody(args);
    Interceptor head = chains.get(method.getName()).getHeadInterceptor();
    Message ret = head.invoke(input);
    if (!ret.isFault()) {
      return ret.getBody();
    } else {
      Throwable th = (Throwable) ret.getBody();
      throw new InvocationTargetException(th);
    }
  } finally {
    input.reset();
  }
}
origin: org.fabric3/fabric3-binding-ws-metro

  throw new AssertionError("No invocation chain found for WSDL operation: " + operationName);
Interceptor head = chains.get(operationName).getHeadInterceptor();
Message ret = head.invoke(input);
origin: com.carecon.fabric3/fabric3-binding-jms

Interceptor interceptor = holder.getChain().getHeadInterceptor();
boolean oneWay = holder.getChain().getPhysicalOperation().isOneWay();
OperationPayloadTypes payloadTypes = holder.getPayloadTypes();
origin: com.carecon.fabric3/fabric3-binding-rs-jersey

public Object invoke(Method method, Object[] args) throws Throwable {
  InvocationChain invocationChain = chains.get(method.getName());
  if (invocationChain == null) {
    throw new ServiceRuntimeException("Unknown resource method: " + method.toString());
  }
  WorkContext context = WorkContextCache.getThreadWorkContext();   // work context set previously in RsContainer
  Message message = MessageCache.getAndResetMessage();
  try {
    message.setWorkContext(context);
    message.setBody(args);
    if (invocationChain != null) {
      Interceptor headInterceptor = invocationChain.getHeadInterceptor();
      Message ret = headInterceptor.invoke(message);
      if (ret.isFault()) {
        return handleFault(ret);
      } else {
        return ret.getBody();
      }
    } else {
      return null;
    }
  } catch (RuntimeException e) {
    throw new InvocationTargetException(e);
  } finally {
    message.reset();
  }
}
origin: org.fabric3/fabric3-binding-rs-jersey

public Object invoke(Method method, Object[] args) throws Throwable {
  InvocationChain invocationChain = chains.get(method.getName());
  if (invocationChain == null) {
    throw new ServiceRuntimeException("Unknown resource method: " + method.toString());
  }
  WorkContext context = WorkContextCache.getThreadWorkContext();   // work context set previously in RsContainer
  Message message = MessageCache.getAndResetMessage();
  try {
    message.setWorkContext(context);
    message.setBody(args);
    if (invocationChain != null) {
      Interceptor headInterceptor = invocationChain.getHeadInterceptor();
      Message ret = headInterceptor.invoke(message);
      if (ret.isFault()) {
        return handleFault(ret);
      } else {
        return ret.getBody();
      }
    } else {
      return null;
    }
  } catch (RuntimeException e) {
    throw new InvocationTargetException(e);
  } finally {
    message.reset();
  }
}
origin: org.fabric3/fabric3-jdk-proxy

Interceptor headInterceptor = chain.getHeadInterceptor();
assert headInterceptor != null;
origin: com.carecon.fabric3/fabric3-jdk-proxy

Interceptor headInterceptor = chain.getHeadInterceptor();
assert headInterceptor != null;
origin: org.fabric3/fabric3-jdk-proxy

Interceptor headInterceptor = chain.getHeadInterceptor();
assert headInterceptor != null;
origin: com.carecon.fabric3/fabric3-jdk-proxy

Interceptor headInterceptor = chain.getHeadInterceptor();
assert headInterceptor != null;
org.fabric3.spi.container.wireInvocationChaingetHeadInterceptor

Javadoc

Returns the first interceptor in the chain.

Popular methods of InvocationChain

  • addInterceptor
    Adds an interceptor to the chain
  • getPhysicalOperation

Popular in Java

  • Parsing JSON documents to java classes using gson
  • setContentView (Activity)
  • onCreateOptionsMenu (Activity)
  • putExtra (Intent)
  • BufferedImage (java.awt.image)
    The BufferedImage subclass describes an java.awt.Image with an accessible buffer of image data. All
  • InetAddress (java.net)
    An Internet Protocol (IP) address. This can be either an IPv4 address or an IPv6 address, and in pra
  • SQLException (java.sql)
    An exception that indicates a failed JDBC operation. It provides the following information about pro
  • Arrays (java.util)
    This class contains various methods for manipulating arrays (such as sorting and searching). This cl
  • Iterator (java.util)
    An iterator over a sequence of objects, such as a collection.If a collection has been changed since
  • Semaphore (java.util.concurrent)
    A counting semaphore. Conceptually, a semaphore maintains a set of permits. Each #acquire blocks if
  • Top 12 Jupyter Notebook extensions
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now