from interface SetListener
508656
public void entryRemoved (EntryRemovedEvent<T> event)
    {
        dispatchMethod(event.getName() + "Removed",
            new Object[] { event.getKey() });
    }
809662
public synchronized void addStateListener(@Nonnull EndpointStateListener<VALUE_TYPE, ARG_TYPE> listener) throws IllegalArgumentException {
        checkListenerNonNull(listener);
        fieldStateListeners.add(listener);
        if (informStateListenerOnAdd) {
            informStateListener(getStateAndValue(), listener);
        }
    }
293689
public void set(final T value) {
		if (this.value.compareAndSet(null, value)) {
			this.listeners.clear();
			this.cdl.countDown();
		}
	}
1176715
@Override
    public void setReactionSet(IReactionSet sor) {
        if (this.setOfReactions != null) this.setOfReactions.removeListener(this);
        this.setOfReactions = sor;
        if (this.setOfReactions != null) this.setOfReactions.addListener(this);
        notifyChanged();
    }
814548
@Override
    public void in() throws Exception {
        if (data == null) {
            throw new ComponentException("Not connected: " + toString());
        }
        Object val = data.getFieldValue();
        // fire only if there is a listener
        if (ens.shouldFire()) {
            DataflowEvent e = new DataflowEvent(ens.getController(), this, val);
////            DataflowEvent e = new DataflowEvent(ens.getController(), this, access.toObject());
            ens.fireIn(e);
//            // the value might be altered
            val = e.getValue();
        }

//        access.pass((Access) val);
        fa.setFieldValue(val);
    }
1322123
public final void setListener( @Nullable final WebSocketListener listener )
  {
    _listener = null == listener ? NullWebSocketListener.LISTENER : listener;
  }
38277
@Override
    public Layer setListening(final boolean listening)
    {
        super.setListening(listening);

        if (listening)
        {
            if (isShowSelectionLayer())
            {
                if (null != getSelectionLayer())
                {
                    doShowSelectionLayer(true);
                }
            }
        }
        else
        {
            if (isShowSelectionLayer())
            {
                doShowSelectionLayer(false);
            }
            m_select = null;
        }
        return this;
    }
438903
def interface(self, context):
        """"""
        self.context = context
        self.callback = self.context.get("callback")
1326377
private <T extends Rdp4jListener> void notifyListeners(Class<T> listenerType, Notifier<T> notifier)
            throws InterruptedException {
        for (Rdp4jListener listener : listeners) {
            if (isInstanceOf(listener, listenerType)) {
                /*
                 * This cast is correct, since we check if listener
                 * is instance of listenerType.
                 */
                @SuppressWarnings("unchecked")
                T listener2 = (T) listener;
                try {
                    notifier.notify(listener2);
                } catch (InterruptedException e) {
                    throw e;
                } catch (Throwable e) {
                    logErrorMessage(e);
                }
            }
        }
    }
869459
def set_listener(self, name, listener):
        
        with self.__listeners_change_condition:
            self.listeners[name] = listener
130724
public void doAddListener(BaseListener listener)
    {
        if (m_nextListener != null)
            m_nextListener.doAddListener(listener);
        else
            m_nextListener = listener;
    }
303482
public void setListeners(java.util.Collection<Listener> listeners) {
        if (listeners == null) {
            this.listeners = null;
            return;
        }

        this.listeners = new com.amazonaws.internal.SdkInternalList<Listener>(listeners);
    }
317016
@SuppressWarnings("unchecked")
    private void prepareListeners() {
        if (preparedListeners != null && preparedUnspecifiedListeners != null) {
            // Already created, skip
            return;
        }
        preparedListeners = new ConcurrentHashMap<>();
        Stream<Class<? extends GloballyAttachableListener>> eventTypes = Stream.concat(
                listeners.keySet().stream(),
                Stream.concat(listenerSuppliers.keySet().stream(),
                        listenerFunctions.keySet().stream())
        ).distinct();
        eventTypes.forEach(type -> {
            ArrayList<Function<DiscordApi, GloballyAttachableListener>> typeListenerFunctions = new ArrayList<>();
            listeners.getOrDefault(type, Collections.emptyList()).forEach(
                    listener -> typeListenerFunctions.add(api -> listener)
            );
            listenerSuppliers.getOrDefault(type, Collections.emptyList()).forEach(
                    supplier -> typeListenerFunctions.add(api -> supplier.get())
            );
            listenerFunctions.getOrDefault(type, Collections.emptyList()).forEach(
                    function -> typeListenerFunctions.add((Function<DiscordApi, GloballyAttachableListener>) function)
            );
            preparedListeners.put(type, typeListenerFunctions);
        });
        // Unspecified Listeners
        preparedUnspecifiedListeners = new CopyOnWriteArrayList<>(unspecifiedListenerFunctions);
        unspecifiedListenerSuppliers.forEach(supplier -> preparedUnspecifiedListeners.add((api) -> supplier.get()));
        unspecifiedListeners.forEach(listener -> preparedUnspecifiedListeners.add((api) -> listener));
    }
710501
@Override
    public void onSetListeners() {
        imageViewPerson.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View v) {
                PersonHolderListener listener = getListener(PersonHolderListener.class);
                if (listener != null) {
                    listener.onPersonImageClicked(getItem());
                }
            }
        });
    }
1060594
@Override
	public boolean loadListeners(String[] listeners, ClassLoader classLoader) {
		// Instantiate all the listeners
		for (String className : listeners) {			
			try {
				Class listenerClass = Class.forName(className, false, classLoader);
				EventListener listener = (EventListener) listenerClass.newInstance();
				
				// FIXME !!! SipInstanceManager sipInstanceManager = ((CatalinaSipContext)sipContext).getSipInstanceManager();
				// FIXME !! sipInstanceManager.processAnnotations(listener, sipInstanceManager.getInjectionMap(listenerClass.getName()));
				
				MobicentsSipServlet sipServletImpl = (MobicentsSipServlet)sipContext.findSipServletByClassName(className);
				if(sipServletImpl != null) {
					listener = (EventListener) sipServletImpl.allocate();
					listenerServlets.put(listener, sipServletImpl);
				} else {
					SipServlet servlet = (SipServlet) listenerClass.getAnnotation(SipServlet.class);
					if (servlet != null) {						
						sipServletImpl = (MobicentsSipServlet)sipContext.findSipServletByName(servlet.name());
						if(sipServletImpl != null) {
							listener = (EventListener) sipServletImpl.allocate();
							listenerServlets.put(listener, sipServletImpl);
						}
					}					
				}				             
				addListenerToBunch(listener);				
			} catch (Exception e) {
				logger.fatal("Cannot instantiate listener class " + className,
						e);
				return false;
			}
		}
		return true;
	}
639590
public void addListener(final WebAppListener listener) {
		NullArgumentException.validateNotNull(listener, "Listener");
		NullArgumentException.validateNotNull(listener.getListenerClass(),
				"Listener class");
		if (!listeners.contains(listener)) {
			listeners.add(listener);
		}
	}
1196592
public void setRuntimeEventListener(RuntimeEventListener listener) {
        if (TraceComponent.isAnyTracingEnabled()
            && tc.isEntryEnabled())
            SibTr.entry(tc, "setRuntimeEventListener", listener);
        _runtimeEventListener = listener;
        if (TraceComponent.isAnyTracingEnabled()
            && tc.isEntryEnabled())
            SibTr.exit(tc, "setRuntimeEventListener");
    }