/* (non-Javadoc)
@see com.ibm.ws.sib.processor.runtime.SIMPPubSubOutboundTransmitControllable#getAttatchedRemoteSubscribers
428950
public SIMPIterator getAttatchedRemoteSubscribers()
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.entry(tc, "getAttatchedRemoteSubscribers");

    // TODO : This method needs to throw runtime invalid to admin
    SIMPIterator itr = null;
    try
    {
      ProtocolItemStream protocolItemStream =
        ((ProtocolItemStream)_streamSet.getItemStream());
      DestinationHandler destHandler = protocolItemStream.getDestinationHandler();

      itr =
        new BasicSIMPIterator(destHandler.getAOControlAdapterIterator());
    }
    catch (MessageStoreException e)
    {
      FFDCFilter.processException(
          e,
          "com.ibm.ws.sib.processor.runtime.InternalOutputStreamSetControl.getAttatchedRemoteSubscribers",
          "1:613:1.30",
          this);
      SibTr.exception(tc, e);
    }

    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.exit(tc, "getAttatchedRemoteSubscribers", itr);
    return itr;
  }
209401
public Collection<Subscription> getSubscriptionsByMessageType(Class messageType) {
        Set<Subscription> subscriptions = new TreeSet<Subscription>(Subscription.SubscriptionByPriorityDesc);
        ReadLock readLock = readWriteLock.readLock();
        try {
            readLock.lock();

            Subscription subscription;
            ArrayList<Subscription> subsPerMessage = subscriptionsPerMessage.get(messageType);

            if (subsPerMessage != null) {
                subscriptions.addAll(subsPerMessage);
            }

            Class[] types = ReflectionUtils.getSuperTypes(messageType);
            for (int i=0, n=types.length; i<n; i++) {
                Class eventSuperType = types[i];
                
                ArrayList<Subscription> subs = subscriptionsPerMessage.get(eventSuperType);
                if (subs != null) {
                    for (int j = 0,m=subs.size(); j<m; j++) {
                        subscription = subs.get(j);

                        if (subscription.handlesMessageType(messageType)) {
                            subscriptions.add(subscription);
                        }
                    }
                }
            }
        }finally{
            readLock.unlock();
        }
        return subscriptions;
    }
1123654
public SubscriptionIndex getSubscriptionIndex()
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
        {
            SibTr.entry(tc, "getSubscriptionIndex");
            SibTr.exit(tc, "getSubscriptionIndex", _subscriptionIndex);
        }
        return _subscriptionIndex;
    }
1152728
@Override
    public String getShareDurableSubscriptions() {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(this, tc, "getShareDurableSubscriptions");
        String val = jcaConnectionFactory.getShareDurableSubscriptions();
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(this, tc, "getShareDurableSubscriptions", val);
        return val;
    }
35818
@Override
    public String getRemoteAddr() {
        try {
            collaborator.preInvoke(componentMetaData);
            return request.getRemoteAddr();
        } finally {
            collaborator.postInvoke();
        }
    }
379746
public java.util.Map<String, IdentityNotificationAttributes> getNotificationAttributes() {
        if (notificationAttributes == null) {
            notificationAttributes = new com.amazonaws.internal.SdkInternalMap<String, IdentityNotificationAttributes>();
        }
        return notificationAttributes;
    }
1045401
@Override
    public RemoteConsumerDispatcher getRemoteConsumerDispatcher(SIBUuid8 meId, SIBUuid12 gatheringTargetDestUuid, boolean createAIH)
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(tc, "getRemoteConsumerDispatcher", new Object[] { meId, gatheringTargetDestUuid, Boolean.valueOf(createAIH) });

        RemoteConsumerDispatcher remoteConsumerDispatcher = _targetDestinationHandler.getRemoteConsumerDispatcher(meId, gatheringTargetDestUuid, createAIH);

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(tc, "getRemoteConsumerDispatcher", remoteConsumerDispatcher);

        return remoteConsumerDispatcher;
    }
1192293
public SIMPIterator getPtoPInboundReceiverIterator()
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.entry(tc, "getPtoPInboundReceiverIterator");

    TargetStreamManager tsm = inputHandler.getTargetStreamManager();
    SIMPIterator itr = tsm.getTargetStreamSetControlIterator();
  
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.exit(tc, "getPtoPInboundReceiverIterator", itr);

    return itr;
  }
624293
public SubscriberEndpoint getNewOrExistingSubscriber(String senderPublicId) {
		SubscriberEndpoint subscriberEndpoint = new SubscriberEndpoint(webParticipant, this, senderPublicId,
				this.getPipeline(), this.openviduConfig);

		SubscriberEndpoint existingSendingEndpoint = this.subscribers.putIfAbsent(senderPublicId, subscriberEndpoint);
		if (existingSendingEndpoint != null) {
			subscriberEndpoint = existingSendingEndpoint;
			log.trace("PARTICIPANT {}: Already exists a subscriber endpoint to user {}", this.getParticipantPublicId(),
					senderPublicId);
		} else {
			log.debug("PARTICIPANT {}: New subscriber endpoint to user {}", this.getParticipantPublicId(),
					senderPublicId);
		}

		return subscriberEndpoint;
	}
365960
@Override
	public boolean unsubscribeAllChannels() {
        final Collection<BitfinexStreamSymbol> channels = getSubscribedChannels();
        final int channelsToUnsubscribe = channels.size();

        logger.debug("Calling unsubscribe for {} channels", channelsToUnsubscribe);
		final CountDownLatch countDownLatch = new CountDownLatch(channelsToUnsubscribe);

        try (Closeable c = callbackRegistry.onUnsubscribeChannelEvent(s -> countDownLatch.countDown())) {
            channels.forEach(symbol -> sendCommand(new UnsubscribeChannelCommand(symbol)));

            // Await the unsubscription
            countDownLatch.await(30, TimeUnit.SECONDS);

            return true;
        } catch (final InterruptedException | IOException e) {
            Thread.currentThread().interrupt();
            return false;
        }
	}
731914
public IConceptMap<IConceptSet> getAffectedSubsumptions() {
        int size = 0;
        for (Context ctx : affectedContexts) {
            if (ctx.hasNewSubsumptions()) {
                size++;
            }
        }

        IConceptMap<IConceptSet> res = new DenseConceptMap<IConceptSet>(size);
        // Collect subsumptions from affected contexts
        for (IntIterator it = contextIndex.keyIterator(); it.hasNext();) {
            int key = it.next();
            Context ctx = contextIndex.get(key);
            if (ctx.hasNewSubsumptions()) {
                res.put(key, ctx.getS());
            }
        }
        return res;
    }
869723
@Override
    public ConsumerDispatcher getDurableSubscriptionConsumerDispatcher(ConsumerDispatcherState subState)
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(tc, "getDurableSubscriptionConsumerDispatcher", subState);

        ConsumerDispatcher consumerDispatcher = _pubSubRealization.
                        getDurableSubscriptionConsumerDispatcher(subState);

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(
                       tc,
                       "getDurableSubscriptionConsumerDispatcher",
                       consumerDispatcher);

        return consumerDispatcher;
    }
1016691
public java.util.List<Subscription> getSubscriptions() {
        if (subscriptions == null) {
            subscriptions = new com.amazonaws.internal.SdkInternalList<Subscription>();
        }
        return subscriptions;
    }
1329051
@Override
    public List<DispatchableKey> getConsumerPoints()
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
        {
            SibTr.entry(tc, "getConsumerPoints");
            SibTr.exit(tc, "getConsumerPoints", consumerPoints);
        }
        return (List<DispatchableKey>) consumerPoints.clone();
    }
1189931
public List getSubscriptionList()
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.entry(tc, "getSubscriptionList");

    List list;
    HashMap durableSubs = destinationManager.getDurableSubscriptionsTable();

    synchronized (durableSubs)
    {
      list = new ArrayList(durableSubs.keySet());
    }

    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.exit(tc, "getSubscriptionList", list);

    return list;
  }
1359262
public List<Subscription> getSubscriptions() throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException {
        return getSubscriptions(null, null);
    }
466560
public List<Object> getSubscribers(final Class<?> eventType, final String eventId) {
        final List<Object> eventSubs = new ArrayList<>();

        synchronized (registeredSubMap) {
            for (Map.Entry<Object, List<SubIdentifier>> entry : registeredSubMap.entrySet()) {
                for (SubIdentifier sub : entry.getValue()) {
                    if (sub.isMyEvent(eventType, eventId)) {
                        eventSubs.add(entry.getKey());

                        break;
                    }
                }
            }
        }

        return eventSubs;
    }