Retrieves a queue by its name.

@param queueName name of the queue.
@return the requested queue or <code>null</code> if there is no queue
with the given name.
344633
AsteriskQueueImpl getQueueByName(String queueName)
    {
        refreshQueueIfForced(queueName);

        AsteriskQueueImpl queue = getInternalQueueByName(queueName);
        if (queue == null)
        {
            logger.error("Requested queue '" + queueName + "' not found!");
        }

        return queue;
    }
275225
public ConnectionFactory getConnectionFactory(String queueName)
    {
        // このメソッドを呼び出す前に、
        // this#initContextMap()を利用してcontextMapを初期しておくこと。 
        if (this.contextMap == null)
        {
            return null;
        }

        RabbitmqClusterContext context = this.contextMap.get(queueName);
        if (context == null)
        {
            return null;
        }

        return context.getConnectionFactory();
    }
1329376
public OvhOvhPabxHuntingQueueLiveStatistics billingAccount_ovhPabx_serviceName_hunting_queue_queueId_liveStatistics_GET(String billingAccount, String serviceName, Long queueId) throws IOException {
		String qPath = "/telephony/{billingAccount}/ovhPabx/{serviceName}/hunting/queue/{queueId}/liveStatistics";
		StringBuilder sb = path(qPath, billingAccount, serviceName, queueId);
		String resp = exec(qPath, "GET", sb.toString(), null);
		return convertTo(resp, OvhOvhPabxHuntingQueueLiveStatistics.class);
	}
650982
private String recoverQueue(String queueName, QueueDeclaration queueDeclaration,
    List<Binding> queueBindings) throws Exception {
    String newQueueName = queueName;

    if (config.isQueueRecoveryEnabled()) {
      if (queueDeclaration != null) {
        newQueueName = recoverQueue(queueName, queueDeclaration);

        // Update dependencies for new queue names
        if (!queueName.equals(newQueueName)) {
          connectionHandler.queueDeclarations.remove(queueName);
          connectionHandler.queueDeclarations.put(newQueueName, queueDeclaration);
          connectionHandler.updateQueueBindingReferences(queueName, newQueueName);
        }
      }

      recoverQueueBindings(queueBindings);
    }

    return newQueueName;
  }
74594
def get(self, id_):
        
        if self.api.queue_exists(id_):
            return Queue(self, {"queue": {"name": id_, "id_": id_}}, key="queue")
        raise exc.NotFound("The queue '%s' does not exist." % id_)
73647
@GET
  @Path("{taskName}")
  public Response enqueueTask(@PathParam("taskName") String taskName) {
    checkNotNull(taskName);
    taskQueue.enqueueTask(taskName, requestParamsProvider.get());
    return Response.ok().build();
  }
961170
public function pop($queueName = '')
    {

        if (!isset($this->queues[$queueName])) {
            return null;
        }

        if (!$this->queues[$queueName]) {
            return null;
        }

        return array_pop($this->queues[$queueName]);
    }
186745
public static String getTransferQueue(String name) {
        LOG.debug("对于需要保序的情况，只应该启动单个中转节点，目前启动多个节点原节点会被挤掉线,但是由于重连机制，会轮着挤掉线");
        return IdManager.generateStaticQueueId(buildTransferName(name));
    }
842666
String recoverQueue(String queueName, QueueDeclaration queueDeclaration) throws Exception {
    try {
      String newQueueName =
          ((Queue.DeclareOk) queueDeclaration.invoke(getRecoveryChannel())).getQueue();
      if (queueName.equals(newQueueName))
        log.info("Recovered queue {} via {}", queueName, this);
      else {
        log.info("Recovered queue {} as {} via {}", queueName, newQueueName, this);
        queueDeclaration.name = newQueueName;
      }

      return newQueueName;
    } catch (Exception e) {
      log.error("Failed to recover queue {} via {}", queueName, this, e);
      if (throwOnRecoveryFailure() || Exceptions.isCausedByConnectionClosure(e))
        throw e;
      return queueName;
    }
  }
285620
public BlockingQueue<CollectionDocument> getQueue(String queueName) {
		Preconditions.checkArgument(registry.containsKey(queueName), "Queue %s does not exist", queueName);
		return registry.get(queueName);
	}
962532
def queue_exists(self, name):
        
        try:
            queue = self._manager.head(name)
            return True
        except exc.NotFound:
            return False
506502
private static com.enioka.jqm.api.Queue getQueue(Queue queue)
    {
        com.enioka.jqm.api.Queue q = new com.enioka.jqm.api.Queue();

        q.setDescription(queue.getDescription());
        q.setId(queue.getId());
        q.setName(queue.getName());

        return q;
    }
1298050
@Override
    public Queue createQueue(String queueName) throws JMSRuntimeException {

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(this, tc, "createQueue", new Object[] { queueName });

        Queue queue = null;
        try {
            queue = jmsSession.createQueue(queueName);
        } catch (JMSException jmse) {
            throw (JMSRuntimeException) JmsErrorUtils.getJMS2Exception(jmse, JMSRuntimeException.class);
        } finally {
            if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
                SibTr.exit(this, tc, "createQueue", new Object[] { queue });
        }

        return queue;
    }
578565
@SuppressWarnings("unchecked")
  public <S> S getService(ObjectName name) {
    return (S) servicesByName.get(name);
  }
918982
public boolean isQueue(String queueName) throws Exception {
        Address addr = Address.root().add(SUBSYSTEM, SUBSYSTEM_MESSAGING, HORNETQ_SERVER, "default");
        String haystack = JMS_QUEUE;
        return null != findNodeInList(addr, haystack, queueName);
    }
1342494
@Override
    public JmsQueue createQueue(String name) throws JMSException {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(this, tc, "createQueue", name);
        JmsQueue queue = null;

        // if name string is null, empty or just "queue://", throw exception
        if ((name == null) || ("".equals(name)) || (JmsQueueImpl.QUEUE_PREFIX.equals(name))) {
            throw (InvalidDestinationException) JmsErrorUtils.newThrowable(
                                                                           InvalidDestinationException.class,
                                                                           "INVALID_VALUE_CWSIA0003",
                                                                           new Object[] { "Queue name", name },
                                                                           tc
                            );
        }

        // if name is "topic://" throw exception
        if (name.startsWith(JmsTopicImpl.TOPIC_PREFIX)) {
            throw (InvalidDestinationException) JmsErrorUtils.newThrowable(
                                                                           InvalidDestinationException.class,
                                                                           "MALFORMED_DESCRIPTOR_CWSIA0047",
                                                                           new Object[] { "Queue", name },
                                                                           tc
                            );
        }

        name = name.trim();
        queue = (JmsQueue) destCreator.createDestinationFromString(name, URIDestinationCreator.DestType.QUEUE);

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(this, tc, "createQueue", queue);
        return queue;
    }
912696
public function get($queueName)
    {
        if (!isset($this->queues[$queueName])) {
            throw new \OutOfBoundsException(sprintf('The collection does not contain the queue "%s".', $queueName));
        }

        return $this->queues[$queueName];
    }