Tabnine Logo
EJBClientContext.getConfiguredPerMethodInterceptors
Code IndexAdd Tabnine to your IDE (free)

How to use
getConfiguredPerMethodInterceptors
method
in
org.jboss.ejb.client.EJBClientContext

Best Java code snippets using org.jboss.ejb.client.EJBClientContext.getConfiguredPerMethodInterceptors (Showing top 6 results out of 315)

origin: wildfly/wildfly

Builder(final EJBClientContext clientContext) {
  globalInterceptors = Arrays.stream(clientContext.globalInterceptors.getInformation()).collect(Collectors.toCollection(ArrayList::new));
  classInterceptors = new ArrayList<>();
  for (Map.Entry<String, InterceptorList> entry : clientContext.getConfiguredPerClassInterceptors().entrySet()) {
    final String className = entry.getKey();
    for (EJBClientInterceptorInformation information : entry.getValue().getInformation()) {
      classInterceptors.add(new ClassInterceptor(className, information));
    }
  }
  methodInterceptors = new ArrayList<>();
  for (Map.Entry<String, Map<EJBMethodLocator, InterceptorList>> entry : clientContext.getConfiguredPerMethodInterceptors().entrySet()) {
    final String className = entry.getKey();
    for (Map.Entry<EJBMethodLocator, InterceptorList> entry1 : entry.getValue().entrySet()) {
      final EJBMethodLocator methodLocator = entry1.getKey();
      for (EJBClientInterceptorInformation information : entry1.getValue().getInformation()) {
        methodInterceptors.add(new MethodInterceptor(className, methodLocator, information));
      }
    }
  }
  transportProviders = new ArrayList<>();
  Collections.addAll(transportProviders, clientContext.transportProviders);
  clientConnections = new ArrayList<>();
  clientConnections.addAll(clientContext.getConfiguredConnections());
  clientClusters = new ArrayList<>();
  clientClusters.addAll(clientContext.configuredClusters.values());
  clusterNodeSelector = clientContext.clusterNodeSelector;
  deploymentNodeSelector = clientContext.deploymentNodeSelector;
  invocationTimeout = clientContext.invocationTimeout;
}
origin: wildfly/wildfly

static <T> EJBProxyInterceptorInformation<T> construct(Class<T> clazz, EJBClientContext clientContext) {
  final EJBProxyInformation<T> proxyInformation = EJBProxyInformation.forViewType(clazz);
  final Collection<EJBProxyInformation.ProxyMethodInfo> methods = proxyInformation.getMethods();
  final String className = clazz.getName();
  final InterceptorList list0 = EJBClientContext.defaultInterceptors;
  final InterceptorList list1 = clientContext.getGlobalInterceptors();
  final InterceptorList list2 = clientContext.getClassPathInterceptors();
  final InterceptorList list3 = clientContext.getConfiguredPerClassInterceptors().getOrDefault(className, EMPTY);
  final InterceptorList list5 = proxyInformation.getClassInterceptors();
  final IdentityHashMap<Method, InterceptorList> interceptorsByMethod = new IdentityHashMap<>(methods.size());
  final HashMap<InterceptorList, InterceptorList> cache = new HashMap<>();
  cache.computeIfAbsent(list0, Function.identity());
  final InterceptorList tailList = list3.combine(list2).combine(list1).combine(list0);
  cache.computeIfAbsent(tailList, Function.identity());
  for (EJBProxyInformation.ProxyMethodInfo method : methods) {
    // compile interceptor information
    final InterceptorList list4 = clientContext.getConfiguredPerMethodInterceptors().getOrDefault(className, emptyMap()).getOrDefault(method.getMethodLocator(), EMPTY);
    final InterceptorList list6 = method.getInterceptors();
    interceptorsByMethod.put(method.getMethod(), cache.computeIfAbsent(list6.combine(list5).combine(list4).combine(tailList), Function.identity()));
  }
  return new EJBProxyInterceptorInformation<T>(proxyInformation, interceptorsByMethod, cache.computeIfAbsent(list5.combine(tailList), Function.identity()));
}
origin: org.jboss.eap/wildfly-client-all

Builder(final EJBClientContext clientContext) {
  globalInterceptors = Arrays.stream(clientContext.globalInterceptors.getInformation()).collect(Collectors.toCollection(ArrayList::new));
  classInterceptors = new ArrayList<>();
  for (Map.Entry<String, InterceptorList> entry : clientContext.getConfiguredPerClassInterceptors().entrySet()) {
    final String className = entry.getKey();
    for (EJBClientInterceptorInformation information : entry.getValue().getInformation()) {
      classInterceptors.add(new ClassInterceptor(className, information));
    }
  }
  methodInterceptors = new ArrayList<>();
  for (Map.Entry<String, Map<EJBMethodLocator, InterceptorList>> entry : clientContext.getConfiguredPerMethodInterceptors().entrySet()) {
    final String className = entry.getKey();
    for (Map.Entry<EJBMethodLocator, InterceptorList> entry1 : entry.getValue().entrySet()) {
      final EJBMethodLocator methodLocator = entry1.getKey();
      for (EJBClientInterceptorInformation information : entry1.getValue().getInformation()) {
        methodInterceptors.add(new MethodInterceptor(className, methodLocator, information));
      }
    }
  }
  transportProviders = new ArrayList<>();
  Collections.addAll(transportProviders, clientContext.transportProviders);
  clientConnections = new ArrayList<>();
  clientConnections.addAll(clientContext.getConfiguredConnections());
  clientClusters = new ArrayList<>();
  clientClusters.addAll(clientContext.configuredClusters.values());
  clusterNodeSelector = clientContext.clusterNodeSelector;
  deploymentNodeSelector = clientContext.deploymentNodeSelector;
  invocationTimeout = clientContext.invocationTimeout;
}
origin: wildfly/jboss-ejb-client

Builder(final EJBClientContext clientContext) {
  globalInterceptors = Arrays.stream(clientContext.globalInterceptors.getInformation()).collect(Collectors.toCollection(ArrayList::new));
  classInterceptors = new ArrayList<>();
  for (Map.Entry<String, InterceptorList> entry : clientContext.getConfiguredPerClassInterceptors().entrySet()) {
    final String className = entry.getKey();
    for (EJBClientInterceptorInformation information : entry.getValue().getInformation()) {
      classInterceptors.add(new ClassInterceptor(className, information));
    }
  }
  methodInterceptors = new ArrayList<>();
  for (Map.Entry<String, Map<EJBMethodLocator, InterceptorList>> entry : clientContext.getConfiguredPerMethodInterceptors().entrySet()) {
    final String className = entry.getKey();
    for (Map.Entry<EJBMethodLocator, InterceptorList> entry1 : entry.getValue().entrySet()) {
      final EJBMethodLocator methodLocator = entry1.getKey();
      for (EJBClientInterceptorInformation information : entry1.getValue().getInformation()) {
        methodInterceptors.add(new MethodInterceptor(className, methodLocator, information));
      }
    }
  }
  transportProviders = new ArrayList<>();
  Collections.addAll(transportProviders, clientContext.transportProviders);
  clientConnections = new ArrayList<>();
  clientConnections.addAll(clientContext.getConfiguredConnections());
  clientClusters = new ArrayList<>();
  clientClusters.addAll(clientContext.configuredClusters.values());
  clusterNodeSelector = clientContext.clusterNodeSelector;
  deploymentNodeSelector = clientContext.deploymentNodeSelector;
  invocationTimeout = clientContext.invocationTimeout;
}
origin: org.jboss.eap/wildfly-client-all

static <T> EJBProxyInterceptorInformation<T> construct(Class<T> clazz, EJBClientContext clientContext) {
  final EJBProxyInformation<T> proxyInformation = EJBProxyInformation.forViewType(clazz);
  final Collection<EJBProxyInformation.ProxyMethodInfo> methods = proxyInformation.getMethods();
  final String className = clazz.getName();
  final InterceptorList list0 = EJBClientContext.defaultInterceptors;
  final InterceptorList list1 = clientContext.getGlobalInterceptors();
  final InterceptorList list2 = clientContext.getClassPathInterceptors();
  final InterceptorList list3 = clientContext.getConfiguredPerClassInterceptors().getOrDefault(className, EMPTY);
  final InterceptorList list5 = proxyInformation.getClassInterceptors();
  final IdentityHashMap<Method, InterceptorList> interceptorsByMethod = new IdentityHashMap<>(methods.size());
  final HashMap<InterceptorList, InterceptorList> cache = new HashMap<>();
  cache.computeIfAbsent(list0, Function.identity());
  final InterceptorList tailList = list3.combine(list2).combine(list1).combine(list0);
  cache.computeIfAbsent(tailList, Function.identity());
  for (EJBProxyInformation.ProxyMethodInfo method : methods) {
    // compile interceptor information
    final InterceptorList list4 = clientContext.getConfiguredPerMethodInterceptors().getOrDefault(className, emptyMap()).getOrDefault(method.getMethodLocator(), EMPTY);
    final InterceptorList list6 = method.getInterceptors();
    interceptorsByMethod.put(method.getMethod(), cache.computeIfAbsent(list6.combine(list5).combine(list4).combine(tailList), Function.identity()));
  }
  return new EJBProxyInterceptorInformation<T>(proxyInformation, interceptorsByMethod, cache.computeIfAbsent(list5.combine(tailList), Function.identity()));
}
origin: wildfly/jboss-ejb-client

static <T> EJBProxyInterceptorInformation<T> construct(Class<T> clazz, EJBClientContext clientContext) {
  final EJBProxyInformation<T> proxyInformation = EJBProxyInformation.forViewType(clazz);
  final Collection<EJBProxyInformation.ProxyMethodInfo> methods = proxyInformation.getMethods();
  final String className = clazz.getName();
  final InterceptorList list0 = EJBClientContext.defaultInterceptors;
  final InterceptorList list1 = clientContext.getGlobalInterceptors();
  final InterceptorList list2 = clientContext.getClassPathInterceptors();
  final InterceptorList list3 = clientContext.getConfiguredPerClassInterceptors().getOrDefault(className, EMPTY);
  final InterceptorList list5 = proxyInformation.getClassInterceptors();
  final IdentityHashMap<Method, InterceptorList> interceptorsByMethod = new IdentityHashMap<>(methods.size());
  final HashMap<InterceptorList, InterceptorList> cache = new HashMap<>();
  cache.computeIfAbsent(list0, Function.identity());
  final InterceptorList tailList = list3.combine(list2).combine(list1).combine(list0);
  cache.computeIfAbsent(tailList, Function.identity());
  for (EJBProxyInformation.ProxyMethodInfo method : methods) {
    // compile interceptor information
    final InterceptorList list4 = clientContext.getConfiguredPerMethodInterceptors().getOrDefault(className, emptyMap()).getOrDefault(method.getMethodLocator(), EMPTY);
    final InterceptorList list6 = method.getInterceptors();
    interceptorsByMethod.put(method.getMethod(), cache.computeIfAbsent(list6.combine(list5).combine(list4).combine(tailList), Function.identity()));
  }
  return new EJBProxyInterceptorInformation<T>(proxyInformation, interceptorsByMethod, cache.computeIfAbsent(list5.combine(tailList), Function.identity()));
}
org.jboss.ejb.clientEJBClientContextgetConfiguredPerMethodInterceptors

Popular methods of EJBClientContext

  • setSelector
  • getContextManager
    Get the context manager.
  • getAttachment
  • <init>
  • calculateMethodInterceptors
  • create
  • createSession
  • createSessionCreationInvocationContext
  • getClassPathInterceptors
  • getClusterNodeSelector
  • getConfiguredConnections
    Get the pre-configured connections for this context. This information may not be used by some transp
  • getConfiguredPerClassInterceptors
  • getConfiguredConnections,
  • getConfiguredPerClassInterceptors,
  • getCurrent,
  • getDeploymentNodeSelector,
  • getGlobalInterceptors,
  • getInterceptors,
  • getInvocationTimeout,
  • getMaximumConnectedClusterNodes,
  • getTransportProvider

Popular in Java

  • Creating JSON documents from java classes using gson
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • setRequestProperty (URLConnection)
  • requestLocationUpdates (LocationManager)
  • File (java.io)
    An "abstract" representation of a file system entity identified by a pathname. The pathname may be a
  • HttpURLConnection (java.net)
    An URLConnection for HTTP (RFC 2616 [http://tools.ietf.org/html/rfc2616]) used to send and receive d
  • SocketException (java.net)
    This SocketException may be thrown during socket creation or setting options, and is the superclass
  • JarFile (java.util.jar)
    JarFile is used to read jar entries and their associated data from jar files.
  • Manifest (java.util.jar)
    The Manifest class is used to obtain attribute information for a JarFile and its entries.
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • Top plugins for Android Studio
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