organize which methods are related to which parts of the spec, try to figure
out what we're missing
This commit is contained in:
parent
6f05bf5ef9
commit
73a1d1db36
|
|
@ -538,8 +538,9 @@ Exchange *Client::createExchange(const QString &name, int channelNumber)
|
||||||
Exchange *exchange = new Exchange(channelNumber, this);
|
Exchange *exchange = new Exchange(channelNumber, this);
|
||||||
d->methodHandlersByChannel[exchange->channelNumber()].append(exchange->d_func());
|
d->methodHandlersByChannel[exchange->channelNumber()].append(exchange->d_func());
|
||||||
connect(this, SIGNAL(connected()), exchange, SLOT(_q_open()));
|
connect(this, SIGNAL(connected()), exchange, SLOT(_q_open()));
|
||||||
exchange->d_func()->open();
|
|
||||||
connect(this, SIGNAL(disconnected()), exchange, SLOT(_q_disconnected()));
|
connect(this, SIGNAL(disconnected()), exchange, SLOT(_q_disconnected()));
|
||||||
|
exchange->d_func()->open();
|
||||||
|
|
||||||
if (!name.isEmpty())
|
if (!name.isEmpty())
|
||||||
exchange->setName(name);
|
exchange->setName(name);
|
||||||
return exchange;
|
return exchange;
|
||||||
|
|
@ -558,8 +559,8 @@ Queue *Client::createQueue(const QString &name, int channelNumber)
|
||||||
d->contentHandlerByChannel[queue->channelNumber()].append(queue->d_func());
|
d->contentHandlerByChannel[queue->channelNumber()].append(queue->d_func());
|
||||||
d->bodyHandlersByChannel[queue->channelNumber()].append(queue->d_func());
|
d->bodyHandlersByChannel[queue->channelNumber()].append(queue->d_func());
|
||||||
connect(this, SIGNAL(connected()), queue, SLOT(_q_open()));
|
connect(this, SIGNAL(connected()), queue, SLOT(_q_open()));
|
||||||
queue->d_func()->open();
|
|
||||||
connect(this, SIGNAL(disconnected()), queue, SLOT(_q_disconnected()));
|
connect(this, SIGNAL(disconnected()), queue, SLOT(_q_disconnected()));
|
||||||
|
queue->d_func()->open();
|
||||||
|
|
||||||
if (!name.isEmpty())
|
if (!name.isEmpty())
|
||||||
queue->setName(name);
|
queue->setName(name);
|
||||||
|
|
|
||||||
|
|
@ -42,29 +42,30 @@ public:
|
||||||
~Queue();
|
~Queue();
|
||||||
QueueOptions option() const;
|
QueueOptions option() const;
|
||||||
|
|
||||||
void declare(const QString &name = QString(),
|
bool hasMessage() const;
|
||||||
QueueOptions options = QueueOptions(Durable | AutoDelete));
|
|
||||||
void remove(bool ifUnused = true, bool ifEmpty = true, bool noWait = true);
|
|
||||||
void purge();
|
|
||||||
|
|
||||||
void bind(const QString &exchangeName, const QString &key);
|
|
||||||
void bind(Exchange *exchange, const QString &key);
|
|
||||||
|
|
||||||
void unbind(const QString &exchangeName, const QString &key);
|
|
||||||
void unbind(Exchange *exchange, const QString &key);
|
|
||||||
|
|
||||||
MessagePtr getMessage();
|
MessagePtr getMessage();
|
||||||
|
|
||||||
void get();
|
|
||||||
void ack(const MessagePtr &message);
|
|
||||||
bool hasMessage() const;
|
|
||||||
void consume(ConsumeOptions options = ConsumeOptions(NoOptions));
|
|
||||||
void setConsumerTag(const QString &consumerTag);
|
void setConsumerTag(const QString &consumerTag);
|
||||||
QString consumerTag() const;
|
QString consumerTag() const;
|
||||||
|
|
||||||
void setNoAck(bool noAck);
|
void setNoAck(bool noAck);
|
||||||
bool noAck() const;
|
bool noAck() const;
|
||||||
|
|
||||||
|
// AMQP Queue
|
||||||
|
void declare(const QString &name = QString(),
|
||||||
|
QueueOptions options = QueueOptions(Durable | AutoDelete));
|
||||||
|
void bind(const QString &exchangeName, const QString &key);
|
||||||
|
void bind(Exchange *exchange, const QString &key);
|
||||||
|
void unbind(const QString &exchangeName, const QString &key);
|
||||||
|
void unbind(Exchange *exchange, const QString &key);
|
||||||
|
void purge();
|
||||||
|
void remove(bool ifUnused = true, bool ifEmpty = true, bool noWait = true);
|
||||||
|
|
||||||
|
// AMQP Basic
|
||||||
|
void consume(ConsumeOptions options = ConsumeOptions(NoOptions));
|
||||||
|
void get();
|
||||||
|
void ack(const MessagePtr &message);
|
||||||
|
|
||||||
Q_SIGNALS:
|
Q_SIGNALS:
|
||||||
void declared();
|
void declared();
|
||||||
void bound();
|
void bound();
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue