Wake up all children consumers
966312
public final void wakeUpConsumers() throws JMSException
    {
        synchronized (consumersMap)
        {
            Iterator<AbstractMessageConsumer> allConsumers = consumersMap.values().iterator();
            while (allConsumers.hasNext())
            {
                AbstractMessageConsumer consumer = allConsumers.next();
                consumer.wakeUp();
            }
        }
    }
1273371
protected void recycleChildren(RecyclerView.Recycler recycler, int startIndex, int endIndex) {
        if (startIndex == endIndex) {
            return;
        }
        if (DEBUG) {
            Log.d(TAG, "Recycling " + Math.abs(startIndex - endIndex) + " items");
        }
        if (endIndex > startIndex) {
            for (int i = endIndex - 1; i >= startIndex; i--) {
                removeAndRecycleViewAt(i, recycler);
            }
        } else {
            for (int i = startIndex; i > endIndex; i--) {
                removeAndRecycleViewAt(i, recycler);
            }
        }
    }
782263
private void notifyConsumer( AbstractMessage message )
    {
    	consumersLock.readLock().lock();
    	try
    	{
    		switch (localConsumers.size())
    		{
    			case 0 : return; // Nobody's listening
    			case 1 : 
    				notifySingleConsumer(localConsumers.get(0),message);
    				break;
    			default : // Multiple consumers
    				notifyNextConsumer(localConsumers,message);
    				break;
    		}
    	}
    	finally
    	{
    		consumersLock.readLock().unlock();
    	}
    }
505329
private HamtPMap<K, V> withChildren(int mask, HamtPMap<K, V>[] children) {
    return mask == this.mask && children == this.children
        ? this
        : new HamtPMap<>(key, hash, value, mask, children);
  }
557107
def set_children(self, value, defined):
        """"""
        self.children = value
        self.children_defined = defined
        return self
585182
public function Children()
    {
        $now = SS_DateTime::now()->Format('Y-m-d');

        return $this->Newsitems()
            ->filter(array('Live' => true))
            ->exclude(array('PublishFrom:GreaterThan' => $now));
    }
469204
protected void invokeConsumer(Consumer<ProgressUpdate> consumer, ProgressUpdate progressUpdate) {
		try {
			consumer.accept(progressUpdate);
		} catch (Throwable t) {
			logger.error("Exception thrown by a Consumer<ProgressUpdate> consumer: " + consumer + "; progressUpdate: " + progressUpdate, t);
		}
	}
424289
function (children) {
        var allChildren = this.get('allChildren');
        if(allChildren) {
          this._setChildren(allChildren.filter(function (child) {
            return children.indexOf(child) !== -1; // true if child is in children
          }));
        }
      }
124650
public void notifyChildren(String eventName, Object eventData, boolean recurse) {
        notifyChildren(this, eventName, eventData, recurse);
    }
720516
public void consumeAsync(List<Purchase> purchases, OnConsumeMultiFinishedListener listener) {
        checkNotDisposed();
        checkSetupDone("consume");
        consumeAsyncInternal(purchases, null, listener);
    }
578988
def set_children(self, child_ids):
        """"""
        if not self._supports_simple_sequencing():
            raise errors.IllegalState()
        self._my_map['childIds'] = [str(i) for i in child_ids]
714011
def consume(self):
        """"""
        head = self.consumers[:-1]
        tail = self.consumers[-1]
        [self._declare_consumer(consumer, nowait=True)
                for consumer in head]
        self._declare_consumer(tail, nowait=False)
290961
@Override
  public void consume(SerializableConsumer<R> consumer) {
    checkNotNull(consumer, "consumer cannot be null");

    ConsumerStreamlet<R> consumerStreamlet = new ConsumerStreamlet<>(this, consumer);
    addChild(consumerStreamlet);
  }
1151265
private void _cleanChildren() {
        //bStatsTreeNeedsUpdate = true;
        if (children != null) {
            Iterator values = children.values().iterator();

            while (values.hasNext()) {
                ModuleItem remMI = (ModuleItem) values.next();
                remMI.getInstance().cleanup();

                //_cleanMBean(remMI);
                remMI._cleanChildren();
                remMI = null;
            }

            children.clear();
        }
    }
686765
def iterchildren(self):
        
        handle = self.handle
        index = 0
        while 1:
            subkey = win32.RegEnumKey(handle, index)
            if subkey is None:
                break
            yield self.child(subkey)
            index += 1
384674
public void notifyStateChangeToUnavailable() {
        final List<ConsumerStateListener> onAvailable = consumerConfig.getOnAvailable();
        if (onAvailable != null) {
            AsyncRuntime.getAsyncThreadPool().execute(new Runnable() {
                @Override
                public void run() {
                    // 状态变化通知监听器
                    for (ConsumerStateListener listener : onAvailable) {
                        try {
                            listener.onUnavailable(consumerConfig.getConsumerBootstrap().getProxyIns());
                        } catch (Exception e) {
                            LOGGER.errorWithApp(consumerConfig.getAppName(),
                                "Failed to notify consumer state listener when state change to unavailable");
                        }
                    }
                }
            });
        }
    }
84290
def mark_as_inactive(self, kid):
        
        k = self.get_key_with_kid(kid)
        k.inactive_since = time.time()