lodsve.amqp.core.QueueBinding Maven / Gradle / Ivy
/*
* Copyright (C) 2018 Sun.Hao
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see .
*/
package lodsve.amqp.core;
import org.springframework.amqp.core.Binding;
import org.springframework.amqp.core.Exchange;
import org.springframework.amqp.core.FanoutExchange;
import org.springframework.amqp.core.Queue;
import java.util.Collections;
/**
* .
*
* @author sunhao(sunhao.java @ gmail.com)
* @version 1.0 2017/12/7 11:18
*/
public class QueueBinding extends Binding {
public QueueBinding(FanoutExchange exchange, Queue queue) {
super(queue.getName(), DestinationType.QUEUE, exchange.getName(), null, Collections.emptyMap());
}
public QueueBinding(Exchange exchange, Queue queue, String routingKey) {
super(queue.getName(), DestinationType.QUEUE, exchange.getName(), routingKey, Collections.emptyMap());
}
public QueueBinding(String exchange, String queue, String routingKey) {
super(queue, DestinationType.QUEUE, exchange, routingKey, Collections.emptyMap());
}
}