Codota Logo
Destination.addRemoveListener
Code IndexAdd Codota to your IDE (free)

How to use
addRemoveListener
method
in
org.granite.config.flex.Destination

Best Java code snippets using org.granite.config.flex.Destination.addRemoveListener (Showing top 2 results out of 315)

  • Common ways to obtain Destination
private void myMethod () {
Destination d =
  • Codota IconService service;String id;service.findDestinationById(id)
  • Smart code suggestions by Codota
}
origin: org.graniteds/granite-server

@Override
public ServiceInvoker<?> getServiceInstance(RemotingMessage request) throws ServiceException {
  String messageType = request.getClass().getName();
  String destinationId = request.getDestination();
  GraniteContext context = GraniteContext.getCurrentInstance();
  Destination destination = ((ServicesConfig)context.getServicesConfig()).findDestinationById(messageType, destinationId);
  if (destination == null)
    throw new ServiceException("No matching destination: " + destinationId);
  destination.addRemoveListener(this);
  Map<String, Object> cache = getCache(destination);
  
  String key = SimpleServiceInvoker.class.getName() + '.' + destination.getId();
  if (invalidKeys.contains(key)) {
    cache.remove(key);
    invalidKeys.remove(key);
  }
  
  SimpleServiceInvoker service = (SimpleServiceInvoker)cache.get(key);
  if (service == null) {
    service = new SimpleServiceInvoker(destination, this);
    cache.put(key, service);
  }
  return service;
}
 
origin: org.graniteds/granite-client

@Override
public ServiceInvoker<?> getServiceInstance(RemotingMessage request) throws ServiceException {
  String messageType = request.getClass().getName();
  String destinationId = request.getDestination();
  GraniteContext context = GraniteContext.getCurrentInstance();
  Destination destination = context.getServicesConfig().findDestinationById(messageType, destinationId);
  if (destination == null)
    throw new ServiceException("No matching destination: " + destinationId);
  destination.addRemoveListener(this);
  Map<String, Object> cache = getCache(destination);
  
  String key = SimpleServiceInvoker.class.getName() + '.' + destination.getId();
  if (invalidKeys.contains(key)) {
    cache.remove(key);
    invalidKeys.remove(key);
  }
  
  SimpleServiceInvoker service = (SimpleServiceInvoker)cache.get(key);
  if (service == null) {
    service = new SimpleServiceInvoker(destination, this);
    cache.put(key, service);
  }
  return service;
}
 
org.granite.config.flexDestinationaddRemoveListener

Popular methods of Destination

  • getProperties
  • getId
  • getScannedClass
  • <init>
  • forElement
  • getSecurizer
  • remove
  • getAdapter
  • getRoles
  • isSecured
  • setSecurizer
  • setSecurizer

Popular in Java

  • Updating database using SQL prepared statement
  • putExtra (Intent)
  • setContentView (Activity)
  • onRequestPermissionsResult (Fragment)
  • System (java.lang)
    Provides access to system-related information and resources including standard input and output. Ena
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate(i
  • Comparator (java.util)
    A Comparator is used to compare two objects to determine their ordering with respect to each other.
  • TreeSet (java.util)
    A NavigableSet implementation based on a TreeMap. The elements are ordered using their Comparable, o
  • Annotation (javassist.bytecode.annotation)
    The annotation structure.An instance of this class is returned bygetAnnotations() in AnnotationsAttr
  • Options (org.apache.commons.cli)
    Main entry-point into the library. Options represents a collection of Option objects, which describ
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now