diff options
author | Robert Godfrey <rgodfrey@apache.org> | 2014-09-28 16:46:34 +0000 |
---|---|---|
committer | Robert Godfrey <rgodfrey@apache.org> | 2014-09-28 16:46:34 +0000 |
commit | 17ff2442352bac23f3776b3a8a6e4e419833e787 (patch) | |
tree | b188a173a65e24e6302dbe12656c174cc2f4590d | |
parent | 9eeb3ec4303c7527e9a9c815278606236e7d701d (diff) | |
download | qpid-python-17ff2442352bac23f3776b3a8a6e4e419833e787.tar.gz |
Remove redundant interfaces
git-svn-id: https://svn.apache.org/repos/asf/qpid/branches/QPID-6125-ProtocolRefactoring@1628082 13f79535-47bb-0310-9956-ffa450edef68
114 files changed, 5773 insertions, 7631 deletions
diff --git a/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/AMQProtocolEngine.java b/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/AMQProtocolEngine.java index 1a746447b0..765e7d6ad7 100644 --- a/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/AMQProtocolEngine.java +++ b/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/AMQProtocolEngine.java @@ -1524,7 +1524,7 @@ public class AMQProtocolEngine implements ServerProtocolEngine, AMQProtocolSessi methodRegistry.createChannelCloseBody( cause.getCode(), AMQShortString.validValueOf(message), - 0,0); + 0, 0); writeFrame(responseBody.generateFrame(channelId)); } diff --git a/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/handler/ConnectionSecureOkMethodHandler.java b/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/handler/ConnectionSecureOkMethodHandler.java index 7a0c0945e1..001719759a 100644 --- a/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/handler/ConnectionSecureOkMethodHandler.java +++ b/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/handler/ConnectionSecureOkMethodHandler.java @@ -114,7 +114,8 @@ public class ConnectionSecureOkMethodHandler implements StateAwareMethodListener case CONTINUE: connection.changeState(AMQState.CONNECTION_NOT_AUTH); - ConnectionSecureBody secureBody = methodRegistry.createConnectionSecureBody(authResult.getChallenge()); + ConnectionSecureBody + secureBody = methodRegistry.createConnectionSecureBody(authResult.getChallenge()); connection.writeFrame(secureBody.generateFrame(0)); } } diff --git a/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/handler/ConnectionStartOkMethodHandler.java b/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/handler/ConnectionStartOkMethodHandler.java index 311b596979..328c03bf74 100644 --- a/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/handler/ConnectionStartOkMethodHandler.java +++ b/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/handler/ConnectionStartOkMethodHandler.java @@ -120,15 +120,17 @@ public class ConnectionStartOkMethodHandler implements StateAwareMethodListener< frameMax = Integer.MAX_VALUE; } - ConnectionTuneBody tuneBody = methodRegistry.createConnectionTuneBody(broker.getConnection_sessionCountLimit(), - frameMax, - broker.getConnection_heartBeatDelay()); + ConnectionTuneBody + tuneBody = methodRegistry.createConnectionTuneBody(broker.getConnection_sessionCountLimit(), + frameMax, + broker.getConnection_heartBeatDelay()); connection.writeFrame(tuneBody.generateFrame(0)); break; case CONTINUE: connection.changeState(AMQState.CONNECTION_NOT_AUTH); - ConnectionSecureBody secureBody = methodRegistry.createConnectionSecureBody(authResult.getChallenge()); + ConnectionSecureBody + secureBody = methodRegistry.createConnectionSecureBody(authResult.getChallenge()); connection.writeFrame(secureBody.generateFrame(0)); } } diff --git a/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/output/ProtocolOutputConverterImpl.java b/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/output/ProtocolOutputConverterImpl.java index 46a575e934..5de9c928e1 100644 --- a/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/output/ProtocolOutputConverterImpl.java +++ b/java/broker-plugins/amqp-0-8-protocol/src/main/java/org/apache/qpid/server/protocol/v0_8/output/ProtocolOutputConverterImpl.java @@ -383,10 +383,10 @@ class ProtocolOutputConverterImpl implements ProtocolOutputConverter BasicGetOkBody getOkBody = _methodRegistry.createBasicGetOkBody(deliveryTag, - isRedelivered, - exchangeName, - routingKey, - queueSize); + isRedelivered, + exchangeName, + routingKey, + queueSize); return getOkBody; } @@ -408,9 +408,9 @@ class ProtocolOutputConverterImpl implements ProtocolOutputConverter BasicReturnBody basicReturnBody = _methodRegistry.createBasicReturnBody(replyCode, - replyText, - messagePublishInfo.getExchange(), - messagePublishInfo.getRoutingKey()); + replyText, + messagePublishInfo.getExchange(), + messagePublishInfo.getRoutingKey()); return basicReturnBody; diff --git a/java/client/src/test/java/org/apache/qpid/client/AMQSession_0_8Test.java b/java/client/src/test/java/org/apache/qpid/client/AMQSession_0_8Test.java index 63d3fe57b0..2a8ab22b81 100644 --- a/java/client/src/test/java/org/apache/qpid/client/AMQSession_0_8Test.java +++ b/java/client/src/test/java/org/apache/qpid/client/AMQSession_0_8Test.java @@ -23,7 +23,7 @@ package org.apache.qpid.client; import org.apache.qpid.AMQException; import org.apache.qpid.client.transport.TestNetworkConnection; import org.apache.qpid.framing.AMQShortString; -import org.apache.qpid.framing.QueueDeclareOkBodyImpl; +import org.apache.qpid.framing.QueueDeclareOkBody; import org.apache.qpid.test.utils.QpidTestCase; import org.apache.qpid.transport.network.NetworkConnection; import org.apache.qpid.url.AMQBindingURL; @@ -50,7 +50,7 @@ public class AMQSession_0_8Test extends QpidTestCase { try { - _connection.getProtocolHandler().methodBodyReceived(1, new QueueDeclareOkBodyImpl(testQueueName, 0, 0)); + _connection.getProtocolHandler().methodBodyReceived(1, new QueueDeclareOkBody(testQueueName, 0, 0)); } catch (AMQException e) { diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicAckBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicAckBody.java index 41c4af5ff0..b04379b0cd 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicAckBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicAckBody.java @@ -22,17 +22,106 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicAckBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicAckBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicAckBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 80; + + // Fields declared in specification + private final long _deliveryTag; // [deliveryTag] + private final byte _bitfield0; // [multiple] + + // Constructor + public BasicAckBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _deliveryTag = readLong( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public BasicAckBody( + long deliveryTag, + boolean multiple + ) + { + _deliveryTag = deliveryTag; + byte bitfield0 = (byte)0; + if( multiple ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final long getDeliveryTag() + { + return _deliveryTag; + } + public final boolean getMultiple() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 9; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeLong( buffer, _deliveryTag ); + writeBitfield( buffer, _bitfield0 ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicAck(this, channelId); + } - public long getDeliveryTag(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicAckBodyImpl: "); + buf.append( "deliveryTag=" ); + buf.append( getDeliveryTag() ); + buf.append( ", " ); + buf.append( "multiple=" ); + buf.append( getMultiple() ); + buf.append("]"); + return buf.toString(); + } - public boolean getMultiple(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicAckBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicAckBodyImpl.java deleted file mode 100644 index 617feabfb1..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicAckBodyImpl.java +++ /dev/null @@ -1,127 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicAckBodyImpl extends AMQMethodBodyImpl implements BasicAckBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicAckBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 80; - - // Fields declared in specification - private final long _deliveryTag; // [deliveryTag] - private final byte _bitfield0; // [multiple] - - // Constructor - public BasicAckBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _deliveryTag = readLong( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public BasicAckBodyImpl( - long deliveryTag, - boolean multiple - ) - { - _deliveryTag = deliveryTag; - byte bitfield0 = (byte)0; - if( multiple ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final long getDeliveryTag() - { - return _deliveryTag; - } - public final boolean getMultiple() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 9; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeLong( buffer, _deliveryTag ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicAck(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicAckBodyImpl: "); - buf.append( "deliveryTag=" ); - buf.append( getDeliveryTag() ); - buf.append( ", " ); - buf.append( "multiple=" ); - buf.append( getMultiple() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicCancelBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicCancelBody.java index 853b1583b9..d52e5f5ac8 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicCancelBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicCancelBody.java @@ -22,17 +22,107 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicCancelBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicCancelBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicCancelBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 30; + + // Fields declared in specification + private final AMQShortString _consumerTag; // [consumerTag] + private final byte _bitfield0; // [nowait] + + // Constructor + public BasicCancelBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _consumerTag = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public BasicCancelBody( + AMQShortString consumerTag, + boolean nowait + ) + { + _consumerTag = consumerTag; + byte bitfield0 = (byte)0; + if( nowait ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getConsumerTag() + { + return _consumerTag; + } + public final boolean getNowait() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 1; + size += getSizeOf( _consumerTag ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _consumerTag ); + writeBitfield( buffer, _bitfield0 ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicCancel(this, channelId); + } - public AMQShortString getConsumerTag(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicCancelBodyImpl: "); + buf.append( "consumerTag=" ); + buf.append( getConsumerTag() ); + buf.append( ", " ); + buf.append( "nowait=" ); + buf.append( getNowait() ); + buf.append("]"); + return buf.toString(); + } - public boolean getNowait(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicCancelBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicCancelBodyImpl.java deleted file mode 100644 index fdfb981b86..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicCancelBodyImpl.java +++ /dev/null @@ -1,128 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicCancelBodyImpl extends AMQMethodBodyImpl implements BasicCancelBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicCancelBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 30; - - // Fields declared in specification - private final AMQShortString _consumerTag; // [consumerTag] - private final byte _bitfield0; // [nowait] - - // Constructor - public BasicCancelBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _consumerTag = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public BasicCancelBodyImpl( - AMQShortString consumerTag, - boolean nowait - ) - { - _consumerTag = consumerTag; - byte bitfield0 = (byte)0; - if( nowait ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getConsumerTag() - { - return _consumerTag; - } - public final boolean getNowait() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 1; - size += getSizeOf( _consumerTag ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _consumerTag ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicCancel(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicCancelBodyImpl: "); - buf.append( "consumerTag=" ); - buf.append( getConsumerTag() ); - buf.append( ", " ); - buf.append( "nowait=" ); - buf.append( getNowait() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicCancelOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicCancelOkBody.java index 623e89275a..ea087ac025 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicCancelOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicCancelOkBody.java @@ -22,15 +22,90 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicCancelOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicCancelOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicCancelOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 31; + + // Fields declared in specification + private final AMQShortString _consumerTag; // [consumerTag] + + // Constructor + public BasicCancelOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _consumerTag = readAMQShortString( buffer ); + } + + public BasicCancelOkBody( + AMQShortString consumerTag + ) + { + _consumerTag = consumerTag; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getConsumerTag() + { + return _consumerTag; + } + + protected int getBodySize() + { + int size = 0; + size += getSizeOf( _consumerTag ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _consumerTag ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicCancelOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicCancelOkBodyImpl: "); + buf.append( "consumerTag=" ); + buf.append( getConsumerTag() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getConsumerTag(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicCancelOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicCancelOkBodyImpl.java deleted file mode 100644 index c1232b9047..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicCancelOkBodyImpl.java +++ /dev/null @@ -1,111 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicCancelOkBodyImpl extends AMQMethodBodyImpl implements BasicCancelOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicCancelOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 31; - - // Fields declared in specification - private final AMQShortString _consumerTag; // [consumerTag] - - // Constructor - public BasicCancelOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _consumerTag = readAMQShortString( buffer ); - } - - public BasicCancelOkBodyImpl( - AMQShortString consumerTag - ) - { - _consumerTag = consumerTag; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getConsumerTag() - { - return _consumerTag; - } - - protected int getBodySize() - { - int size = 0; - size += getSizeOf( _consumerTag ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _consumerTag ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicCancelOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicCancelOkBodyImpl: "); - buf.append( "consumerTag=" ); - buf.append( getConsumerTag() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeBody.java index d263899082..c198d3938b 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeBody.java @@ -22,29 +22,185 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicConsumeBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicConsumeBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicConsumeBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 20; + + // Fields declared in specification + private final int _ticket; // [ticket] + private final AMQShortString _queue; // [queue] + private final AMQShortString _consumerTag; // [consumerTag] + private final byte _bitfield0; // [noLocal, noAck, exclusive, nowait] + private final FieldTable _arguments; // [arguments] + + // Constructor + public BasicConsumeBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _ticket = readUnsignedShort( buffer ); + _queue = readAMQShortString( buffer ); + _consumerTag = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + _arguments = readFieldTable( buffer ); + } + + public BasicConsumeBody( + int ticket, + AMQShortString queue, + AMQShortString consumerTag, + boolean noLocal, + boolean noAck, + boolean exclusive, + boolean nowait, + FieldTable arguments + ) + { + _ticket = ticket; + _queue = queue; + _consumerTag = consumerTag; + byte bitfield0 = (byte)0; + if( noLocal ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + + if( noAck ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); + } + + if( exclusive ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 2)); + } + + if( nowait ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 3)); + } + + _bitfield0 = bitfield0; + _arguments = arguments; + } - public FieldTable getArguments(); + public int getClazz() + { + return CLASS_ID; + } - public AMQShortString getConsumerTag(); + public int getMethod() + { + return METHOD_ID; + } - public boolean getExclusive(); + public final int getTicket() + { + return _ticket; + } + public final AMQShortString getQueue() + { + return _queue; + } + public final AMQShortString getConsumerTag() + { + return _consumerTag; + } + public final boolean getNoLocal() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + public final boolean getNoAck() + { + return (((int)(_bitfield0)) & ( 1 << 1)) != 0; + } + public final boolean getExclusive() + { + return (((int)(_bitfield0)) & ( 1 << 2)) != 0; + } + public final boolean getNowait() + { + return (((int)(_bitfield0)) & ( 1 << 3)) != 0; + } + public final FieldTable getArguments() + { + return _arguments; + } - public boolean getNoAck(); + protected int getBodySize() + { + int size = 3; + size += getSizeOf( _queue ); + size += getSizeOf( _consumerTag ); + size += getSizeOf( _arguments ); + return size; + } - public boolean getNoLocal(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _ticket ); + writeAMQShortString( buffer, _queue ); + writeAMQShortString( buffer, _consumerTag ); + writeBitfield( buffer, _bitfield0 ); + writeFieldTable( buffer, _arguments ); + } - public boolean getNowait(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicConsume(this, channelId); + } - public AMQShortString getQueue(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicConsumeBodyImpl: "); + buf.append( "ticket=" ); + buf.append( getTicket() ); + buf.append( ", " ); + buf.append( "queue=" ); + buf.append( getQueue() ); + buf.append( ", " ); + buf.append( "consumerTag=" ); + buf.append( getConsumerTag() ); + buf.append( ", " ); + buf.append( "noLocal=" ); + buf.append( getNoLocal() ); + buf.append( ", " ); + buf.append( "noAck=" ); + buf.append( getNoAck() ); + buf.append( ", " ); + buf.append( "exclusive=" ); + buf.append( getExclusive() ); + buf.append( ", " ); + buf.append( "nowait=" ); + buf.append( getNowait() ); + buf.append( ", " ); + buf.append( "arguments=" ); + buf.append( getArguments() ); + buf.append("]"); + return buf.toString(); + } - public int getTicket(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeBodyImpl.java deleted file mode 100644 index ea13064979..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeBodyImpl.java +++ /dev/null @@ -1,206 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicConsumeBodyImpl extends AMQMethodBodyImpl implements BasicConsumeBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicConsumeBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 20; - - // Fields declared in specification - private final int _ticket; // [ticket] - private final AMQShortString _queue; // [queue] - private final AMQShortString _consumerTag; // [consumerTag] - private final byte _bitfield0; // [noLocal, noAck, exclusive, nowait] - private final FieldTable _arguments; // [arguments] - - // Constructor - public BasicConsumeBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _ticket = readUnsignedShort( buffer ); - _queue = readAMQShortString( buffer ); - _consumerTag = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - _arguments = readFieldTable( buffer ); - } - - public BasicConsumeBodyImpl( - int ticket, - AMQShortString queue, - AMQShortString consumerTag, - boolean noLocal, - boolean noAck, - boolean exclusive, - boolean nowait, - FieldTable arguments - ) - { - _ticket = ticket; - _queue = queue; - _consumerTag = consumerTag; - byte bitfield0 = (byte)0; - if( noLocal ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - - if( noAck ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); - } - - if( exclusive ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 2)); - } - - if( nowait ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 3)); - } - - _bitfield0 = bitfield0; - _arguments = arguments; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getTicket() - { - return _ticket; - } - public final AMQShortString getQueue() - { - return _queue; - } - public final AMQShortString getConsumerTag() - { - return _consumerTag; - } - public final boolean getNoLocal() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - public final boolean getNoAck() - { - return (((int)(_bitfield0)) & ( 1 << 1)) != 0; - } - public final boolean getExclusive() - { - return (((int)(_bitfield0)) & ( 1 << 2)) != 0; - } - public final boolean getNowait() - { - return (((int)(_bitfield0)) & ( 1 << 3)) != 0; - } - public final FieldTable getArguments() - { - return _arguments; - } - - protected int getBodySize() - { - int size = 3; - size += getSizeOf( _queue ); - size += getSizeOf( _consumerTag ); - size += getSizeOf( _arguments ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _ticket ); - writeAMQShortString( buffer, _queue ); - writeAMQShortString( buffer, _consumerTag ); - writeBitfield( buffer, _bitfield0 ); - writeFieldTable( buffer, _arguments ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicConsume(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicConsumeBodyImpl: "); - buf.append( "ticket=" ); - buf.append( getTicket() ); - buf.append( ", " ); - buf.append( "queue=" ); - buf.append( getQueue() ); - buf.append( ", " ); - buf.append( "consumerTag=" ); - buf.append( getConsumerTag() ); - buf.append( ", " ); - buf.append( "noLocal=" ); - buf.append( getNoLocal() ); - buf.append( ", " ); - buf.append( "noAck=" ); - buf.append( getNoAck() ); - buf.append( ", " ); - buf.append( "exclusive=" ); - buf.append( getExclusive() ); - buf.append( ", " ); - buf.append( "nowait=" ); - buf.append( getNowait() ); - buf.append( ", " ); - buf.append( "arguments=" ); - buf.append( getArguments() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeOkBody.java index a73cb9605d..ec6cdd5130 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeOkBody.java @@ -22,15 +22,90 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicConsumeOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicConsumeOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicConsumeOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 21; + + // Fields declared in specification + private final AMQShortString _consumerTag; // [consumerTag] + + // Constructor + public BasicConsumeOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _consumerTag = readAMQShortString( buffer ); + } + + public BasicConsumeOkBody( + AMQShortString consumerTag + ) + { + _consumerTag = consumerTag; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getConsumerTag() + { + return _consumerTag; + } + + protected int getBodySize() + { + int size = 0; + size += getSizeOf( _consumerTag ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _consumerTag ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicConsumeOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicConsumeOkBodyImpl: "); + buf.append( "consumerTag=" ); + buf.append( getConsumerTag() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getConsumerTag(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeOkBodyImpl.java deleted file mode 100644 index c7f590012b..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicConsumeOkBodyImpl.java +++ /dev/null @@ -1,111 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicConsumeOkBodyImpl extends AMQMethodBodyImpl implements BasicConsumeOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicConsumeOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 21; - - // Fields declared in specification - private final AMQShortString _consumerTag; // [consumerTag] - - // Constructor - public BasicConsumeOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _consumerTag = readAMQShortString( buffer ); - } - - public BasicConsumeOkBodyImpl( - AMQShortString consumerTag - ) - { - _consumerTag = consumerTag; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getConsumerTag() - { - return _consumerTag; - } - - protected int getBodySize() - { - int size = 0; - size += getSizeOf( _consumerTag ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _consumerTag ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicConsumeOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicConsumeOkBodyImpl: "); - buf.append( "consumerTag=" ); - buf.append( getConsumerTag() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicDeliverBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicDeliverBody.java index 07781c0026..4247447d0d 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicDeliverBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicDeliverBody.java @@ -22,23 +22,146 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicDeliverBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicDeliverBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicDeliverBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 60; + + // Fields declared in specification + private final AMQShortString _consumerTag; // [consumerTag] + private final long _deliveryTag; // [deliveryTag] + private final byte _bitfield0; // [redelivered] + private final AMQShortString _exchange; // [exchange] + private final AMQShortString _routingKey; // [routingKey] + + // Constructor + public BasicDeliverBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _consumerTag = readAMQShortString( buffer ); + _deliveryTag = readLong( buffer ); + _bitfield0 = readBitfield( buffer ); + _exchange = readAMQShortString( buffer ); + _routingKey = readAMQShortString( buffer ); + } + + public BasicDeliverBody( + AMQShortString consumerTag, + long deliveryTag, + boolean redelivered, + AMQShortString exchange, + AMQShortString routingKey + ) + { + _consumerTag = consumerTag; + _deliveryTag = deliveryTag; + byte bitfield0 = (byte)0; + if( redelivered ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + + _bitfield0 = bitfield0; + _exchange = exchange; + _routingKey = routingKey; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getConsumerTag() + { + return _consumerTag; + } + public final long getDeliveryTag() + { + return _deliveryTag; + } + public final boolean getRedelivered() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + public final AMQShortString getExchange() + { + return _exchange; + } + public final AMQShortString getRoutingKey() + { + return _routingKey; + } - public AMQShortString getConsumerTag(); + protected int getBodySize() + { + int size = 9; + size += getSizeOf( _consumerTag ); + size += getSizeOf( _exchange ); + size += getSizeOf( _routingKey ); + return size; + } - public long getDeliveryTag(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _consumerTag ); + writeLong( buffer, _deliveryTag ); + writeBitfield( buffer, _bitfield0 ); + writeAMQShortString( buffer, _exchange ); + writeAMQShortString( buffer, _routingKey ); + } - public AMQShortString getExchange(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicDeliver(this, channelId); + } - public boolean getRedelivered(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicDeliverBodyImpl: "); + buf.append( "consumerTag=" ); + buf.append( getConsumerTag() ); + buf.append( ", " ); + buf.append( "deliveryTag=" ); + buf.append( getDeliveryTag() ); + buf.append( ", " ); + buf.append( "redelivered=" ); + buf.append( getRedelivered() ); + buf.append( ", " ); + buf.append( "exchange=" ); + buf.append( getExchange() ); + buf.append( ", " ); + buf.append( "routingKey=" ); + buf.append( getRoutingKey() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getRoutingKey(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicDeliverBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicDeliverBodyImpl.java deleted file mode 100644 index e1e6e1aa03..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicDeliverBodyImpl.java +++ /dev/null @@ -1,167 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicDeliverBodyImpl extends AMQMethodBodyImpl implements BasicDeliverBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicDeliverBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 60; - - // Fields declared in specification - private final AMQShortString _consumerTag; // [consumerTag] - private final long _deliveryTag; // [deliveryTag] - private final byte _bitfield0; // [redelivered] - private final AMQShortString _exchange; // [exchange] - private final AMQShortString _routingKey; // [routingKey] - - // Constructor - public BasicDeliverBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _consumerTag = readAMQShortString( buffer ); - _deliveryTag = readLong( buffer ); - _bitfield0 = readBitfield( buffer ); - _exchange = readAMQShortString( buffer ); - _routingKey = readAMQShortString( buffer ); - } - - public BasicDeliverBodyImpl( - AMQShortString consumerTag, - long deliveryTag, - boolean redelivered, - AMQShortString exchange, - AMQShortString routingKey - ) - { - _consumerTag = consumerTag; - _deliveryTag = deliveryTag; - byte bitfield0 = (byte)0; - if( redelivered ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - - _bitfield0 = bitfield0; - _exchange = exchange; - _routingKey = routingKey; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getConsumerTag() - { - return _consumerTag; - } - public final long getDeliveryTag() - { - return _deliveryTag; - } - public final boolean getRedelivered() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - public final AMQShortString getExchange() - { - return _exchange; - } - public final AMQShortString getRoutingKey() - { - return _routingKey; - } - - protected int getBodySize() - { - int size = 9; - size += getSizeOf( _consumerTag ); - size += getSizeOf( _exchange ); - size += getSizeOf( _routingKey ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _consumerTag ); - writeLong( buffer, _deliveryTag ); - writeBitfield( buffer, _bitfield0 ); - writeAMQShortString( buffer, _exchange ); - writeAMQShortString( buffer, _routingKey ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicDeliver(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicDeliverBodyImpl: "); - buf.append( "consumerTag=" ); - buf.append( getConsumerTag() ); - buf.append( ", " ); - buf.append( "deliveryTag=" ); - buf.append( getDeliveryTag() ); - buf.append( ", " ); - buf.append( "redelivered=" ); - buf.append( getRedelivered() ); - buf.append( ", " ); - buf.append( "exchange=" ); - buf.append( getExchange() ); - buf.append( ", " ); - buf.append( "routingKey=" ); - buf.append( getRoutingKey() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicGetBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicGetBody.java index b2a27cf840..9c38eb859a 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicGetBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicGetBody.java @@ -22,19 +22,119 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicGetBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicGetBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicGetBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 70; + + // Fields declared in specification + private final int _ticket; // [ticket] + private final AMQShortString _queue; // [queue] + private final byte _bitfield0; // [noAck] + + // Constructor + public BasicGetBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _ticket = readUnsignedShort( buffer ); + _queue = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public BasicGetBody( + int ticket, + AMQShortString queue, + boolean noAck + ) + { + _ticket = ticket; + _queue = queue; + byte bitfield0 = (byte)0; + if( noAck ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getTicket() + { + return _ticket; + } + public final AMQShortString getQueue() + { + return _queue; + } + public final boolean getNoAck() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 3; + size += getSizeOf( _queue ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _ticket ); + writeAMQShortString( buffer, _queue ); + writeBitfield( buffer, _bitfield0 ); + } - public boolean getNoAck(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicGet(this, channelId); + } - public AMQShortString getQueue(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicGetBodyImpl: "); + buf.append( "ticket=" ); + buf.append( getTicket() ); + buf.append( ", " ); + buf.append( "queue=" ); + buf.append( getQueue() ); + buf.append( ", " ); + buf.append( "noAck=" ); + buf.append( getNoAck() ); + buf.append("]"); + return buf.toString(); + } - public int getTicket(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicGetBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicGetBodyImpl.java deleted file mode 100644 index 3ec7d47ce8..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicGetBodyImpl.java +++ /dev/null @@ -1,140 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicGetBodyImpl extends AMQMethodBodyImpl implements BasicGetBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicGetBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 70; - - // Fields declared in specification - private final int _ticket; // [ticket] - private final AMQShortString _queue; // [queue] - private final byte _bitfield0; // [noAck] - - // Constructor - public BasicGetBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _ticket = readUnsignedShort( buffer ); - _queue = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public BasicGetBodyImpl( - int ticket, - AMQShortString queue, - boolean noAck - ) - { - _ticket = ticket; - _queue = queue; - byte bitfield0 = (byte)0; - if( noAck ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getTicket() - { - return _ticket; - } - public final AMQShortString getQueue() - { - return _queue; - } - public final boolean getNoAck() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 3; - size += getSizeOf( _queue ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _ticket ); - writeAMQShortString( buffer, _queue ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicGet(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicGetBodyImpl: "); - buf.append( "ticket=" ); - buf.append( getTicket() ); - buf.append( ", " ); - buf.append( "queue=" ); - buf.append( getQueue() ); - buf.append( ", " ); - buf.append( "noAck=" ); - buf.append( getNoAck() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicGetEmptyBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicGetEmptyBody.java index 758d15ba37..1a3d27705e 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicGetEmptyBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicGetEmptyBody.java @@ -22,15 +22,90 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicGetEmptyBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicGetEmptyBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicGetEmptyBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 72; + + // Fields declared in specification + private final AMQShortString _clusterId; // [clusterId] + + // Constructor + public BasicGetEmptyBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _clusterId = readAMQShortString( buffer ); + } + + public BasicGetEmptyBody( + AMQShortString clusterId + ) + { + _clusterId = clusterId; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getClusterId() + { + return _clusterId; + } + + protected int getBodySize() + { + int size = 0; + size += getSizeOf( _clusterId ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _clusterId ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicGetEmpty(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicGetEmptyBodyImpl: "); + buf.append( "clusterId=" ); + buf.append( getClusterId() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getClusterId(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicGetEmptyBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicGetEmptyBodyImpl.java deleted file mode 100644 index bea04254f1..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicGetEmptyBodyImpl.java +++ /dev/null @@ -1,111 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicGetEmptyBodyImpl extends AMQMethodBodyImpl implements BasicGetEmptyBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicGetEmptyBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 72; - - // Fields declared in specification - private final AMQShortString _clusterId; // [clusterId] - - // Constructor - public BasicGetEmptyBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _clusterId = readAMQShortString( buffer ); - } - - public BasicGetEmptyBodyImpl( - AMQShortString clusterId - ) - { - _clusterId = clusterId; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getClusterId() - { - return _clusterId; - } - - protected int getBodySize() - { - int size = 0; - size += getSizeOf( _clusterId ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _clusterId ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicGetEmpty(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicGetEmptyBodyImpl: "); - buf.append( "clusterId=" ); - buf.append( getClusterId() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicGetOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicGetOkBody.java index fac54d975c..2e3823482c 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicGetOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicGetOkBody.java @@ -22,23 +22,145 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicGetOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicGetOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicGetOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 71; + + // Fields declared in specification + private final long _deliveryTag; // [deliveryTag] + private final byte _bitfield0; // [redelivered] + private final AMQShortString _exchange; // [exchange] + private final AMQShortString _routingKey; // [routingKey] + private final long _messageCount; // [messageCount] + + // Constructor + public BasicGetOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _deliveryTag = readLong( buffer ); + _bitfield0 = readBitfield( buffer ); + _exchange = readAMQShortString( buffer ); + _routingKey = readAMQShortString( buffer ); + _messageCount = readUnsignedInteger( buffer ); + } + + public BasicGetOkBody( + long deliveryTag, + boolean redelivered, + AMQShortString exchange, + AMQShortString routingKey, + long messageCount + ) + { + _deliveryTag = deliveryTag; + byte bitfield0 = (byte)0; + if( redelivered ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + + _bitfield0 = bitfield0; + _exchange = exchange; + _routingKey = routingKey; + _messageCount = messageCount; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final long getDeliveryTag() + { + return _deliveryTag; + } + public final boolean getRedelivered() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + public final AMQShortString getExchange() + { + return _exchange; + } + public final AMQShortString getRoutingKey() + { + return _routingKey; + } + public final long getMessageCount() + { + return _messageCount; + } - public long getDeliveryTag(); + protected int getBodySize() + { + int size = 13; + size += getSizeOf( _exchange ); + size += getSizeOf( _routingKey ); + return size; + } - public AMQShortString getExchange(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeLong( buffer, _deliveryTag ); + writeBitfield( buffer, _bitfield0 ); + writeAMQShortString( buffer, _exchange ); + writeAMQShortString( buffer, _routingKey ); + writeUnsignedInteger( buffer, _messageCount ); + } - public long getMessageCount(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicGetOk(this, channelId); + } - public boolean getRedelivered(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicGetOkBodyImpl: "); + buf.append( "deliveryTag=" ); + buf.append( getDeliveryTag() ); + buf.append( ", " ); + buf.append( "redelivered=" ); + buf.append( getRedelivered() ); + buf.append( ", " ); + buf.append( "exchange=" ); + buf.append( getExchange() ); + buf.append( ", " ); + buf.append( "routingKey=" ); + buf.append( getRoutingKey() ); + buf.append( ", " ); + buf.append( "messageCount=" ); + buf.append( getMessageCount() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getRoutingKey(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicGetOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicGetOkBodyImpl.java deleted file mode 100644 index f2573ab25d..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicGetOkBodyImpl.java +++ /dev/null @@ -1,166 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicGetOkBodyImpl extends AMQMethodBodyImpl implements BasicGetOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicGetOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 71; - - // Fields declared in specification - private final long _deliveryTag; // [deliveryTag] - private final byte _bitfield0; // [redelivered] - private final AMQShortString _exchange; // [exchange] - private final AMQShortString _routingKey; // [routingKey] - private final long _messageCount; // [messageCount] - - // Constructor - public BasicGetOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _deliveryTag = readLong( buffer ); - _bitfield0 = readBitfield( buffer ); - _exchange = readAMQShortString( buffer ); - _routingKey = readAMQShortString( buffer ); - _messageCount = readUnsignedInteger( buffer ); - } - - public BasicGetOkBodyImpl( - long deliveryTag, - boolean redelivered, - AMQShortString exchange, - AMQShortString routingKey, - long messageCount - ) - { - _deliveryTag = deliveryTag; - byte bitfield0 = (byte)0; - if( redelivered ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - - _bitfield0 = bitfield0; - _exchange = exchange; - _routingKey = routingKey; - _messageCount = messageCount; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final long getDeliveryTag() - { - return _deliveryTag; - } - public final boolean getRedelivered() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - public final AMQShortString getExchange() - { - return _exchange; - } - public final AMQShortString getRoutingKey() - { - return _routingKey; - } - public final long getMessageCount() - { - return _messageCount; - } - - protected int getBodySize() - { - int size = 13; - size += getSizeOf( _exchange ); - size += getSizeOf( _routingKey ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeLong( buffer, _deliveryTag ); - writeBitfield( buffer, _bitfield0 ); - writeAMQShortString( buffer, _exchange ); - writeAMQShortString( buffer, _routingKey ); - writeUnsignedInteger( buffer, _messageCount ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicGetOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicGetOkBodyImpl: "); - buf.append( "deliveryTag=" ); - buf.append( getDeliveryTag() ); - buf.append( ", " ); - buf.append( "redelivered=" ); - buf.append( getRedelivered() ); - buf.append( ", " ); - buf.append( "exchange=" ); - buf.append( getExchange() ); - buf.append( ", " ); - buf.append( "routingKey=" ); - buf.append( getRoutingKey() ); - buf.append( ", " ); - buf.append( "messageCount=" ); - buf.append( getMessageCount() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicPublishBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicPublishBody.java index f71e012cd8..6246f46651 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicPublishBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicPublishBody.java @@ -22,23 +22,145 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicPublishBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicPublishBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicPublishBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 40; + + // Fields declared in specification + private final int _ticket; // [ticket] + private final AMQShortString _exchange; // [exchange] + private final AMQShortString _routingKey; // [routingKey] + private final byte _bitfield0; // [mandatory, immediate] + + // Constructor + public BasicPublishBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _ticket = readUnsignedShort( buffer ); + _exchange = readAMQShortString( buffer ); + _routingKey = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public BasicPublishBody( + int ticket, + AMQShortString exchange, + AMQShortString routingKey, + boolean mandatory, + boolean immediate + ) + { + _ticket = ticket; + _exchange = exchange; + _routingKey = routingKey; + byte bitfield0 = (byte)0; + if( mandatory ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + + if( immediate ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getTicket() + { + return _ticket; + } + public final AMQShortString getExchange() + { + return _exchange; + } + public final AMQShortString getRoutingKey() + { + return _routingKey; + } + public final boolean getMandatory() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + public final boolean getImmediate() + { + return (((int)(_bitfield0)) & ( 1 << 1)) != 0; + } - public AMQShortString getExchange(); + protected int getBodySize() + { + int size = 3; + size += getSizeOf( _exchange ); + size += getSizeOf( _routingKey ); + return size; + } - public boolean getImmediate(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _ticket ); + writeAMQShortString( buffer, _exchange ); + writeAMQShortString( buffer, _routingKey ); + writeBitfield( buffer, _bitfield0 ); + } - public boolean getMandatory(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicPublish(this, channelId); + } - public AMQShortString getRoutingKey(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicPublishBodyImpl: "); + buf.append( "ticket=" ); + buf.append( getTicket() ); + buf.append( ", " ); + buf.append( "exchange=" ); + buf.append( getExchange() ); + buf.append( ", " ); + buf.append( "routingKey=" ); + buf.append( getRoutingKey() ); + buf.append( ", " ); + buf.append( "mandatory=" ); + buf.append( getMandatory() ); + buf.append( ", " ); + buf.append( "immediate=" ); + buf.append( getImmediate() ); + buf.append("]"); + return buf.toString(); + } - public int getTicket(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicPublishBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicPublishBodyImpl.java deleted file mode 100644 index db49a34081..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicPublishBodyImpl.java +++ /dev/null @@ -1,166 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicPublishBodyImpl extends AMQMethodBodyImpl implements BasicPublishBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicPublishBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 40; - - // Fields declared in specification - private final int _ticket; // [ticket] - private final AMQShortString _exchange; // [exchange] - private final AMQShortString _routingKey; // [routingKey] - private final byte _bitfield0; // [mandatory, immediate] - - // Constructor - public BasicPublishBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _ticket = readUnsignedShort( buffer ); - _exchange = readAMQShortString( buffer ); - _routingKey = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public BasicPublishBodyImpl( - int ticket, - AMQShortString exchange, - AMQShortString routingKey, - boolean mandatory, - boolean immediate - ) - { - _ticket = ticket; - _exchange = exchange; - _routingKey = routingKey; - byte bitfield0 = (byte)0; - if( mandatory ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - - if( immediate ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getTicket() - { - return _ticket; - } - public final AMQShortString getExchange() - { - return _exchange; - } - public final AMQShortString getRoutingKey() - { - return _routingKey; - } - public final boolean getMandatory() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - public final boolean getImmediate() - { - return (((int)(_bitfield0)) & ( 1 << 1)) != 0; - } - - protected int getBodySize() - { - int size = 3; - size += getSizeOf( _exchange ); - size += getSizeOf( _routingKey ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _ticket ); - writeAMQShortString( buffer, _exchange ); - writeAMQShortString( buffer, _routingKey ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicPublish(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicPublishBodyImpl: "); - buf.append( "ticket=" ); - buf.append( getTicket() ); - buf.append( ", " ); - buf.append( "exchange=" ); - buf.append( getExchange() ); - buf.append( ", " ); - buf.append( "routingKey=" ); - buf.append( getRoutingKey() ); - buf.append( ", " ); - buf.append( "mandatory=" ); - buf.append( getMandatory() ); - buf.append( ", " ); - buf.append( "immediate=" ); - buf.append( getImmediate() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicQosBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicQosBody.java index 909a5dae8b..28f657ee95 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicQosBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicQosBody.java @@ -22,19 +22,118 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicQosBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicQosBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicQosBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 10; + + // Fields declared in specification + private final long _prefetchSize; // [prefetchSize] + private final int _prefetchCount; // [prefetchCount] + private final byte _bitfield0; // [global] + + // Constructor + public BasicQosBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _prefetchSize = readUnsignedInteger( buffer ); + _prefetchCount = readUnsignedShort( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public BasicQosBody( + long prefetchSize, + int prefetchCount, + boolean global + ) + { + _prefetchSize = prefetchSize; + _prefetchCount = prefetchCount; + byte bitfield0 = (byte)0; + if( global ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final long getPrefetchSize() + { + return _prefetchSize; + } + public final int getPrefetchCount() + { + return _prefetchCount; + } + public final boolean getGlobal() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 7; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedInteger( buffer, _prefetchSize ); + writeUnsignedShort( buffer, _prefetchCount ); + writeBitfield( buffer, _bitfield0 ); + } - public boolean getGlobal(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicQos(this, channelId); + } - public int getPrefetchCount(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicQosBodyImpl: "); + buf.append( "prefetchSize=" ); + buf.append( getPrefetchSize() ); + buf.append( ", " ); + buf.append( "prefetchCount=" ); + buf.append( getPrefetchCount() ); + buf.append( ", " ); + buf.append( "global=" ); + buf.append( getGlobal() ); + buf.append("]"); + return buf.toString(); + } - public long getPrefetchSize(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicQosBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicQosBodyImpl.java deleted file mode 100644 index b96fa0b67d..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicQosBodyImpl.java +++ /dev/null @@ -1,139 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicQosBodyImpl extends AMQMethodBodyImpl implements BasicQosBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicQosBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 10; - - // Fields declared in specification - private final long _prefetchSize; // [prefetchSize] - private final int _prefetchCount; // [prefetchCount] - private final byte _bitfield0; // [global] - - // Constructor - public BasicQosBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _prefetchSize = readUnsignedInteger( buffer ); - _prefetchCount = readUnsignedShort( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public BasicQosBodyImpl( - long prefetchSize, - int prefetchCount, - boolean global - ) - { - _prefetchSize = prefetchSize; - _prefetchCount = prefetchCount; - byte bitfield0 = (byte)0; - if( global ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final long getPrefetchSize() - { - return _prefetchSize; - } - public final int getPrefetchCount() - { - return _prefetchCount; - } - public final boolean getGlobal() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 7; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedInteger( buffer, _prefetchSize ); - writeUnsignedShort( buffer, _prefetchCount ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicQos(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicQosBodyImpl: "); - buf.append( "prefetchSize=" ); - buf.append( getPrefetchSize() ); - buf.append( ", " ); - buf.append( "prefetchCount=" ); - buf.append( getPrefetchCount() ); - buf.append( ", " ); - buf.append( "global=" ); - buf.append( getGlobal() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicQosOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicQosOkBody.java index b37cd30e73..824e5f6111 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicQosOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicQosOkBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicQosOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicQosOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicQosOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 11; + + // Fields declared in specification + + // Constructor + public BasicQosOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public BasicQosOkBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicQosOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicQosOkBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicQosOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicQosOkBodyImpl.java deleted file mode 100644 index 9f60a2225c..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicQosOkBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicQosOkBodyImpl extends AMQMethodBodyImpl implements BasicQosOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicQosOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 11; - - // Fields declared in specification - - // Constructor - public BasicQosOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public BasicQosOkBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicQosOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicQosOkBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicRecoverBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicRecoverBody.java index 57e5637222..526e9e0df3 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicRecoverBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicRecoverBody.java @@ -22,15 +22,94 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicRecoverBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicRecoverBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicRecoverBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 100; + + // Fields declared in specification + private final byte _bitfield0; // [requeue] + + // Constructor + public BasicRecoverBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _bitfield0 = readBitfield( buffer ); + } + + public BasicRecoverBody( + boolean requeue + ) + { + byte bitfield0 = (byte)0; + if( requeue ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final boolean getRequeue() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 1; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeBitfield( buffer, _bitfield0 ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicRecover(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicRecoverBodyImpl: "); + buf.append( "requeue=" ); + buf.append( getRequeue() ); + buf.append("]"); + return buf.toString(); + } - public boolean getRequeue(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicRecoverBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicRecoverBodyImpl.java deleted file mode 100644 index 12f79e37f5..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicRecoverBodyImpl.java +++ /dev/null @@ -1,115 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicRecoverBodyImpl extends AMQMethodBodyImpl implements BasicRecoverBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicRecoverBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 100; - - // Fields declared in specification - private final byte _bitfield0; // [requeue] - - // Constructor - public BasicRecoverBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _bitfield0 = readBitfield( buffer ); - } - - public BasicRecoverBodyImpl( - boolean requeue - ) - { - byte bitfield0 = (byte)0; - if( requeue ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final boolean getRequeue() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 1; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicRecover(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicRecoverBodyImpl: "); - buf.append( "requeue=" ); - buf.append( getRequeue() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicRejectBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicRejectBody.java index 87cd1083fb..69f84390a7 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicRejectBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicRejectBody.java @@ -22,17 +22,106 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicRejectBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicRejectBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicRejectBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 90; + + // Fields declared in specification + private final long _deliveryTag; // [deliveryTag] + private final byte _bitfield0; // [requeue] + + // Constructor + public BasicRejectBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _deliveryTag = readLong( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public BasicRejectBody( + long deliveryTag, + boolean requeue + ) + { + _deliveryTag = deliveryTag; + byte bitfield0 = (byte)0; + if( requeue ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final long getDeliveryTag() + { + return _deliveryTag; + } + public final boolean getRequeue() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 9; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeLong( buffer, _deliveryTag ); + writeBitfield( buffer, _bitfield0 ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicReject(this, channelId); + } - public long getDeliveryTag(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicRejectBodyImpl: "); + buf.append( "deliveryTag=" ); + buf.append( getDeliveryTag() ); + buf.append( ", " ); + buf.append( "requeue=" ); + buf.append( getRequeue() ); + buf.append("]"); + return buf.toString(); + } - public boolean getRequeue(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicRejectBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicRejectBodyImpl.java deleted file mode 100644 index a4cce3cb50..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicRejectBodyImpl.java +++ /dev/null @@ -1,127 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicRejectBodyImpl extends AMQMethodBodyImpl implements BasicRejectBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicRejectBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 90; - - // Fields declared in specification - private final long _deliveryTag; // [deliveryTag] - private final byte _bitfield0; // [requeue] - - // Constructor - public BasicRejectBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _deliveryTag = readLong( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public BasicRejectBodyImpl( - long deliveryTag, - boolean requeue - ) - { - _deliveryTag = deliveryTag; - byte bitfield0 = (byte)0; - if( requeue ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final long getDeliveryTag() - { - return _deliveryTag; - } - public final boolean getRequeue() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 9; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeLong( buffer, _deliveryTag ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicReject(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicRejectBodyImpl: "); - buf.append( "deliveryTag=" ); - buf.append( getDeliveryTag() ); - buf.append( ", " ); - buf.append( "requeue=" ); - buf.append( getRequeue() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicReturnBody.java b/java/common/src/main/java/org/apache/qpid/framing/BasicReturnBody.java index ace37b61fa..aa1fa61e81 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicReturnBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/BasicReturnBody.java @@ -22,21 +22,128 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface BasicReturnBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class BasicReturnBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new BasicReturnBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 60; + public static final int METHOD_ID = 50; + + // Fields declared in specification + private final int _replyCode; // [replyCode] + private final AMQShortString _replyText; // [replyText] + private final AMQShortString _exchange; // [exchange] + private final AMQShortString _routingKey; // [routingKey] + + // Constructor + public BasicReturnBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _replyCode = readUnsignedShort( buffer ); + _replyText = readAMQShortString( buffer ); + _exchange = readAMQShortString( buffer ); + _routingKey = readAMQShortString( buffer ); + } + + public BasicReturnBody( + int replyCode, + AMQShortString replyText, + AMQShortString exchange, + AMQShortString routingKey + ) + { + _replyCode = replyCode; + _replyText = replyText; + _exchange = exchange; + _routingKey = routingKey; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getReplyCode() + { + return _replyCode; + } + public final AMQShortString getReplyText() + { + return _replyText; + } + public final AMQShortString getExchange() + { + return _exchange; + } + public final AMQShortString getRoutingKey() + { + return _routingKey; + } + + protected int getBodySize() + { + int size = 2; + size += getSizeOf( _replyText ); + size += getSizeOf( _exchange ); + size += getSizeOf( _routingKey ); + return size; + } - public AMQShortString getExchange(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _replyCode ); + writeAMQShortString( buffer, _replyText ); + writeAMQShortString( buffer, _exchange ); + writeAMQShortString( buffer, _routingKey ); + } - public int getReplyCode(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchBasicReturn(this, channelId); + } - public AMQShortString getReplyText(); + public String toString() + { + StringBuilder buf = new StringBuilder("[BasicReturnBodyImpl: "); + buf.append( "replyCode=" ); + buf.append( getReplyCode() ); + buf.append( ", " ); + buf.append( "replyText=" ); + buf.append( getReplyText() ); + buf.append( ", " ); + buf.append( "exchange=" ); + buf.append( getExchange() ); + buf.append( ", " ); + buf.append( "routingKey=" ); + buf.append( getRoutingKey() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getRoutingKey(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/BasicReturnBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/BasicReturnBodyImpl.java deleted file mode 100644 index e19227bb19..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/BasicReturnBodyImpl.java +++ /dev/null @@ -1,149 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class BasicReturnBodyImpl extends AMQMethodBodyImpl implements BasicReturnBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new BasicReturnBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 60; - public static final int METHOD_ID = 50; - - // Fields declared in specification - private final int _replyCode; // [replyCode] - private final AMQShortString _replyText; // [replyText] - private final AMQShortString _exchange; // [exchange] - private final AMQShortString _routingKey; // [routingKey] - - // Constructor - public BasicReturnBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _replyCode = readUnsignedShort( buffer ); - _replyText = readAMQShortString( buffer ); - _exchange = readAMQShortString( buffer ); - _routingKey = readAMQShortString( buffer ); - } - - public BasicReturnBodyImpl( - int replyCode, - AMQShortString replyText, - AMQShortString exchange, - AMQShortString routingKey - ) - { - _replyCode = replyCode; - _replyText = replyText; - _exchange = exchange; - _routingKey = routingKey; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getReplyCode() - { - return _replyCode; - } - public final AMQShortString getReplyText() - { - return _replyText; - } - public final AMQShortString getExchange() - { - return _exchange; - } - public final AMQShortString getRoutingKey() - { - return _routingKey; - } - - protected int getBodySize() - { - int size = 2; - size += getSizeOf( _replyText ); - size += getSizeOf( _exchange ); - size += getSizeOf( _routingKey ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _replyCode ); - writeAMQShortString( buffer, _replyText ); - writeAMQShortString( buffer, _exchange ); - writeAMQShortString( buffer, _routingKey ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchBasicReturn(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[BasicReturnBodyImpl: "); - buf.append( "replyCode=" ); - buf.append( getReplyCode() ); - buf.append( ", " ); - buf.append( "replyText=" ); - buf.append( getReplyText() ); - buf.append( ", " ); - buf.append( "exchange=" ); - buf.append( getExchange() ); - buf.append( ", " ); - buf.append( "routingKey=" ); - buf.append( getRoutingKey() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseBody.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseBody.java index d791b9125e..62eb7f3986 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseBody.java @@ -22,21 +22,126 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ChannelCloseBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ChannelCloseBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ChannelCloseBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 20; + public static final int METHOD_ID = 40; + + // Fields declared in specification + private final int _replyCode; // [replyCode] + private final AMQShortString _replyText; // [replyText] + private final int _classId; // [classId] + private final int _methodId; // [methodId] + + // Constructor + public ChannelCloseBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _replyCode = readUnsignedShort( buffer ); + _replyText = readAMQShortString( buffer ); + _classId = readUnsignedShort( buffer ); + _methodId = readUnsignedShort( buffer ); + } + + public ChannelCloseBody( + int replyCode, + AMQShortString replyText, + int classId, + int methodId + ) + { + _replyCode = replyCode; + _replyText = replyText; + _classId = classId; + _methodId = methodId; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getReplyCode() + { + return _replyCode; + } + public final AMQShortString getReplyText() + { + return _replyText; + } + public final int getClassId() + { + return _classId; + } + public final int getMethodId() + { + return _methodId; + } + + protected int getBodySize() + { + int size = 6; + size += getSizeOf( _replyText ); + return size; + } - public int getClassId(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _replyCode ); + writeAMQShortString( buffer, _replyText ); + writeUnsignedShort( buffer, _classId ); + writeUnsignedShort( buffer, _methodId ); + } - public int getMethodId(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchChannelClose(this, channelId); + } - public int getReplyCode(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ChannelCloseBodyImpl: "); + buf.append( "replyCode=" ); + buf.append( getReplyCode() ); + buf.append( ", " ); + buf.append( "replyText=" ); + buf.append( getReplyText() ); + buf.append( ", " ); + buf.append( "classId=" ); + buf.append( getClassId() ); + buf.append( ", " ); + buf.append( "methodId=" ); + buf.append( getMethodId() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getReplyText(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseBodyImpl.java deleted file mode 100644 index 2fc0e1557e..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseBodyImpl.java +++ /dev/null @@ -1,147 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ChannelCloseBodyImpl extends AMQMethodBodyImpl implements ChannelCloseBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ChannelCloseBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 20; - public static final int METHOD_ID = 40; - - // Fields declared in specification - private final int _replyCode; // [replyCode] - private final AMQShortString _replyText; // [replyText] - private final int _classId; // [classId] - private final int _methodId; // [methodId] - - // Constructor - public ChannelCloseBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _replyCode = readUnsignedShort( buffer ); - _replyText = readAMQShortString( buffer ); - _classId = readUnsignedShort( buffer ); - _methodId = readUnsignedShort( buffer ); - } - - public ChannelCloseBodyImpl( - int replyCode, - AMQShortString replyText, - int classId, - int methodId - ) - { - _replyCode = replyCode; - _replyText = replyText; - _classId = classId; - _methodId = methodId; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getReplyCode() - { - return _replyCode; - } - public final AMQShortString getReplyText() - { - return _replyText; - } - public final int getClassId() - { - return _classId; - } - public final int getMethodId() - { - return _methodId; - } - - protected int getBodySize() - { - int size = 6; - size += getSizeOf( _replyText ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _replyCode ); - writeAMQShortString( buffer, _replyText ); - writeUnsignedShort( buffer, _classId ); - writeUnsignedShort( buffer, _methodId ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchChannelClose(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ChannelCloseBodyImpl: "); - buf.append( "replyCode=" ); - buf.append( getReplyCode() ); - buf.append( ", " ); - buf.append( "replyText=" ); - buf.append( getReplyText() ); - buf.append( ", " ); - buf.append( "classId=" ); - buf.append( getClassId() ); - buf.append( ", " ); - buf.append( "methodId=" ); - buf.append( getMethodId() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseOkBody.java index 4d9b8b4c3a..66b01ce0d4 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseOkBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ChannelCloseOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ChannelCloseOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ChannelCloseOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 20; + public static final int METHOD_ID = 41; + + // Fields declared in specification + + // Constructor + public ChannelCloseOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public ChannelCloseOkBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchChannelCloseOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[ChannelCloseOkBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseOkBodyImpl.java deleted file mode 100644 index 6b9f14c46b..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelCloseOkBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ChannelCloseOkBodyImpl extends AMQMethodBodyImpl implements ChannelCloseOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ChannelCloseOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 20; - public static final int METHOD_ID = 41; - - // Fields declared in specification - - // Constructor - public ChannelCloseOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public ChannelCloseOkBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchChannelCloseOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ChannelCloseOkBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowBody.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowBody.java index 08a75df9a5..096b6f8704 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowBody.java @@ -22,15 +22,94 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ChannelFlowBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ChannelFlowBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ChannelFlowBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 20; + public static final int METHOD_ID = 20; + + // Fields declared in specification + private final byte _bitfield0; // [active] + + // Constructor + public ChannelFlowBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _bitfield0 = readBitfield( buffer ); + } + + public ChannelFlowBody( + boolean active + ) + { + byte bitfield0 = (byte)0; + if( active ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final boolean getActive() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 1; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeBitfield( buffer, _bitfield0 ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchChannelFlow(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[ChannelFlowBodyImpl: "); + buf.append( "active=" ); + buf.append( getActive() ); + buf.append("]"); + return buf.toString(); + } - public boolean getActive(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowBodyImpl.java deleted file mode 100644 index cfefa9f45a..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowBodyImpl.java +++ /dev/null @@ -1,115 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ChannelFlowBodyImpl extends AMQMethodBodyImpl implements ChannelFlowBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ChannelFlowBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 20; - public static final int METHOD_ID = 20; - - // Fields declared in specification - private final byte _bitfield0; // [active] - - // Constructor - public ChannelFlowBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _bitfield0 = readBitfield( buffer ); - } - - public ChannelFlowBodyImpl( - boolean active - ) - { - byte bitfield0 = (byte)0; - if( active ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final boolean getActive() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 1; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchChannelFlow(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ChannelFlowBodyImpl: "); - buf.append( "active=" ); - buf.append( getActive() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowOkBody.java index 750156ea9c..c2bc6619c7 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowOkBody.java @@ -22,15 +22,94 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ChannelFlowOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ChannelFlowOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ChannelFlowOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 20; + public static final int METHOD_ID = 21; + + // Fields declared in specification + private final byte _bitfield0; // [active] + + // Constructor + public ChannelFlowOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _bitfield0 = readBitfield( buffer ); + } + + public ChannelFlowOkBody( + boolean active + ) + { + byte bitfield0 = (byte)0; + if( active ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final boolean getActive() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 1; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeBitfield( buffer, _bitfield0 ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchChannelFlowOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[ChannelFlowOkBodyImpl: "); + buf.append( "active=" ); + buf.append( getActive() ); + buf.append("]"); + return buf.toString(); + } - public boolean getActive(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowOkBodyImpl.java deleted file mode 100644 index 1f4d3b6f80..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelFlowOkBodyImpl.java +++ /dev/null @@ -1,115 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ChannelFlowOkBodyImpl extends AMQMethodBodyImpl implements ChannelFlowOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ChannelFlowOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 20; - public static final int METHOD_ID = 21; - - // Fields declared in specification - private final byte _bitfield0; // [active] - - // Constructor - public ChannelFlowOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _bitfield0 = readBitfield( buffer ); - } - - public ChannelFlowOkBodyImpl( - boolean active - ) - { - byte bitfield0 = (byte)0; - if( active ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final boolean getActive() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 1; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchChannelFlowOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ChannelFlowOkBodyImpl: "); - buf.append( "active=" ); - buf.append( getActive() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelOpenBody.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelOpenBody.java index 0333cdae9f..49b5e9c6cb 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelOpenBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ChannelOpenBody.java @@ -22,15 +22,90 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ChannelOpenBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ChannelOpenBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ChannelOpenBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 20; + public static final int METHOD_ID = 10; + + // Fields declared in specification + private final AMQShortString _outOfBand; // [outOfBand] + + // Constructor + public ChannelOpenBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _outOfBand = readAMQShortString( buffer ); + } + + public ChannelOpenBody( + AMQShortString outOfBand + ) + { + _outOfBand = outOfBand; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getOutOfBand() + { + return _outOfBand; + } + + protected int getBodySize() + { + int size = 0; + size += getSizeOf( _outOfBand ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _outOfBand ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchChannelOpen(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[ChannelOpenBodyImpl: "); + buf.append( "outOfBand=" ); + buf.append( getOutOfBand() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getOutOfBand(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ChannelOpenBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ChannelOpenBodyImpl.java deleted file mode 100644 index 0473d9289e..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ChannelOpenBodyImpl.java +++ /dev/null @@ -1,111 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ChannelOpenBodyImpl extends AMQMethodBodyImpl implements ChannelOpenBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ChannelOpenBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 20; - public static final int METHOD_ID = 10; - - // Fields declared in specification - private final AMQShortString _outOfBand; // [outOfBand] - - // Constructor - public ChannelOpenBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _outOfBand = readAMQShortString( buffer ); - } - - public ChannelOpenBodyImpl( - AMQShortString outOfBand - ) - { - _outOfBand = outOfBand; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getOutOfBand() - { - return _outOfBand; - } - - protected int getBodySize() - { - int size = 0; - size += getSizeOf( _outOfBand ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _outOfBand ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchChannelOpen(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ChannelOpenBodyImpl: "); - buf.append( "outOfBand=" ); - buf.append( getOutOfBand() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ClientMethodDispatcher.java b/java/common/src/main/java/org/apache/qpid/framing/ClientMethodDispatcher.java index 0b31d99463..bc92212590 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ClientMethodDispatcher.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ClientMethodDispatcher.java @@ -63,4 +63,4 @@ public interface ClientMethodDispatcher public boolean dispatchTxRollbackOk(TxRollbackOkBody body, int channelId) throws AMQException; public boolean dispatchTxSelectOk(TxSelectOkBody body, int channelId) throws AMQException; -}
\ No newline at end of file +} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenBody.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenBody.java index cfa52b5f44..d643151bb0 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenBody.java @@ -22,19 +22,120 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ConnectionOpenBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ConnectionOpenBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ConnectionOpenBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 10; + public static final int METHOD_ID = 40; + + // Fields declared in specification + private final AMQShortString _virtualHost; // [virtualHost] + private final AMQShortString _capabilities; // [capabilities] + private final byte _bitfield0; // [insist] + + // Constructor + public ConnectionOpenBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _virtualHost = readAMQShortString( buffer ); + _capabilities = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public ConnectionOpenBody( + AMQShortString virtualHost, + AMQShortString capabilities, + boolean insist + ) + { + _virtualHost = virtualHost; + _capabilities = capabilities; + byte bitfield0 = (byte)0; + if( insist ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getVirtualHost() + { + return _virtualHost; + } + public final AMQShortString getCapabilities() + { + return _capabilities; + } + public final boolean getInsist() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 1; + size += getSizeOf( _virtualHost ); + size += getSizeOf( _capabilities ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _virtualHost ); + writeAMQShortString( buffer, _capabilities ); + writeBitfield( buffer, _bitfield0 ); + } - public AMQShortString getCapabilities(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchConnectionOpen(this, channelId); + } - public boolean getInsist(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ConnectionOpenBodyImpl: "); + buf.append( "virtualHost=" ); + buf.append( getVirtualHost() ); + buf.append( ", " ); + buf.append( "capabilities=" ); + buf.append( getCapabilities() ); + buf.append( ", " ); + buf.append( "insist=" ); + buf.append( getInsist() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getVirtualHost(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenBodyImpl.java deleted file mode 100644 index 3d7b4a5620..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenBodyImpl.java +++ /dev/null @@ -1,141 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ConnectionOpenBodyImpl extends AMQMethodBodyImpl implements ConnectionOpenBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ConnectionOpenBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 10; - public static final int METHOD_ID = 40; - - // Fields declared in specification - private final AMQShortString _virtualHost; // [virtualHost] - private final AMQShortString _capabilities; // [capabilities] - private final byte _bitfield0; // [insist] - - // Constructor - public ConnectionOpenBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _virtualHost = readAMQShortString( buffer ); - _capabilities = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public ConnectionOpenBodyImpl( - AMQShortString virtualHost, - AMQShortString capabilities, - boolean insist - ) - { - _virtualHost = virtualHost; - _capabilities = capabilities; - byte bitfield0 = (byte)0; - if( insist ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getVirtualHost() - { - return _virtualHost; - } - public final AMQShortString getCapabilities() - { - return _capabilities; - } - public final boolean getInsist() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 1; - size += getSizeOf( _virtualHost ); - size += getSizeOf( _capabilities ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _virtualHost ); - writeAMQShortString( buffer, _capabilities ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchConnectionOpen(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ConnectionOpenBodyImpl: "); - buf.append( "virtualHost=" ); - buf.append( getVirtualHost() ); - buf.append( ", " ); - buf.append( "capabilities=" ); - buf.append( getCapabilities() ); - buf.append( ", " ); - buf.append( "insist=" ); - buf.append( getInsist() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenOkBody.java index eb2122fd74..26f1e45475 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenOkBody.java @@ -22,15 +22,90 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ConnectionOpenOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ConnectionOpenOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ConnectionOpenOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 10; + public static final int METHOD_ID = 41; + + // Fields declared in specification + private final AMQShortString _knownHosts; // [knownHosts] + + // Constructor + public ConnectionOpenOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _knownHosts = readAMQShortString( buffer ); + } + + public ConnectionOpenOkBody( + AMQShortString knownHosts + ) + { + _knownHosts = knownHosts; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getKnownHosts() + { + return _knownHosts; + } + + protected int getBodySize() + { + int size = 0; + size += getSizeOf( _knownHosts ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _knownHosts ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchConnectionOpenOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[ConnectionOpenOkBodyImpl: "); + buf.append( "knownHosts=" ); + buf.append( getKnownHosts() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getKnownHosts(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenOkBodyImpl.java deleted file mode 100644 index 34bce76500..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionOpenOkBodyImpl.java +++ /dev/null @@ -1,111 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ConnectionOpenOkBodyImpl extends AMQMethodBodyImpl implements ConnectionOpenOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ConnectionOpenOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 10; - public static final int METHOD_ID = 41; - - // Fields declared in specification - private final AMQShortString _knownHosts; // [knownHosts] - - // Constructor - public ConnectionOpenOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _knownHosts = readAMQShortString( buffer ); - } - - public ConnectionOpenOkBodyImpl( - AMQShortString knownHosts - ) - { - _knownHosts = knownHosts; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getKnownHosts() - { - return _knownHosts; - } - - protected int getBodySize() - { - int size = 0; - size += getSizeOf( _knownHosts ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _knownHosts ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchConnectionOpenOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ConnectionOpenOkBodyImpl: "); - buf.append( "knownHosts=" ); - buf.append( getKnownHosts() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureBody.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureBody.java index ebcdc2cf4d..6fcde5f96e 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureBody.java @@ -22,15 +22,90 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ConnectionSecureBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ConnectionSecureBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ConnectionSecureBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 10; + public static final int METHOD_ID = 20; + + // Fields declared in specification + private final byte[] _challenge; // [challenge] + + // Constructor + public ConnectionSecureBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _challenge = readBytes( buffer ); + } + + public ConnectionSecureBody( + byte[] challenge + ) + { + _challenge = challenge; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final byte[] getChallenge() + { + return _challenge; + } + + protected int getBodySize() + { + int size = 0; + size += getSizeOf( _challenge ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeBytes( buffer, _challenge ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchConnectionSecure(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[ConnectionSecureBodyImpl: "); + buf.append( "challenge=" ); + buf.append( getChallenge() == null ? "null" : java.util.Arrays.toString( getChallenge() ) ); + buf.append("]"); + return buf.toString(); + } - public byte[] getChallenge(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureBodyImpl.java deleted file mode 100644 index 429ad56855..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureBodyImpl.java +++ /dev/null @@ -1,111 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ConnectionSecureBodyImpl extends AMQMethodBodyImpl implements ConnectionSecureBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ConnectionSecureBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 10; - public static final int METHOD_ID = 20; - - // Fields declared in specification - private final byte[] _challenge; // [challenge] - - // Constructor - public ConnectionSecureBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _challenge = readBytes( buffer ); - } - - public ConnectionSecureBodyImpl( - byte[] challenge - ) - { - _challenge = challenge; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final byte[] getChallenge() - { - return _challenge; - } - - protected int getBodySize() - { - int size = 0; - size += getSizeOf( _challenge ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeBytes( buffer, _challenge ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchConnectionSecure(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ConnectionSecureBodyImpl: "); - buf.append( "challenge=" ); - buf.append( getChallenge() == null ? "null" : java.util.Arrays.toString( getChallenge() ) ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureOkBody.java index 7abbe9d18c..69c3cecefd 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureOkBody.java @@ -22,15 +22,90 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ConnectionSecureOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ConnectionSecureOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ConnectionSecureOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 10; + public static final int METHOD_ID = 21; + + // Fields declared in specification + private final byte[] _response; // [response] + + // Constructor + public ConnectionSecureOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _response = readBytes( buffer ); + } + + public ConnectionSecureOkBody( + byte[] response + ) + { + _response = response; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final byte[] getResponse() + { + return _response; + } + + protected int getBodySize() + { + int size = 0; + size += getSizeOf( _response ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeBytes( buffer, _response ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchConnectionSecureOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[ConnectionSecureOkBodyImpl: "); + buf.append( "response=" ); + buf.append( getResponse() == null ? "null" : java.util.Arrays.toString( getResponse() ) ); + buf.append("]"); + return buf.toString(); + } - public byte[] getResponse(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureOkBodyImpl.java deleted file mode 100644 index 1fbec8b627..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionSecureOkBodyImpl.java +++ /dev/null @@ -1,111 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ConnectionSecureOkBodyImpl extends AMQMethodBodyImpl implements ConnectionSecureOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ConnectionSecureOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 10; - public static final int METHOD_ID = 21; - - // Fields declared in specification - private final byte[] _response; // [response] - - // Constructor - public ConnectionSecureOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _response = readBytes( buffer ); - } - - public ConnectionSecureOkBodyImpl( - byte[] response - ) - { - _response = response; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final byte[] getResponse() - { - return _response; - } - - protected int getBodySize() - { - int size = 0; - size += getSizeOf( _response ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeBytes( buffer, _response ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchConnectionSecureOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ConnectionSecureOkBodyImpl: "); - buf.append( "response=" ); - buf.append( getResponse() == null ? "null" : java.util.Arrays.toString( getResponse() ) ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartBody.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartBody.java index 3219a9f392..f393dc8cff 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartBody.java @@ -22,23 +22,140 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ConnectionStartBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ConnectionStartBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ConnectionStartBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 10; + public static final int METHOD_ID = 10; + + // Fields declared in specification + private final short _versionMajor; // [versionMajor] + private final short _versionMinor; // [versionMinor] + private final FieldTable _serverProperties; // [serverProperties] + private final byte[] _mechanisms; // [mechanisms] + private final byte[] _locales; // [locales] + + // Constructor + public ConnectionStartBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _versionMajor = readUnsignedByte( buffer ); + _versionMinor = readUnsignedByte( buffer ); + _serverProperties = readFieldTable( buffer ); + _mechanisms = readBytes( buffer ); + _locales = readBytes( buffer ); + } + + public ConnectionStartBody( + short versionMajor, + short versionMinor, + FieldTable serverProperties, + byte[] mechanisms, + byte[] locales + ) + { + _versionMajor = versionMajor; + _versionMinor = versionMinor; + _serverProperties = serverProperties; + _mechanisms = mechanisms; + _locales = locales; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final short getVersionMajor() + { + return _versionMajor; + } + public final short getVersionMinor() + { + return _versionMinor; + } + public final FieldTable getServerProperties() + { + return _serverProperties; + } + public final byte[] getMechanisms() + { + return _mechanisms; + } + public final byte[] getLocales() + { + return _locales; + } - public byte[] getLocales(); + protected int getBodySize() + { + int size = 2; + size += getSizeOf( _serverProperties ); + size += getSizeOf( _mechanisms ); + size += getSizeOf( _locales ); + return size; + } - public byte[] getMechanisms(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedByte( buffer, _versionMajor ); + writeUnsignedByte( buffer, _versionMinor ); + writeFieldTable( buffer, _serverProperties ); + writeBytes( buffer, _mechanisms ); + writeBytes( buffer, _locales ); + } - public FieldTable getServerProperties(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchConnectionStart(this, channelId); + } - public short getVersionMajor(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ConnectionStartBodyImpl: "); + buf.append( "versionMajor=" ); + buf.append( getVersionMajor() ); + buf.append( ", " ); + buf.append( "versionMinor=" ); + buf.append( getVersionMinor() ); + buf.append( ", " ); + buf.append( "serverProperties=" ); + buf.append( getServerProperties() ); + buf.append( ", " ); + buf.append( "mechanisms=" ); + buf.append( getMechanisms() == null ? "null" : java.util.Arrays.toString( getMechanisms() ) ); + buf.append( ", " ); + buf.append( "locales=" ); + buf.append( getLocales() == null ? "null" : java.util.Arrays.toString( getLocales() ) ); + buf.append("]"); + return buf.toString(); + } - public short getVersionMinor(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartBodyImpl.java deleted file mode 100644 index 12c1a55b56..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartBodyImpl.java +++ /dev/null @@ -1,161 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ConnectionStartBodyImpl extends AMQMethodBodyImpl implements ConnectionStartBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ConnectionStartBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 10; - public static final int METHOD_ID = 10; - - // Fields declared in specification - private final short _versionMajor; // [versionMajor] - private final short _versionMinor; // [versionMinor] - private final FieldTable _serverProperties; // [serverProperties] - private final byte[] _mechanisms; // [mechanisms] - private final byte[] _locales; // [locales] - - // Constructor - public ConnectionStartBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _versionMajor = readUnsignedByte( buffer ); - _versionMinor = readUnsignedByte( buffer ); - _serverProperties = readFieldTable( buffer ); - _mechanisms = readBytes( buffer ); - _locales = readBytes( buffer ); - } - - public ConnectionStartBodyImpl( - short versionMajor, - short versionMinor, - FieldTable serverProperties, - byte[] mechanisms, - byte[] locales - ) - { - _versionMajor = versionMajor; - _versionMinor = versionMinor; - _serverProperties = serverProperties; - _mechanisms = mechanisms; - _locales = locales; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final short getVersionMajor() - { - return _versionMajor; - } - public final short getVersionMinor() - { - return _versionMinor; - } - public final FieldTable getServerProperties() - { - return _serverProperties; - } - public final byte[] getMechanisms() - { - return _mechanisms; - } - public final byte[] getLocales() - { - return _locales; - } - - protected int getBodySize() - { - int size = 2; - size += getSizeOf( _serverProperties ); - size += getSizeOf( _mechanisms ); - size += getSizeOf( _locales ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedByte( buffer, _versionMajor ); - writeUnsignedByte( buffer, _versionMinor ); - writeFieldTable( buffer, _serverProperties ); - writeBytes( buffer, _mechanisms ); - writeBytes( buffer, _locales ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchConnectionStart(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ConnectionStartBodyImpl: "); - buf.append( "versionMajor=" ); - buf.append( getVersionMajor() ); - buf.append( ", " ); - buf.append( "versionMinor=" ); - buf.append( getVersionMinor() ); - buf.append( ", " ); - buf.append( "serverProperties=" ); - buf.append( getServerProperties() ); - buf.append( ", " ); - buf.append( "mechanisms=" ); - buf.append( getMechanisms() == null ? "null" : java.util.Arrays.toString( getMechanisms() ) ); - buf.append( ", " ); - buf.append( "locales=" ); - buf.append( getLocales() == null ? "null" : java.util.Arrays.toString( getLocales() ) ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartOkBody.java index bd45ce0fa0..f46fa4ed9f 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartOkBody.java @@ -22,21 +22,129 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ConnectionStartOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ConnectionStartOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ConnectionStartOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 10; + public static final int METHOD_ID = 11; + + // Fields declared in specification + private final FieldTable _clientProperties; // [clientProperties] + private final AMQShortString _mechanism; // [mechanism] + private final byte[] _response; // [response] + private final AMQShortString _locale; // [locale] + + // Constructor + public ConnectionStartOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _clientProperties = readFieldTable( buffer ); + _mechanism = readAMQShortString( buffer ); + _response = readBytes( buffer ); + _locale = readAMQShortString( buffer ); + } + + public ConnectionStartOkBody( + FieldTable clientProperties, + AMQShortString mechanism, + byte[] response, + AMQShortString locale + ) + { + _clientProperties = clientProperties; + _mechanism = mechanism; + _response = response; + _locale = locale; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final FieldTable getClientProperties() + { + return _clientProperties; + } + public final AMQShortString getMechanism() + { + return _mechanism; + } + public final byte[] getResponse() + { + return _response; + } + public final AMQShortString getLocale() + { + return _locale; + } + + protected int getBodySize() + { + int size = 0; + size += getSizeOf( _clientProperties ); + size += getSizeOf( _mechanism ); + size += getSizeOf( _response ); + size += getSizeOf( _locale ); + return size; + } - public FieldTable getClientProperties(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeFieldTable( buffer, _clientProperties ); + writeAMQShortString( buffer, _mechanism ); + writeBytes( buffer, _response ); + writeAMQShortString( buffer, _locale ); + } - public AMQShortString getLocale(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchConnectionStartOk(this, channelId); + } - public AMQShortString getMechanism(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ConnectionStartOkBodyImpl: "); + buf.append( "clientProperties=" ); + buf.append( getClientProperties() ); + buf.append( ", " ); + buf.append( "mechanism=" ); + buf.append( getMechanism() ); + buf.append( ", " ); + buf.append( "response=" ); + buf.append( getResponse() == null ? "null" : java.util.Arrays.toString( getResponse() ) ); + buf.append( ", " ); + buf.append( "locale=" ); + buf.append( getLocale() ); + buf.append("]"); + return buf.toString(); + } - public byte[] getResponse(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartOkBodyImpl.java deleted file mode 100644 index f197f651ba..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionStartOkBodyImpl.java +++ /dev/null @@ -1,150 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ConnectionStartOkBodyImpl extends AMQMethodBodyImpl implements ConnectionStartOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ConnectionStartOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 10; - public static final int METHOD_ID = 11; - - // Fields declared in specification - private final FieldTable _clientProperties; // [clientProperties] - private final AMQShortString _mechanism; // [mechanism] - private final byte[] _response; // [response] - private final AMQShortString _locale; // [locale] - - // Constructor - public ConnectionStartOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _clientProperties = readFieldTable( buffer ); - _mechanism = readAMQShortString( buffer ); - _response = readBytes( buffer ); - _locale = readAMQShortString( buffer ); - } - - public ConnectionStartOkBodyImpl( - FieldTable clientProperties, - AMQShortString mechanism, - byte[] response, - AMQShortString locale - ) - { - _clientProperties = clientProperties; - _mechanism = mechanism; - _response = response; - _locale = locale; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final FieldTable getClientProperties() - { - return _clientProperties; - } - public final AMQShortString getMechanism() - { - return _mechanism; - } - public final byte[] getResponse() - { - return _response; - } - public final AMQShortString getLocale() - { - return _locale; - } - - protected int getBodySize() - { - int size = 0; - size += getSizeOf( _clientProperties ); - size += getSizeOf( _mechanism ); - size += getSizeOf( _response ); - size += getSizeOf( _locale ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeFieldTable( buffer, _clientProperties ); - writeAMQShortString( buffer, _mechanism ); - writeBytes( buffer, _response ); - writeAMQShortString( buffer, _locale ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchConnectionStartOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ConnectionStartOkBodyImpl: "); - buf.append( "clientProperties=" ); - buf.append( getClientProperties() ); - buf.append( ", " ); - buf.append( "mechanism=" ); - buf.append( getMechanism() ); - buf.append( ", " ); - buf.append( "response=" ); - buf.append( getResponse() == null ? "null" : java.util.Arrays.toString( getResponse() ) ); - buf.append( ", " ); - buf.append( "locale=" ); - buf.append( getLocale() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneBody.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneBody.java index 82a1b2f04b..cc5618db27 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneBody.java @@ -22,19 +22,113 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ConnectionTuneBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ConnectionTuneBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ConnectionTuneBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 10; + public static final int METHOD_ID = 30; + + // Fields declared in specification + private final int _channelMax; // [channelMax] + private final long _frameMax; // [frameMax] + private final int _heartbeat; // [heartbeat] + + // Constructor + public ConnectionTuneBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _channelMax = readUnsignedShort( buffer ); + _frameMax = readUnsignedInteger( buffer ); + _heartbeat = readUnsignedShort( buffer ); + } + + public ConnectionTuneBody( + int channelMax, + long frameMax, + int heartbeat + ) + { + _channelMax = channelMax; + _frameMax = frameMax; + _heartbeat = heartbeat; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getChannelMax() + { + return _channelMax; + } + public final long getFrameMax() + { + return _frameMax; + } + public final int getHeartbeat() + { + return _heartbeat; + } + + protected int getBodySize() + { + int size = 8; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _channelMax ); + writeUnsignedInteger( buffer, _frameMax ); + writeUnsignedShort( buffer, _heartbeat ); + } - public int getChannelMax(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchConnectionTune(this, channelId); + } - public long getFrameMax(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ConnectionTuneBodyImpl: "); + buf.append( "channelMax=" ); + buf.append( getChannelMax() ); + buf.append( ", " ); + buf.append( "frameMax=" ); + buf.append( getFrameMax() ); + buf.append( ", " ); + buf.append( "heartbeat=" ); + buf.append( getHeartbeat() ); + buf.append("]"); + return buf.toString(); + } - public int getHeartbeat(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneBodyImpl.java deleted file mode 100644 index 0c35ad839a..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneBodyImpl.java +++ /dev/null @@ -1,134 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ConnectionTuneBodyImpl extends AMQMethodBodyImpl implements ConnectionTuneBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ConnectionTuneBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 10; - public static final int METHOD_ID = 30; - - // Fields declared in specification - private final int _channelMax; // [channelMax] - private final long _frameMax; // [frameMax] - private final int _heartbeat; // [heartbeat] - - // Constructor - public ConnectionTuneBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _channelMax = readUnsignedShort( buffer ); - _frameMax = readUnsignedInteger( buffer ); - _heartbeat = readUnsignedShort( buffer ); - } - - public ConnectionTuneBodyImpl( - int channelMax, - long frameMax, - int heartbeat - ) - { - _channelMax = channelMax; - _frameMax = frameMax; - _heartbeat = heartbeat; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getChannelMax() - { - return _channelMax; - } - public final long getFrameMax() - { - return _frameMax; - } - public final int getHeartbeat() - { - return _heartbeat; - } - - protected int getBodySize() - { - int size = 8; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _channelMax ); - writeUnsignedInteger( buffer, _frameMax ); - writeUnsignedShort( buffer, _heartbeat ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchConnectionTune(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ConnectionTuneBodyImpl: "); - buf.append( "channelMax=" ); - buf.append( getChannelMax() ); - buf.append( ", " ); - buf.append( "frameMax=" ); - buf.append( getFrameMax() ); - buf.append( ", " ); - buf.append( "heartbeat=" ); - buf.append( getHeartbeat() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneOkBody.java index 15cdd44c08..a2ea80b13c 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneOkBody.java @@ -22,19 +22,113 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ConnectionTuneOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ConnectionTuneOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ConnectionTuneOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 10; + public static final int METHOD_ID = 31; + + // Fields declared in specification + private final int _channelMax; // [channelMax] + private final long _frameMax; // [frameMax] + private final int _heartbeat; // [heartbeat] + + // Constructor + public ConnectionTuneOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _channelMax = readUnsignedShort( buffer ); + _frameMax = readUnsignedInteger( buffer ); + _heartbeat = readUnsignedShort( buffer ); + } + + public ConnectionTuneOkBody( + int channelMax, + long frameMax, + int heartbeat + ) + { + _channelMax = channelMax; + _frameMax = frameMax; + _heartbeat = heartbeat; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getChannelMax() + { + return _channelMax; + } + public final long getFrameMax() + { + return _frameMax; + } + public final int getHeartbeat() + { + return _heartbeat; + } + + protected int getBodySize() + { + int size = 8; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _channelMax ); + writeUnsignedInteger( buffer, _frameMax ); + writeUnsignedShort( buffer, _heartbeat ); + } - public int getChannelMax(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchConnectionTuneOk(this, channelId); + } - public long getFrameMax(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ConnectionTuneOkBodyImpl: "); + buf.append( "channelMax=" ); + buf.append( getChannelMax() ); + buf.append( ", " ); + buf.append( "frameMax=" ); + buf.append( getFrameMax() ); + buf.append( ", " ); + buf.append( "heartbeat=" ); + buf.append( getHeartbeat() ); + buf.append("]"); + return buf.toString(); + } - public int getHeartbeat(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneOkBodyImpl.java deleted file mode 100644 index 529b5eecc8..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ConnectionTuneOkBodyImpl.java +++ /dev/null @@ -1,134 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ConnectionTuneOkBodyImpl extends AMQMethodBodyImpl implements ConnectionTuneOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ConnectionTuneOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 10; - public static final int METHOD_ID = 31; - - // Fields declared in specification - private final int _channelMax; // [channelMax] - private final long _frameMax; // [frameMax] - private final int _heartbeat; // [heartbeat] - - // Constructor - public ConnectionTuneOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _channelMax = readUnsignedShort( buffer ); - _frameMax = readUnsignedInteger( buffer ); - _heartbeat = readUnsignedShort( buffer ); - } - - public ConnectionTuneOkBodyImpl( - int channelMax, - long frameMax, - int heartbeat - ) - { - _channelMax = channelMax; - _frameMax = frameMax; - _heartbeat = heartbeat; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getChannelMax() - { - return _channelMax; - } - public final long getFrameMax() - { - return _frameMax; - } - public final int getHeartbeat() - { - return _heartbeat; - } - - protected int getBodySize() - { - int size = 8; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _channelMax ); - writeUnsignedInteger( buffer, _frameMax ); - writeUnsignedShort( buffer, _heartbeat ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchConnectionTuneOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ConnectionTuneOkBodyImpl: "); - buf.append( "channelMax=" ); - buf.append( getChannelMax() ); - buf.append( ", " ); - buf.append( "frameMax=" ); - buf.append( getFrameMax() ); - buf.append( ", " ); - buf.append( "heartbeat=" ); - buf.append( getHeartbeat() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ContentHeaderPropertiesFactory.java b/java/common/src/main/java/org/apache/qpid/framing/ContentHeaderPropertiesFactory.java index 4e2f5ebceb..e8eb471284 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ContentHeaderPropertiesFactory.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ContentHeaderPropertiesFactory.java @@ -44,7 +44,7 @@ public class ContentHeaderPropertiesFactory // AMQP version change: "Hardwired" version to major=8, minor=0 // TODO: Change so that the actual version is obtained from // the ProtocolInitiation object for this session. - if (classId == BasicConsumeBodyImpl.CLASS_ID) + if (classId == BasicConsumeBody.CLASS_ID) { properties = new BasicContentHeaderProperties(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundBody.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundBody.java index fa1fb441a8..7f94da70a0 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundBody.java @@ -22,19 +22,116 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ExchangeBoundBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ExchangeBoundBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ExchangeBoundBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 40; + public static final int METHOD_ID = 22; + + // Fields declared in specification + private final AMQShortString _exchange; // [exchange] + private final AMQShortString _routingKey; // [routingKey] + private final AMQShortString _queue; // [queue] + + // Constructor + public ExchangeBoundBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _exchange = readAMQShortString( buffer ); + _routingKey = readAMQShortString( buffer ); + _queue = readAMQShortString( buffer ); + } + + public ExchangeBoundBody( + AMQShortString exchange, + AMQShortString routingKey, + AMQShortString queue + ) + { + _exchange = exchange; + _routingKey = routingKey; + _queue = queue; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getExchange() + { + return _exchange; + } + public final AMQShortString getRoutingKey() + { + return _routingKey; + } + public final AMQShortString getQueue() + { + return _queue; + } + + protected int getBodySize() + { + int size = 0; + size += getSizeOf( _exchange ); + size += getSizeOf( _routingKey ); + size += getSizeOf( _queue ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _exchange ); + writeAMQShortString( buffer, _routingKey ); + writeAMQShortString( buffer, _queue ); + } - public AMQShortString getExchange(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchExchangeBound(this, channelId); + } - public AMQShortString getQueue(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ExchangeBoundBodyImpl: "); + buf.append( "exchange=" ); + buf.append( getExchange() ); + buf.append( ", " ); + buf.append( "routingKey=" ); + buf.append( getRoutingKey() ); + buf.append( ", " ); + buf.append( "queue=" ); + buf.append( getQueue() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getRoutingKey(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundBodyImpl.java deleted file mode 100644 index ccc0bec072..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundBodyImpl.java +++ /dev/null @@ -1,137 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ExchangeBoundBodyImpl extends AMQMethodBodyImpl implements ExchangeBoundBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ExchangeBoundBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 40; - public static final int METHOD_ID = 22; - - // Fields declared in specification - private final AMQShortString _exchange; // [exchange] - private final AMQShortString _routingKey; // [routingKey] - private final AMQShortString _queue; // [queue] - - // Constructor - public ExchangeBoundBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _exchange = readAMQShortString( buffer ); - _routingKey = readAMQShortString( buffer ); - _queue = readAMQShortString( buffer ); - } - - public ExchangeBoundBodyImpl( - AMQShortString exchange, - AMQShortString routingKey, - AMQShortString queue - ) - { - _exchange = exchange; - _routingKey = routingKey; - _queue = queue; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getExchange() - { - return _exchange; - } - public final AMQShortString getRoutingKey() - { - return _routingKey; - } - public final AMQShortString getQueue() - { - return _queue; - } - - protected int getBodySize() - { - int size = 0; - size += getSizeOf( _exchange ); - size += getSizeOf( _routingKey ); - size += getSizeOf( _queue ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _exchange ); - writeAMQShortString( buffer, _routingKey ); - writeAMQShortString( buffer, _queue ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchExchangeBound(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ExchangeBoundBodyImpl: "); - buf.append( "exchange=" ); - buf.append( getExchange() ); - buf.append( ", " ); - buf.append( "routingKey=" ); - buf.append( getRoutingKey() ); - buf.append( ", " ); - buf.append( "queue=" ); - buf.append( getQueue() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundOkBody.java index 7a60e4dc21..9f546cf413 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundOkBody.java @@ -22,17 +22,102 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ExchangeBoundOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ExchangeBoundOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ExchangeBoundOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 40; + public static final int METHOD_ID = 23; + + // Fields declared in specification + private final int _replyCode; // [replyCode] + private final AMQShortString _replyText; // [replyText] + + // Constructor + public ExchangeBoundOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _replyCode = readUnsignedShort( buffer ); + _replyText = readAMQShortString( buffer ); + } + + public ExchangeBoundOkBody( + int replyCode, + AMQShortString replyText + ) + { + _replyCode = replyCode; + _replyText = replyText; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getReplyCode() + { + return _replyCode; + } + public final AMQShortString getReplyText() + { + return _replyText; + } + + protected int getBodySize() + { + int size = 2; + size += getSizeOf( _replyText ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _replyCode ); + writeAMQShortString( buffer, _replyText ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchExchangeBoundOk(this, channelId); + } - public int getReplyCode(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ExchangeBoundOkBodyImpl: "); + buf.append( "replyCode=" ); + buf.append( getReplyCode() ); + buf.append( ", " ); + buf.append( "replyText=" ); + buf.append( getReplyText() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getReplyText(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundOkBodyImpl.java deleted file mode 100644 index 24348ebcd2..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeBoundOkBodyImpl.java +++ /dev/null @@ -1,123 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ExchangeBoundOkBodyImpl extends AMQMethodBodyImpl implements ExchangeBoundOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ExchangeBoundOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 40; - public static final int METHOD_ID = 23; - - // Fields declared in specification - private final int _replyCode; // [replyCode] - private final AMQShortString _replyText; // [replyText] - - // Constructor - public ExchangeBoundOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _replyCode = readUnsignedShort( buffer ); - _replyText = readAMQShortString( buffer ); - } - - public ExchangeBoundOkBodyImpl( - int replyCode, - AMQShortString replyText - ) - { - _replyCode = replyCode; - _replyText = replyText; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getReplyCode() - { - return _replyCode; - } - public final AMQShortString getReplyText() - { - return _replyText; - } - - protected int getBodySize() - { - int size = 2; - size += getSizeOf( _replyText ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _replyCode ); - writeAMQShortString( buffer, _replyText ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchExchangeBoundOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ExchangeBoundOkBodyImpl: "); - buf.append( "replyCode=" ); - buf.append( getReplyCode() ); - buf.append( ", " ); - buf.append( "replyText=" ); - buf.append( getReplyText() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareBody.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareBody.java index 8ffb998e47..b6efaf1cfa 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareBody.java @@ -22,31 +22,198 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ExchangeDeclareBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ExchangeDeclareBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ExchangeDeclareBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 40; + public static final int METHOD_ID = 10; + + // Fields declared in specification + private final int _ticket; // [ticket] + private final AMQShortString _exchange; // [exchange] + private final AMQShortString _type; // [type] + private final byte _bitfield0; // [passive, durable, autoDelete, internal, nowait] + private final FieldTable _arguments; // [arguments] + + // Constructor + public ExchangeDeclareBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _ticket = readUnsignedShort( buffer ); + _exchange = readAMQShortString( buffer ); + _type = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + _arguments = readFieldTable( buffer ); + } + + public ExchangeDeclareBody( + int ticket, + AMQShortString exchange, + AMQShortString type, + boolean passive, + boolean durable, + boolean autoDelete, + boolean internal, + boolean nowait, + FieldTable arguments + ) + { + _ticket = ticket; + _exchange = exchange; + _type = type; + byte bitfield0 = (byte)0; + if( passive ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + + if( durable ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); + } + + if( autoDelete ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 2)); + } + + if( internal ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 3)); + } + + if( nowait ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 4)); + } - public FieldTable getArguments(); + _bitfield0 = bitfield0; + _arguments = arguments; + } - public boolean getAutoDelete(); + public int getClazz() + { + return CLASS_ID; + } - public boolean getDurable(); + public int getMethod() + { + return METHOD_ID; + } - public AMQShortString getExchange(); + public final int getTicket() + { + return _ticket; + } + public final AMQShortString getExchange() + { + return _exchange; + } + public final AMQShortString getType() + { + return _type; + } + public final boolean getPassive() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + public final boolean getDurable() + { + return (((int)(_bitfield0)) & ( 1 << 1)) != 0; + } + public final boolean getAutoDelete() + { + return (((int)(_bitfield0)) & ( 1 << 2)) != 0; + } + public final boolean getInternal() + { + return (((int)(_bitfield0)) & ( 1 << 3)) != 0; + } + public final boolean getNowait() + { + return (((int)(_bitfield0)) & ( 1 << 4)) != 0; + } + public final FieldTable getArguments() + { + return _arguments; + } - public boolean getInternal(); + protected int getBodySize() + { + int size = 3; + size += getSizeOf( _exchange ); + size += getSizeOf( _type ); + size += getSizeOf( _arguments ); + return size; + } - public boolean getNowait(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _ticket ); + writeAMQShortString( buffer, _exchange ); + writeAMQShortString( buffer, _type ); + writeBitfield( buffer, _bitfield0 ); + writeFieldTable( buffer, _arguments ); + } - public boolean getPassive(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchExchangeDeclare(this, channelId); + } - public int getTicket(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ExchangeDeclareBodyImpl: "); + buf.append( "ticket=" ); + buf.append( getTicket() ); + buf.append( ", " ); + buf.append( "exchange=" ); + buf.append( getExchange() ); + buf.append( ", " ); + buf.append( "type=" ); + buf.append( getType() ); + buf.append( ", " ); + buf.append( "passive=" ); + buf.append( getPassive() ); + buf.append( ", " ); + buf.append( "durable=" ); + buf.append( getDurable() ); + buf.append( ", " ); + buf.append( "autoDelete=" ); + buf.append( getAutoDelete() ); + buf.append( ", " ); + buf.append( "internal=" ); + buf.append( getInternal() ); + buf.append( ", " ); + buf.append( "nowait=" ); + buf.append( getNowait() ); + buf.append( ", " ); + buf.append( "arguments=" ); + buf.append( getArguments() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getType(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareBodyImpl.java deleted file mode 100644 index cf46e4ae0c..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareBodyImpl.java +++ /dev/null @@ -1,219 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ExchangeDeclareBodyImpl extends AMQMethodBodyImpl implements ExchangeDeclareBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ExchangeDeclareBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 40; - public static final int METHOD_ID = 10; - - // Fields declared in specification - private final int _ticket; // [ticket] - private final AMQShortString _exchange; // [exchange] - private final AMQShortString _type; // [type] - private final byte _bitfield0; // [passive, durable, autoDelete, internal, nowait] - private final FieldTable _arguments; // [arguments] - - // Constructor - public ExchangeDeclareBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _ticket = readUnsignedShort( buffer ); - _exchange = readAMQShortString( buffer ); - _type = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - _arguments = readFieldTable( buffer ); - } - - public ExchangeDeclareBodyImpl( - int ticket, - AMQShortString exchange, - AMQShortString type, - boolean passive, - boolean durable, - boolean autoDelete, - boolean internal, - boolean nowait, - FieldTable arguments - ) - { - _ticket = ticket; - _exchange = exchange; - _type = type; - byte bitfield0 = (byte)0; - if( passive ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - - if( durable ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); - } - - if( autoDelete ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 2)); - } - - if( internal ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 3)); - } - - if( nowait ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 4)); - } - - _bitfield0 = bitfield0; - _arguments = arguments; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getTicket() - { - return _ticket; - } - public final AMQShortString getExchange() - { - return _exchange; - } - public final AMQShortString getType() - { - return _type; - } - public final boolean getPassive() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - public final boolean getDurable() - { - return (((int)(_bitfield0)) & ( 1 << 1)) != 0; - } - public final boolean getAutoDelete() - { - return (((int)(_bitfield0)) & ( 1 << 2)) != 0; - } - public final boolean getInternal() - { - return (((int)(_bitfield0)) & ( 1 << 3)) != 0; - } - public final boolean getNowait() - { - return (((int)(_bitfield0)) & ( 1 << 4)) != 0; - } - public final FieldTable getArguments() - { - return _arguments; - } - - protected int getBodySize() - { - int size = 3; - size += getSizeOf( _exchange ); - size += getSizeOf( _type ); - size += getSizeOf( _arguments ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _ticket ); - writeAMQShortString( buffer, _exchange ); - writeAMQShortString( buffer, _type ); - writeBitfield( buffer, _bitfield0 ); - writeFieldTable( buffer, _arguments ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchExchangeDeclare(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ExchangeDeclareBodyImpl: "); - buf.append( "ticket=" ); - buf.append( getTicket() ); - buf.append( ", " ); - buf.append( "exchange=" ); - buf.append( getExchange() ); - buf.append( ", " ); - buf.append( "type=" ); - buf.append( getType() ); - buf.append( ", " ); - buf.append( "passive=" ); - buf.append( getPassive() ); - buf.append( ", " ); - buf.append( "durable=" ); - buf.append( getDurable() ); - buf.append( ", " ); - buf.append( "autoDelete=" ); - buf.append( getAutoDelete() ); - buf.append( ", " ); - buf.append( "internal=" ); - buf.append( getInternal() ); - buf.append( ", " ); - buf.append( "nowait=" ); - buf.append( getNowait() ); - buf.append( ", " ); - buf.append( "arguments=" ); - buf.append( getArguments() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareOkBody.java index 848963ce1b..c0d2e557fd 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareOkBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ExchangeDeclareOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ExchangeDeclareOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ExchangeDeclareOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 40; + public static final int METHOD_ID = 11; + + // Fields declared in specification + + // Constructor + public ExchangeDeclareOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public ExchangeDeclareOkBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchExchangeDeclareOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[ExchangeDeclareOkBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareOkBodyImpl.java deleted file mode 100644 index ca30257192..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeclareOkBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ExchangeDeclareOkBodyImpl extends AMQMethodBodyImpl implements ExchangeDeclareOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ExchangeDeclareOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 40; - public static final int METHOD_ID = 11; - - // Fields declared in specification - - // Constructor - public ExchangeDeclareOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public ExchangeDeclareOkBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchExchangeDeclareOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ExchangeDeclareOkBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteBody.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteBody.java index 5ce3a7415f..b99c85b023 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteBody.java @@ -22,21 +22,132 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ExchangeDeleteBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ExchangeDeleteBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ExchangeDeleteBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 40; + public static final int METHOD_ID = 20; + + // Fields declared in specification + private final int _ticket; // [ticket] + private final AMQShortString _exchange; // [exchange] + private final byte _bitfield0; // [ifUnused, nowait] + + // Constructor + public ExchangeDeleteBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _ticket = readUnsignedShort( buffer ); + _exchange = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public ExchangeDeleteBody( + int ticket, + AMQShortString exchange, + boolean ifUnused, + boolean nowait + ) + { + _ticket = ticket; + _exchange = exchange; + byte bitfield0 = (byte)0; + if( ifUnused ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + + if( nowait ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getTicket() + { + return _ticket; + } + public final AMQShortString getExchange() + { + return _exchange; + } + public final boolean getIfUnused() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + public final boolean getNowait() + { + return (((int)(_bitfield0)) & ( 1 << 1)) != 0; + } + + protected int getBodySize() + { + int size = 3; + size += getSizeOf( _exchange ); + return size; + } - public AMQShortString getExchange(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _ticket ); + writeAMQShortString( buffer, _exchange ); + writeBitfield( buffer, _bitfield0 ); + } - public boolean getIfUnused(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchExchangeDelete(this, channelId); + } - public boolean getNowait(); + public String toString() + { + StringBuilder buf = new StringBuilder("[ExchangeDeleteBodyImpl: "); + buf.append( "ticket=" ); + buf.append( getTicket() ); + buf.append( ", " ); + buf.append( "exchange=" ); + buf.append( getExchange() ); + buf.append( ", " ); + buf.append( "ifUnused=" ); + buf.append( getIfUnused() ); + buf.append( ", " ); + buf.append( "nowait=" ); + buf.append( getNowait() ); + buf.append("]"); + return buf.toString(); + } - public int getTicket(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteBodyImpl.java deleted file mode 100644 index 9d7a60a6e4..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteBodyImpl.java +++ /dev/null @@ -1,153 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ExchangeDeleteBodyImpl extends AMQMethodBodyImpl implements ExchangeDeleteBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ExchangeDeleteBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 40; - public static final int METHOD_ID = 20; - - // Fields declared in specification - private final int _ticket; // [ticket] - private final AMQShortString _exchange; // [exchange] - private final byte _bitfield0; // [ifUnused, nowait] - - // Constructor - public ExchangeDeleteBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _ticket = readUnsignedShort( buffer ); - _exchange = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public ExchangeDeleteBodyImpl( - int ticket, - AMQShortString exchange, - boolean ifUnused, - boolean nowait - ) - { - _ticket = ticket; - _exchange = exchange; - byte bitfield0 = (byte)0; - if( ifUnused ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - - if( nowait ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getTicket() - { - return _ticket; - } - public final AMQShortString getExchange() - { - return _exchange; - } - public final boolean getIfUnused() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - public final boolean getNowait() - { - return (((int)(_bitfield0)) & ( 1 << 1)) != 0; - } - - protected int getBodySize() - { - int size = 3; - size += getSizeOf( _exchange ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _ticket ); - writeAMQShortString( buffer, _exchange ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchExchangeDelete(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ExchangeDeleteBodyImpl: "); - buf.append( "ticket=" ); - buf.append( getTicket() ); - buf.append( ", " ); - buf.append( "exchange=" ); - buf.append( getExchange() ); - buf.append( ", " ); - buf.append( "ifUnused=" ); - buf.append( getIfUnused() ); - buf.append( ", " ); - buf.append( "nowait=" ); - buf.append( getNowait() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteOkBody.java index 54ce0940d5..6ef35352af 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteOkBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface ExchangeDeleteOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class ExchangeDeleteOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new ExchangeDeleteOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 40; + public static final int METHOD_ID = 21; + + // Fields declared in specification + + // Constructor + public ExchangeDeleteOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public ExchangeDeleteOkBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchExchangeDeleteOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[ExchangeDeleteOkBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteOkBodyImpl.java deleted file mode 100644 index 7c78a9e384..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/ExchangeDeleteOkBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class ExchangeDeleteOkBodyImpl extends AMQMethodBodyImpl implements ExchangeDeleteOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new ExchangeDeleteOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 40; - public static final int METHOD_ID = 21; - - // Fields declared in specification - - // Constructor - public ExchangeDeleteOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public ExchangeDeleteOkBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchExchangeDeleteOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[ExchangeDeleteOkBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/MethodRegistry.java b/java/common/src/main/java/org/apache/qpid/framing/MethodRegistry.java index 84274ba3a6..e027705af7 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/MethodRegistry.java +++ b/java/common/src/main/java/org/apache/qpid/framing/MethodRegistry.java @@ -74,115 +74,115 @@ public abstract class MethodRegistry public abstract BasicAckBody createBasicAckBody( - final long deliveryTag, - final boolean multiple - ); + final long deliveryTag, + final boolean multiple + ); public abstract BasicCancelBody createBasicCancelBody( - final AMQShortString consumerTag, - final boolean nowait - ); + final AMQShortString consumerTag, + final boolean nowait + ); public abstract BasicCancelOkBody createBasicCancelOkBody( - final AMQShortString consumerTag - ); + final AMQShortString consumerTag + ); public abstract BasicConsumeBody createBasicConsumeBody( - final int ticket, - final AMQShortString queue, - final AMQShortString consumerTag, - final boolean noLocal, - final boolean noAck, - final boolean exclusive, - final boolean nowait, - final FieldTable arguments - ); + final int ticket, + final AMQShortString queue, + final AMQShortString consumerTag, + final boolean noLocal, + final boolean noAck, + final boolean exclusive, + final boolean nowait, + final FieldTable arguments + ); public abstract BasicConsumeOkBody createBasicConsumeOkBody( - final AMQShortString consumerTag - ); + final AMQShortString consumerTag + ); public abstract BasicDeliverBody createBasicDeliverBody( - final AMQShortString consumerTag, - final long deliveryTag, - final boolean redelivered, - final AMQShortString exchange, - final AMQShortString routingKey - ); + final AMQShortString consumerTag, + final long deliveryTag, + final boolean redelivered, + final AMQShortString exchange, + final AMQShortString routingKey + ); public abstract BasicGetBody createBasicGetBody( - final int ticket, - final AMQShortString queue, - final boolean noAck - ); + final int ticket, + final AMQShortString queue, + final boolean noAck + ); public abstract BasicGetEmptyBody createBasicGetEmptyBody( - final AMQShortString clusterId - ); + final AMQShortString clusterId + ); public abstract BasicGetOkBody createBasicGetOkBody( - final long deliveryTag, - final boolean redelivered, - final AMQShortString exchange, - final AMQShortString routingKey, - final long messageCount - ); + final long deliveryTag, + final boolean redelivered, + final AMQShortString exchange, + final AMQShortString routingKey, + final long messageCount + ); public abstract BasicPublishBody createBasicPublishBody( - final int ticket, - final AMQShortString exchange, - final AMQShortString routingKey, - final boolean mandatory, - final boolean immediate - ); + final int ticket, + final AMQShortString exchange, + final AMQShortString routingKey, + final boolean mandatory, + final boolean immediate + ); public abstract BasicQosBody createBasicQosBody( - final long prefetchSize, - final int prefetchCount, - final boolean global - ); + final long prefetchSize, + final int prefetchCount, + final boolean global + ); public abstract BasicQosOkBody createBasicQosOkBody( - ); + ); public abstract BasicRecoverBody createBasicRecoverBody( - final boolean requeue - ); + final boolean requeue + ); public abstract BasicRejectBody createBasicRejectBody( - final long deliveryTag, - final boolean requeue - ); + final long deliveryTag, + final boolean requeue + ); public abstract BasicReturnBody createBasicReturnBody( - final int replyCode, - final AMQShortString replyText, - final AMQShortString exchange, - final AMQShortString routingKey - ); + final int replyCode, + final AMQShortString replyText, + final AMQShortString exchange, + final AMQShortString routingKey + ); public abstract ChannelCloseBody createChannelCloseBody( - final int replyCode, - final AMQShortString replyText, - final int classId, - final int methodId - ); + final int replyCode, + final AMQShortString replyText, + final int classId, + final int methodId + ); public abstract ChannelCloseOkBody createChannelCloseOkBody( - ); + ); public abstract ChannelFlowBody createChannelFlowBody( - final boolean active - ); + final boolean active + ); public abstract ChannelFlowOkBody createChannelFlowOkBody( - final boolean active - ); + final boolean active + ); public abstract ChannelOpenBody createChannelOpenBody( - final AMQShortString outOfBand - ); + final AMQShortString outOfBand + ); public abstract ConnectionCloseBody createConnectionCloseBody( @@ -196,163 +196,163 @@ public abstract class MethodRegistry ); public abstract ConnectionOpenBody createConnectionOpenBody( - final AMQShortString virtualHost, - final AMQShortString capabilities, - final boolean insist - ); + final AMQShortString virtualHost, + final AMQShortString capabilities, + final boolean insist + ); public abstract ConnectionOpenOkBody createConnectionOpenOkBody( - final AMQShortString knownHosts - ); + final AMQShortString knownHosts + ); public abstract ConnectionSecureBody createConnectionSecureBody( - final byte[] challenge - ); + final byte[] challenge + ); public abstract ConnectionSecureOkBody createConnectionSecureOkBody( - final byte[] response - ); + final byte[] response + ); public abstract ConnectionStartBody createConnectionStartBody( - final short versionMajor, - final short versionMinor, - final FieldTable serverProperties, - final byte[] mechanisms, - final byte[] locales - ); + final short versionMajor, + final short versionMinor, + final FieldTable serverProperties, + final byte[] mechanisms, + final byte[] locales + ); public abstract ConnectionStartOkBody createConnectionStartOkBody( - final FieldTable clientProperties, - final AMQShortString mechanism, - final byte[] response, - final AMQShortString locale - ); + final FieldTable clientProperties, + final AMQShortString mechanism, + final byte[] response, + final AMQShortString locale + ); public abstract ConnectionTuneBody createConnectionTuneBody( - final int channelMax, - final long frameMax, - final int heartbeat - ); + final int channelMax, + final long frameMax, + final int heartbeat + ); public abstract ConnectionTuneOkBody createConnectionTuneOkBody( - final int channelMax, - final long frameMax, - final int heartbeat - ); + final int channelMax, + final long frameMax, + final int heartbeat + ); public abstract ExchangeBoundBody createExchangeBoundBody( - final AMQShortString exchange, - final AMQShortString routingKey, - final AMQShortString queue - ); + final AMQShortString exchange, + final AMQShortString routingKey, + final AMQShortString queue + ); public abstract ExchangeBoundOkBody createExchangeBoundOkBody( - final int replyCode, - final AMQShortString replyText - ); + final int replyCode, + final AMQShortString replyText + ); public abstract ExchangeDeclareBody createExchangeDeclareBody( - final int ticket, - final AMQShortString exchange, - final AMQShortString type, - final boolean passive, - final boolean durable, - final boolean autoDelete, - final boolean internal, - final boolean nowait, - final FieldTable arguments - ); + final int ticket, + final AMQShortString exchange, + final AMQShortString type, + final boolean passive, + final boolean durable, + final boolean autoDelete, + final boolean internal, + final boolean nowait, + final FieldTable arguments + ); public abstract ExchangeDeclareOkBody createExchangeDeclareOkBody( - ); + ); public abstract ExchangeDeleteBody createExchangeDeleteBody( - final int ticket, - final AMQShortString exchange, - final boolean ifUnused, - final boolean nowait - ); + final int ticket, + final AMQShortString exchange, + final boolean ifUnused, + final boolean nowait + ); public abstract ExchangeDeleteOkBody createExchangeDeleteOkBody( - ); + ); public abstract QueueBindBody createQueueBindBody( - final int ticket, - final AMQShortString queue, - final AMQShortString exchange, - final AMQShortString routingKey, - final boolean nowait, - final FieldTable arguments - ); + final int ticket, + final AMQShortString queue, + final AMQShortString exchange, + final AMQShortString routingKey, + final boolean nowait, + final FieldTable arguments + ); public abstract QueueBindOkBody createQueueBindOkBody( - ); + ); public abstract QueueDeclareBody createQueueDeclareBody( - final int ticket, - final AMQShortString queue, - final boolean passive, - final boolean durable, - final boolean exclusive, - final boolean autoDelete, - final boolean nowait, - final FieldTable arguments - ); + final int ticket, + final AMQShortString queue, + final boolean passive, + final boolean durable, + final boolean exclusive, + final boolean autoDelete, + final boolean nowait, + final FieldTable arguments + ); public abstract QueueDeclareOkBody createQueueDeclareOkBody( - final AMQShortString queue, - final long messageCount, - final long consumerCount - ); + final AMQShortString queue, + final long messageCount, + final long consumerCount + ); public abstract QueueDeleteBody createQueueDeleteBody( - final int ticket, - final AMQShortString queue, - final boolean ifUnused, - final boolean ifEmpty, - final boolean nowait - ); + final int ticket, + final AMQShortString queue, + final boolean ifUnused, + final boolean ifEmpty, + final boolean nowait + ); public abstract QueueDeleteOkBody createQueueDeleteOkBody( - final long messageCount - ); + final long messageCount + ); public abstract QueuePurgeBody createQueuePurgeBody( - final int ticket, - final AMQShortString queue, - final boolean nowait - ); + final int ticket, + final AMQShortString queue, + final boolean nowait + ); public abstract QueuePurgeOkBody createQueuePurgeOkBody( - final long messageCount - ); + final long messageCount + ); public abstract TxCommitBody createTxCommitBody( - ); + ); public abstract TxCommitOkBody createTxCommitOkBody( - ); + ); public abstract TxRollbackBody createTxRollbackBody( - ); + ); public abstract TxRollbackOkBody createTxRollbackOkBody( - ); + ); public abstract TxSelectBody createTxSelectBody( - ); + ); public abstract TxSelectOkBody createTxSelectOkBody( - ); + ); public abstract ProtocolVersionMethodConverter getProtocolVersionMethodConverter(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueBindBody.java b/java/common/src/main/java/org/apache/qpid/framing/QueueBindBody.java index d5f3b2b924..35ff7faeb2 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueBindBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/QueueBindBody.java @@ -22,25 +22,159 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface QueueBindBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class QueueBindBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new QueueBindBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 50; + public static final int METHOD_ID = 20; + + // Fields declared in specification + private final int _ticket; // [ticket] + private final AMQShortString _queue; // [queue] + private final AMQShortString _exchange; // [exchange] + private final AMQShortString _routingKey; // [routingKey] + private final byte _bitfield0; // [nowait] + private final FieldTable _arguments; // [arguments] + + // Constructor + public QueueBindBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _ticket = readUnsignedShort( buffer ); + _queue = readAMQShortString( buffer ); + _exchange = readAMQShortString( buffer ); + _routingKey = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + _arguments = readFieldTable( buffer ); + } + + public QueueBindBody( + int ticket, + AMQShortString queue, + AMQShortString exchange, + AMQShortString routingKey, + boolean nowait, + FieldTable arguments + ) + { + _ticket = ticket; + _queue = queue; + _exchange = exchange; + _routingKey = routingKey; + byte bitfield0 = (byte)0; + if( nowait ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + + _bitfield0 = bitfield0; + _arguments = arguments; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } - public FieldTable getArguments(); + public final int getTicket() + { + return _ticket; + } + public final AMQShortString getQueue() + { + return _queue; + } + public final AMQShortString getExchange() + { + return _exchange; + } + public final AMQShortString getRoutingKey() + { + return _routingKey; + } + public final boolean getNowait() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + public final FieldTable getArguments() + { + return _arguments; + } - public AMQShortString getExchange(); + protected int getBodySize() + { + int size = 3; + size += getSizeOf( _queue ); + size += getSizeOf( _exchange ); + size += getSizeOf( _routingKey ); + size += getSizeOf( _arguments ); + return size; + } - public boolean getNowait(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _ticket ); + writeAMQShortString( buffer, _queue ); + writeAMQShortString( buffer, _exchange ); + writeAMQShortString( buffer, _routingKey ); + writeBitfield( buffer, _bitfield0 ); + writeFieldTable( buffer, _arguments ); + } - public AMQShortString getQueue(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchQueueBind(this, channelId); + } - public AMQShortString getRoutingKey(); + public String toString() + { + StringBuilder buf = new StringBuilder("[QueueBindBodyImpl: "); + buf.append( "ticket=" ); + buf.append( getTicket() ); + buf.append( ", " ); + buf.append( "queue=" ); + buf.append( getQueue() ); + buf.append( ", " ); + buf.append( "exchange=" ); + buf.append( getExchange() ); + buf.append( ", " ); + buf.append( "routingKey=" ); + buf.append( getRoutingKey() ); + buf.append( ", " ); + buf.append( "nowait=" ); + buf.append( getNowait() ); + buf.append( ", " ); + buf.append( "arguments=" ); + buf.append( getArguments() ); + buf.append("]"); + return buf.toString(); + } - public int getTicket(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueBindBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/QueueBindBodyImpl.java deleted file mode 100644 index d68e3d4267..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueBindBodyImpl.java +++ /dev/null @@ -1,180 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class QueueBindBodyImpl extends AMQMethodBodyImpl implements QueueBindBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new QueueBindBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 50; - public static final int METHOD_ID = 20; - - // Fields declared in specification - private final int _ticket; // [ticket] - private final AMQShortString _queue; // [queue] - private final AMQShortString _exchange; // [exchange] - private final AMQShortString _routingKey; // [routingKey] - private final byte _bitfield0; // [nowait] - private final FieldTable _arguments; // [arguments] - - // Constructor - public QueueBindBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _ticket = readUnsignedShort( buffer ); - _queue = readAMQShortString( buffer ); - _exchange = readAMQShortString( buffer ); - _routingKey = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - _arguments = readFieldTable( buffer ); - } - - public QueueBindBodyImpl( - int ticket, - AMQShortString queue, - AMQShortString exchange, - AMQShortString routingKey, - boolean nowait, - FieldTable arguments - ) - { - _ticket = ticket; - _queue = queue; - _exchange = exchange; - _routingKey = routingKey; - byte bitfield0 = (byte)0; - if( nowait ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - - _bitfield0 = bitfield0; - _arguments = arguments; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getTicket() - { - return _ticket; - } - public final AMQShortString getQueue() - { - return _queue; - } - public final AMQShortString getExchange() - { - return _exchange; - } - public final AMQShortString getRoutingKey() - { - return _routingKey; - } - public final boolean getNowait() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - public final FieldTable getArguments() - { - return _arguments; - } - - protected int getBodySize() - { - int size = 3; - size += getSizeOf( _queue ); - size += getSizeOf( _exchange ); - size += getSizeOf( _routingKey ); - size += getSizeOf( _arguments ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _ticket ); - writeAMQShortString( buffer, _queue ); - writeAMQShortString( buffer, _exchange ); - writeAMQShortString( buffer, _routingKey ); - writeBitfield( buffer, _bitfield0 ); - writeFieldTable( buffer, _arguments ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchQueueBind(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[QueueBindBodyImpl: "); - buf.append( "ticket=" ); - buf.append( getTicket() ); - buf.append( ", " ); - buf.append( "queue=" ); - buf.append( getQueue() ); - buf.append( ", " ); - buf.append( "exchange=" ); - buf.append( getExchange() ); - buf.append( ", " ); - buf.append( "routingKey=" ); - buf.append( getRoutingKey() ); - buf.append( ", " ); - buf.append( "nowait=" ); - buf.append( getNowait() ); - buf.append( ", " ); - buf.append( "arguments=" ); - buf.append( getArguments() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueBindOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/QueueBindOkBody.java index 3e2f0104f8..be230b9cb7 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueBindOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/QueueBindOkBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface QueueBindOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class QueueBindOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new QueueBindOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 50; + public static final int METHOD_ID = 21; + + // Fields declared in specification + + // Constructor + public QueueBindOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public QueueBindOkBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchQueueBindOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[QueueBindOkBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueBindOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/QueueBindOkBodyImpl.java deleted file mode 100644 index b58fbfca52..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueBindOkBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class QueueBindOkBodyImpl extends AMQMethodBodyImpl implements QueueBindOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new QueueBindOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 50; - public static final int METHOD_ID = 21; - - // Fields declared in specification - - // Constructor - public QueueBindOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public QueueBindOkBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchQueueBindOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[QueueBindOkBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareBody.java b/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareBody.java index 23066457e6..a2cc2cf994 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareBody.java @@ -22,29 +22,185 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface QueueDeclareBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class QueueDeclareBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new QueueDeclareBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 50; + public static final int METHOD_ID = 10; + + // Fields declared in specification + private final int _ticket; // [ticket] + private final AMQShortString _queue; // [queue] + private final byte _bitfield0; // [passive, durable, exclusive, autoDelete, nowait] + private final FieldTable _arguments; // [arguments] + + // Constructor + public QueueDeclareBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _ticket = readUnsignedShort( buffer ); + _queue = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + _arguments = readFieldTable( buffer ); + } + + public QueueDeclareBody( + int ticket, + AMQShortString queue, + boolean passive, + boolean durable, + boolean exclusive, + boolean autoDelete, + boolean nowait, + FieldTable arguments + ) + { + _ticket = ticket; + _queue = queue; + byte bitfield0 = (byte)0; + if( passive ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + + if( durable ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); + } + + if( exclusive ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 2)); + } + + if( autoDelete ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 3)); + } + + if( nowait ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 4)); + } + + _bitfield0 = bitfield0; + _arguments = arguments; + } - public FieldTable getArguments(); + public int getClazz() + { + return CLASS_ID; + } - public boolean getAutoDelete(); + public int getMethod() + { + return METHOD_ID; + } - public boolean getDurable(); + public final int getTicket() + { + return _ticket; + } + public final AMQShortString getQueue() + { + return _queue; + } + public final boolean getPassive() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + public final boolean getDurable() + { + return (((int)(_bitfield0)) & ( 1 << 1)) != 0; + } + public final boolean getExclusive() + { + return (((int)(_bitfield0)) & ( 1 << 2)) != 0; + } + public final boolean getAutoDelete() + { + return (((int)(_bitfield0)) & ( 1 << 3)) != 0; + } + public final boolean getNowait() + { + return (((int)(_bitfield0)) & ( 1 << 4)) != 0; + } + public final FieldTable getArguments() + { + return _arguments; + } - public boolean getExclusive(); + protected int getBodySize() + { + int size = 3; + size += getSizeOf( _queue ); + size += getSizeOf( _arguments ); + return size; + } - public boolean getNowait(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _ticket ); + writeAMQShortString( buffer, _queue ); + writeBitfield( buffer, _bitfield0 ); + writeFieldTable( buffer, _arguments ); + } - public boolean getPassive(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchQueueDeclare(this, channelId); + } - public AMQShortString getQueue(); + public String toString() + { + StringBuilder buf = new StringBuilder("[QueueDeclareBodyImpl: "); + buf.append( "ticket=" ); + buf.append( getTicket() ); + buf.append( ", " ); + buf.append( "queue=" ); + buf.append( getQueue() ); + buf.append( ", " ); + buf.append( "passive=" ); + buf.append( getPassive() ); + buf.append( ", " ); + buf.append( "durable=" ); + buf.append( getDurable() ); + buf.append( ", " ); + buf.append( "exclusive=" ); + buf.append( getExclusive() ); + buf.append( ", " ); + buf.append( "autoDelete=" ); + buf.append( getAutoDelete() ); + buf.append( ", " ); + buf.append( "nowait=" ); + buf.append( getNowait() ); + buf.append( ", " ); + buf.append( "arguments=" ); + buf.append( getArguments() ); + buf.append("]"); + return buf.toString(); + } - public int getTicket(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareBodyImpl.java deleted file mode 100644 index 4765aa140c..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareBodyImpl.java +++ /dev/null @@ -1,206 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class QueueDeclareBodyImpl extends AMQMethodBodyImpl implements QueueDeclareBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new QueueDeclareBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 50; - public static final int METHOD_ID = 10; - - // Fields declared in specification - private final int _ticket; // [ticket] - private final AMQShortString _queue; // [queue] - private final byte _bitfield0; // [passive, durable, exclusive, autoDelete, nowait] - private final FieldTable _arguments; // [arguments] - - // Constructor - public QueueDeclareBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _ticket = readUnsignedShort( buffer ); - _queue = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - _arguments = readFieldTable( buffer ); - } - - public QueueDeclareBodyImpl( - int ticket, - AMQShortString queue, - boolean passive, - boolean durable, - boolean exclusive, - boolean autoDelete, - boolean nowait, - FieldTable arguments - ) - { - _ticket = ticket; - _queue = queue; - byte bitfield0 = (byte)0; - if( passive ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - - if( durable ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); - } - - if( exclusive ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 2)); - } - - if( autoDelete ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 3)); - } - - if( nowait ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 4)); - } - - _bitfield0 = bitfield0; - _arguments = arguments; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getTicket() - { - return _ticket; - } - public final AMQShortString getQueue() - { - return _queue; - } - public final boolean getPassive() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - public final boolean getDurable() - { - return (((int)(_bitfield0)) & ( 1 << 1)) != 0; - } - public final boolean getExclusive() - { - return (((int)(_bitfield0)) & ( 1 << 2)) != 0; - } - public final boolean getAutoDelete() - { - return (((int)(_bitfield0)) & ( 1 << 3)) != 0; - } - public final boolean getNowait() - { - return (((int)(_bitfield0)) & ( 1 << 4)) != 0; - } - public final FieldTable getArguments() - { - return _arguments; - } - - protected int getBodySize() - { - int size = 3; - size += getSizeOf( _queue ); - size += getSizeOf( _arguments ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _ticket ); - writeAMQShortString( buffer, _queue ); - writeBitfield( buffer, _bitfield0 ); - writeFieldTable( buffer, _arguments ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchQueueDeclare(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[QueueDeclareBodyImpl: "); - buf.append( "ticket=" ); - buf.append( getTicket() ); - buf.append( ", " ); - buf.append( "queue=" ); - buf.append( getQueue() ); - buf.append( ", " ); - buf.append( "passive=" ); - buf.append( getPassive() ); - buf.append( ", " ); - buf.append( "durable=" ); - buf.append( getDurable() ); - buf.append( ", " ); - buf.append( "exclusive=" ); - buf.append( getExclusive() ); - buf.append( ", " ); - buf.append( "autoDelete=" ); - buf.append( getAutoDelete() ); - buf.append( ", " ); - buf.append( "nowait=" ); - buf.append( getNowait() ); - buf.append( ", " ); - buf.append( "arguments=" ); - buf.append( getArguments() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareOkBody.java index 0557f2c54d..0df80bd6b4 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareOkBody.java @@ -22,19 +22,114 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface QueueDeclareOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class QueueDeclareOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new QueueDeclareOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 50; + public static final int METHOD_ID = 11; + + // Fields declared in specification + private final AMQShortString _queue; // [queue] + private final long _messageCount; // [messageCount] + private final long _consumerCount; // [consumerCount] + + // Constructor + public QueueDeclareOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _queue = readAMQShortString( buffer ); + _messageCount = readUnsignedInteger( buffer ); + _consumerCount = readUnsignedInteger( buffer ); + } + + public QueueDeclareOkBody( + AMQShortString queue, + long messageCount, + long consumerCount + ) + { + _queue = queue; + _messageCount = messageCount; + _consumerCount = consumerCount; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final AMQShortString getQueue() + { + return _queue; + } + public final long getMessageCount() + { + return _messageCount; + } + public final long getConsumerCount() + { + return _consumerCount; + } + + protected int getBodySize() + { + int size = 8; + size += getSizeOf( _queue ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeAMQShortString( buffer, _queue ); + writeUnsignedInteger( buffer, _messageCount ); + writeUnsignedInteger( buffer, _consumerCount ); + } - public long getConsumerCount(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchQueueDeclareOk(this, channelId); + } - public long getMessageCount(); + public String toString() + { + StringBuilder buf = new StringBuilder("[QueueDeclareOkBodyImpl: "); + buf.append( "queue=" ); + buf.append( getQueue() ); + buf.append( ", " ); + buf.append( "messageCount=" ); + buf.append( getMessageCount() ); + buf.append( ", " ); + buf.append( "consumerCount=" ); + buf.append( getConsumerCount() ); + buf.append("]"); + return buf.toString(); + } - public AMQShortString getQueue(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareOkBodyImpl.java deleted file mode 100644 index bb243feb4a..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueDeclareOkBodyImpl.java +++ /dev/null @@ -1,135 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class QueueDeclareOkBodyImpl extends AMQMethodBodyImpl implements QueueDeclareOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new QueueDeclareOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 50; - public static final int METHOD_ID = 11; - - // Fields declared in specification - private final AMQShortString _queue; // [queue] - private final long _messageCount; // [messageCount] - private final long _consumerCount; // [consumerCount] - - // Constructor - public QueueDeclareOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _queue = readAMQShortString( buffer ); - _messageCount = readUnsignedInteger( buffer ); - _consumerCount = readUnsignedInteger( buffer ); - } - - public QueueDeclareOkBodyImpl( - AMQShortString queue, - long messageCount, - long consumerCount - ) - { - _queue = queue; - _messageCount = messageCount; - _consumerCount = consumerCount; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final AMQShortString getQueue() - { - return _queue; - } - public final long getMessageCount() - { - return _messageCount; - } - public final long getConsumerCount() - { - return _consumerCount; - } - - protected int getBodySize() - { - int size = 8; - size += getSizeOf( _queue ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeAMQShortString( buffer, _queue ); - writeUnsignedInteger( buffer, _messageCount ); - writeUnsignedInteger( buffer, _consumerCount ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchQueueDeclareOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[QueueDeclareOkBodyImpl: "); - buf.append( "queue=" ); - buf.append( getQueue() ); - buf.append( ", " ); - buf.append( "messageCount=" ); - buf.append( getMessageCount() ); - buf.append( ", " ); - buf.append( "consumerCount=" ); - buf.append( getConsumerCount() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteBody.java b/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteBody.java index 2cced4d67e..95390976fd 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteBody.java @@ -22,23 +22,145 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface QueueDeleteBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class QueueDeleteBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new QueueDeleteBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 50; + public static final int METHOD_ID = 40; + + // Fields declared in specification + private final int _ticket; // [ticket] + private final AMQShortString _queue; // [queue] + private final byte _bitfield0; // [ifUnused, ifEmpty, nowait] + + // Constructor + public QueueDeleteBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _ticket = readUnsignedShort( buffer ); + _queue = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public QueueDeleteBody( + int ticket, + AMQShortString queue, + boolean ifUnused, + boolean ifEmpty, + boolean nowait + ) + { + _ticket = ticket; + _queue = queue; + byte bitfield0 = (byte)0; + if( ifUnused ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + + if( ifEmpty ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); + } + + if( nowait ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 2)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getTicket() + { + return _ticket; + } + public final AMQShortString getQueue() + { + return _queue; + } + public final boolean getIfUnused() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + public final boolean getIfEmpty() + { + return (((int)(_bitfield0)) & ( 1 << 1)) != 0; + } + public final boolean getNowait() + { + return (((int)(_bitfield0)) & ( 1 << 2)) != 0; + } - public boolean getIfEmpty(); + protected int getBodySize() + { + int size = 3; + size += getSizeOf( _queue ); + return size; + } - public boolean getIfUnused(); + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _ticket ); + writeAMQShortString( buffer, _queue ); + writeBitfield( buffer, _bitfield0 ); + } - public boolean getNowait(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchQueueDelete(this, channelId); + } - public AMQShortString getQueue(); + public String toString() + { + StringBuilder buf = new StringBuilder("[QueueDeleteBodyImpl: "); + buf.append( "ticket=" ); + buf.append( getTicket() ); + buf.append( ", " ); + buf.append( "queue=" ); + buf.append( getQueue() ); + buf.append( ", " ); + buf.append( "ifUnused=" ); + buf.append( getIfUnused() ); + buf.append( ", " ); + buf.append( "ifEmpty=" ); + buf.append( getIfEmpty() ); + buf.append( ", " ); + buf.append( "nowait=" ); + buf.append( getNowait() ); + buf.append("]"); + return buf.toString(); + } - public int getTicket(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteBodyImpl.java deleted file mode 100644 index 781bf7f1b1..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteBodyImpl.java +++ /dev/null @@ -1,166 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class QueueDeleteBodyImpl extends AMQMethodBodyImpl implements QueueDeleteBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new QueueDeleteBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 50; - public static final int METHOD_ID = 40; - - // Fields declared in specification - private final int _ticket; // [ticket] - private final AMQShortString _queue; // [queue] - private final byte _bitfield0; // [ifUnused, ifEmpty, nowait] - - // Constructor - public QueueDeleteBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _ticket = readUnsignedShort( buffer ); - _queue = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public QueueDeleteBodyImpl( - int ticket, - AMQShortString queue, - boolean ifUnused, - boolean ifEmpty, - boolean nowait - ) - { - _ticket = ticket; - _queue = queue; - byte bitfield0 = (byte)0; - if( ifUnused ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - - if( ifEmpty ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 1)); - } - - if( nowait ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 2)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getTicket() - { - return _ticket; - } - public final AMQShortString getQueue() - { - return _queue; - } - public final boolean getIfUnused() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - public final boolean getIfEmpty() - { - return (((int)(_bitfield0)) & ( 1 << 1)) != 0; - } - public final boolean getNowait() - { - return (((int)(_bitfield0)) & ( 1 << 2)) != 0; - } - - protected int getBodySize() - { - int size = 3; - size += getSizeOf( _queue ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _ticket ); - writeAMQShortString( buffer, _queue ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchQueueDelete(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[QueueDeleteBodyImpl: "); - buf.append( "ticket=" ); - buf.append( getTicket() ); - buf.append( ", " ); - buf.append( "queue=" ); - buf.append( getQueue() ); - buf.append( ", " ); - buf.append( "ifUnused=" ); - buf.append( getIfUnused() ); - buf.append( ", " ); - buf.append( "ifEmpty=" ); - buf.append( getIfEmpty() ); - buf.append( ", " ); - buf.append( "nowait=" ); - buf.append( getNowait() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteOkBody.java index 41acf6f246..3c31e77b9f 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteOkBody.java @@ -22,15 +22,89 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface QueueDeleteOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class QueueDeleteOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new QueueDeleteOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 50; + public static final int METHOD_ID = 41; + + // Fields declared in specification + private final long _messageCount; // [messageCount] + + // Constructor + public QueueDeleteOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _messageCount = readUnsignedInteger( buffer ); + } + + public QueueDeleteOkBody( + long messageCount + ) + { + _messageCount = messageCount; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final long getMessageCount() + { + return _messageCount; + } + + protected int getBodySize() + { + int size = 4; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedInteger( buffer, _messageCount ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchQueueDeleteOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[QueueDeleteOkBodyImpl: "); + buf.append( "messageCount=" ); + buf.append( getMessageCount() ); + buf.append("]"); + return buf.toString(); + } - public long getMessageCount(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteOkBodyImpl.java deleted file mode 100644 index 72a02230b0..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/QueueDeleteOkBodyImpl.java +++ /dev/null @@ -1,110 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class QueueDeleteOkBodyImpl extends AMQMethodBodyImpl implements QueueDeleteOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new QueueDeleteOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 50; - public static final int METHOD_ID = 41; - - // Fields declared in specification - private final long _messageCount; // [messageCount] - - // Constructor - public QueueDeleteOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _messageCount = readUnsignedInteger( buffer ); - } - - public QueueDeleteOkBodyImpl( - long messageCount - ) - { - _messageCount = messageCount; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final long getMessageCount() - { - return _messageCount; - } - - protected int getBodySize() - { - int size = 4; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedInteger( buffer, _messageCount ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchQueueDeleteOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[QueueDeleteOkBodyImpl: "); - buf.append( "messageCount=" ); - buf.append( getMessageCount() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeBody.java b/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeBody.java index 1965345997..ee2858ebcb 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeBody.java @@ -22,19 +22,119 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface QueuePurgeBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class QueuePurgeBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new QueuePurgeBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 50; + public static final int METHOD_ID = 30; + + // Fields declared in specification + private final int _ticket; // [ticket] + private final AMQShortString _queue; // [queue] + private final byte _bitfield0; // [nowait] + + // Constructor + public QueuePurgeBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _ticket = readUnsignedShort( buffer ); + _queue = readAMQShortString( buffer ); + _bitfield0 = readBitfield( buffer ); + } + + public QueuePurgeBody( + int ticket, + AMQShortString queue, + boolean nowait + ) + { + _ticket = ticket; + _queue = queue; + byte bitfield0 = (byte)0; + if( nowait ) + { + bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); + } + _bitfield0 = bitfield0; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final int getTicket() + { + return _ticket; + } + public final AMQShortString getQueue() + { + return _queue; + } + public final boolean getNowait() + { + return (((int)(_bitfield0)) & ( 1 << 0)) != 0; + } + + protected int getBodySize() + { + int size = 3; + size += getSizeOf( _queue ); + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedShort( buffer, _ticket ); + writeAMQShortString( buffer, _queue ); + writeBitfield( buffer, _bitfield0 ); + } - public boolean getNowait(); + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchQueuePurge(this, channelId); + } - public AMQShortString getQueue(); + public String toString() + { + StringBuilder buf = new StringBuilder("[QueuePurgeBodyImpl: "); + buf.append( "ticket=" ); + buf.append( getTicket() ); + buf.append( ", " ); + buf.append( "queue=" ); + buf.append( getQueue() ); + buf.append( ", " ); + buf.append( "nowait=" ); + buf.append( getNowait() ); + buf.append("]"); + return buf.toString(); + } - public int getTicket(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeBodyImpl.java deleted file mode 100644 index 857a2e567c..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeBodyImpl.java +++ /dev/null @@ -1,140 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class QueuePurgeBodyImpl extends AMQMethodBodyImpl implements QueuePurgeBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new QueuePurgeBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 50; - public static final int METHOD_ID = 30; - - // Fields declared in specification - private final int _ticket; // [ticket] - private final AMQShortString _queue; // [queue] - private final byte _bitfield0; // [nowait] - - // Constructor - public QueuePurgeBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _ticket = readUnsignedShort( buffer ); - _queue = readAMQShortString( buffer ); - _bitfield0 = readBitfield( buffer ); - } - - public QueuePurgeBodyImpl( - int ticket, - AMQShortString queue, - boolean nowait - ) - { - _ticket = ticket; - _queue = queue; - byte bitfield0 = (byte)0; - if( nowait ) - { - bitfield0 = (byte) (((int) bitfield0) | (1 << 0)); - } - _bitfield0 = bitfield0; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final int getTicket() - { - return _ticket; - } - public final AMQShortString getQueue() - { - return _queue; - } - public final boolean getNowait() - { - return (((int)(_bitfield0)) & ( 1 << 0)) != 0; - } - - protected int getBodySize() - { - int size = 3; - size += getSizeOf( _queue ); - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedShort( buffer, _ticket ); - writeAMQShortString( buffer, _queue ); - writeBitfield( buffer, _bitfield0 ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchQueuePurge(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[QueuePurgeBodyImpl: "); - buf.append( "ticket=" ); - buf.append( getTicket() ); - buf.append( ", " ); - buf.append( "queue=" ); - buf.append( getQueue() ); - buf.append( ", " ); - buf.append( "nowait=" ); - buf.append( getNowait() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeOkBody.java index 2641dcf81d..921aa751f4 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeOkBody.java @@ -22,15 +22,89 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface QueuePurgeOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class QueuePurgeOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new QueuePurgeOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 50; + public static final int METHOD_ID = 31; + + // Fields declared in specification + private final long _messageCount; // [messageCount] + + // Constructor + public QueuePurgeOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + _messageCount = readUnsignedInteger( buffer ); + } + + public QueuePurgeOkBody( + long messageCount + ) + { + _messageCount = messageCount; + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + public final long getMessageCount() + { + return _messageCount; + } + + protected int getBodySize() + { + int size = 4; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + writeUnsignedInteger( buffer, _messageCount ); + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchQueuePurgeOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[QueuePurgeOkBodyImpl: "); + buf.append( "messageCount=" ); + buf.append( getMessageCount() ); + buf.append("]"); + return buf.toString(); + } - public long getMessageCount(); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeOkBodyImpl.java deleted file mode 100644 index c9e484ad50..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/QueuePurgeOkBodyImpl.java +++ /dev/null @@ -1,110 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class QueuePurgeOkBodyImpl extends AMQMethodBodyImpl implements QueuePurgeOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new QueuePurgeOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 50; - public static final int METHOD_ID = 31; - - // Fields declared in specification - private final long _messageCount; // [messageCount] - - // Constructor - public QueuePurgeOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - _messageCount = readUnsignedInteger( buffer ); - } - - public QueuePurgeOkBodyImpl( - long messageCount - ) - { - _messageCount = messageCount; - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - public final long getMessageCount() - { - return _messageCount; - } - - protected int getBodySize() - { - int size = 4; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - writeUnsignedInteger( buffer, _messageCount ); - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchQueuePurgeOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[QueuePurgeOkBodyImpl: "); - buf.append( "messageCount=" ); - buf.append( getMessageCount() ); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/ServerMethodDispatcher.java b/java/common/src/main/java/org/apache/qpid/framing/ServerMethodDispatcher.java index 6df8defed1..4ad16b9ca5 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/ServerMethodDispatcher.java +++ b/java/common/src/main/java/org/apache/qpid/framing/ServerMethodDispatcher.java @@ -64,4 +64,4 @@ public interface ServerMethodDispatcher public boolean dispatchTxRollback(TxRollbackBody body, int channelId) throws AMQException; public boolean dispatchTxSelect(TxSelectBody body, int channelId) throws AMQException; -}
\ No newline at end of file +} diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxCommitBody.java b/java/common/src/main/java/org/apache/qpid/framing/TxCommitBody.java index 189ea0cd40..f610301ffe 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/TxCommitBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/TxCommitBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface TxCommitBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class TxCommitBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new TxCommitBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 90; + public static final int METHOD_ID = 20; + + // Fields declared in specification + + // Constructor + public TxCommitBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public TxCommitBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchTxCommit(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[TxCommitBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxCommitBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/TxCommitBodyImpl.java deleted file mode 100644 index e98a939e70..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/TxCommitBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class TxCommitBodyImpl extends AMQMethodBodyImpl implements TxCommitBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new TxCommitBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 90; - public static final int METHOD_ID = 20; - - // Fields declared in specification - - // Constructor - public TxCommitBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public TxCommitBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchTxCommit(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[TxCommitBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxCommitOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/TxCommitOkBody.java index 3df65e0504..2976d3ea8d 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/TxCommitOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/TxCommitOkBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface TxCommitOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class TxCommitOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new TxCommitOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 90; + public static final int METHOD_ID = 21; + + // Fields declared in specification + + // Constructor + public TxCommitOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public TxCommitOkBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchTxCommitOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[TxCommitOkBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxCommitOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/TxCommitOkBodyImpl.java deleted file mode 100644 index 3bee9d210d..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/TxCommitOkBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class TxCommitOkBodyImpl extends AMQMethodBodyImpl implements TxCommitOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new TxCommitOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 90; - public static final int METHOD_ID = 21; - - // Fields declared in specification - - // Constructor - public TxCommitOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public TxCommitOkBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchTxCommitOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[TxCommitOkBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxRollbackBody.java b/java/common/src/main/java/org/apache/qpid/framing/TxRollbackBody.java index d440dc8e04..b456a67cf6 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/TxRollbackBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/TxRollbackBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface TxRollbackBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class TxRollbackBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new TxRollbackBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 90; + public static final int METHOD_ID = 30; + + // Fields declared in specification + + // Constructor + public TxRollbackBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public TxRollbackBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchTxRollback(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[TxRollbackBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxRollbackBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/TxRollbackBodyImpl.java deleted file mode 100644 index 7acb99984f..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/TxRollbackBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class TxRollbackBodyImpl extends AMQMethodBodyImpl implements TxRollbackBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new TxRollbackBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 90; - public static final int METHOD_ID = 30; - - // Fields declared in specification - - // Constructor - public TxRollbackBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public TxRollbackBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchTxRollback(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[TxRollbackBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxRollbackOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/TxRollbackOkBody.java index c542ff790a..26bd9d21b8 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/TxRollbackOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/TxRollbackOkBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface TxRollbackOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class TxRollbackOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new TxRollbackOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 90; + public static final int METHOD_ID = 31; + + // Fields declared in specification + + // Constructor + public TxRollbackOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public TxRollbackOkBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchTxRollbackOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[TxRollbackOkBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxRollbackOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/TxRollbackOkBodyImpl.java deleted file mode 100644 index 0412028472..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/TxRollbackOkBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class TxRollbackOkBodyImpl extends AMQMethodBodyImpl implements TxRollbackOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new TxRollbackOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 90; - public static final int METHOD_ID = 31; - - // Fields declared in specification - - // Constructor - public TxRollbackOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public TxRollbackOkBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchTxRollbackOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[TxRollbackOkBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxSelectBody.java b/java/common/src/main/java/org/apache/qpid/framing/TxSelectBody.java index c3c881cd9d..ced3c59050 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/TxSelectBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/TxSelectBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface TxSelectBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class TxSelectBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new TxSelectBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 90; + public static final int METHOD_ID = 10; + + // Fields declared in specification + + // Constructor + public TxSelectBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public TxSelectBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchTxSelect(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[TxSelectBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxSelectBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/TxSelectBodyImpl.java deleted file mode 100644 index 7d7172df7f..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/TxSelectBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class TxSelectBodyImpl extends AMQMethodBodyImpl implements TxSelectBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new TxSelectBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 90; - public static final int METHOD_ID = 10; - - // Fields declared in specification - - // Constructor - public TxSelectBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public TxSelectBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchTxSelect(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[TxSelectBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxSelectOkBody.java b/java/common/src/main/java/org/apache/qpid/framing/TxSelectOkBody.java index 6841283bb2..4814aed18f 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/TxSelectOkBody.java +++ b/java/common/src/main/java/org/apache/qpid/framing/TxSelectOkBody.java @@ -22,13 +22,78 @@ /* * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. * Supported AMQP version: - * 0-9 - * 0-91 - * 8-0 - */ + * 8-0 + */ package org.apache.qpid.framing; -public interface TxSelectOkBody extends EncodableAMQDataBlock, AMQMethodBody +import java.io.DataOutput; +import java.io.IOException; + +import org.apache.qpid.AMQException; +import org.apache.qpid.codec.MarkableDataInput; + +public class TxSelectOkBody extends AMQMethodBodyImpl implements EncodableAMQDataBlock, AMQMethodBody { + private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() + { + public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException + { + return new TxSelectOkBody(in); + } + }; + + public static AMQMethodBodyInstanceFactory getFactory() + { + return FACTORY_INSTANCE; + } + + public static final int CLASS_ID = 90; + public static final int METHOD_ID = 11; + + // Fields declared in specification + + // Constructor + public TxSelectOkBody(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException + { + } + + public TxSelectOkBody( + ) + { + } + + public int getClazz() + { + return CLASS_ID; + } + + public int getMethod() + { + return METHOD_ID; + } + + + protected int getBodySize() + { + int size = 0; + return size; + } + + public void writeMethodPayload(DataOutput buffer) throws IOException + { + } + + public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException + { + return dispatcher.dispatchTxSelectOk(this, channelId); + } + + public String toString() + { + StringBuilder buf = new StringBuilder("[TxSelectOkBodyImpl: "); + buf.append("]"); + return buf.toString(); + } + } diff --git a/java/common/src/main/java/org/apache/qpid/framing/TxSelectOkBodyImpl.java b/java/common/src/main/java/org/apache/qpid/framing/TxSelectOkBodyImpl.java deleted file mode 100644 index ddb62a270f..0000000000 --- a/java/common/src/main/java/org/apache/qpid/framing/TxSelectOkBodyImpl.java +++ /dev/null @@ -1,99 +0,0 @@ -/* - * - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - * - */ - -/* - * This file is auto-generated by Qpid Gentools v.0.1 - do not modify. - * Supported AMQP version: - * 8-0 - */ - -package org.apache.qpid.framing; - -import java.io.DataOutput; -import java.io.IOException; - -import org.apache.qpid.AMQException; -import org.apache.qpid.codec.MarkableDataInput; - -public class TxSelectOkBodyImpl extends AMQMethodBodyImpl implements TxSelectOkBody -{ - private static final AMQMethodBodyInstanceFactory FACTORY_INSTANCE = new AMQMethodBodyInstanceFactory() - { - public AMQMethodBody newInstance(MarkableDataInput in, long size) throws AMQFrameDecodingException, IOException - { - return new TxSelectOkBodyImpl(in); - } - }; - - public static AMQMethodBodyInstanceFactory getFactory() - { - return FACTORY_INSTANCE; - } - - public static final int CLASS_ID = 90; - public static final int METHOD_ID = 11; - - // Fields declared in specification - - // Constructor - public TxSelectOkBodyImpl(MarkableDataInput buffer) throws AMQFrameDecodingException, IOException - { - } - - public TxSelectOkBodyImpl( - ) - { - } - - public int getClazz() - { - return CLASS_ID; - } - - public int getMethod() - { - return METHOD_ID; - } - - - protected int getBodySize() - { - int size = 0; - return size; - } - - public void writeMethodPayload(DataOutput buffer) throws IOException - { - } - - public boolean execute(MethodDispatcher dispatcher, int channelId) throws AMQException - { - return dispatcher.dispatchTxSelectOk(this, channelId); - } - - public String toString() - { - StringBuilder buf = new StringBuilder("[TxSelectOkBodyImpl: "); - buf.append("]"); - return buf.toString(); - } - -} diff --git a/java/common/src/main/java/org/apache/qpid/framing/amqp_0_9/MethodConverter_0_9.java b/java/common/src/main/java/org/apache/qpid/framing/amqp_0_9/MethodConverter_0_9.java index 9fd961bb13..e473ce7926 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/amqp_0_9/MethodConverter_0_9.java +++ b/java/common/src/main/java/org/apache/qpid/framing/amqp_0_9/MethodConverter_0_9.java @@ -24,7 +24,6 @@ package org.apache.qpid.framing.amqp_0_9; import org.apache.qpid.framing.AMQMethodBody; import org.apache.qpid.framing.AMQShortString; import org.apache.qpid.framing.BasicPublishBody; -import org.apache.qpid.framing.BasicPublishBodyImpl; import org.apache.qpid.framing.abstraction.AbstractMethodConverter; import org.apache.qpid.framing.abstraction.MessagePublishInfo; import org.apache.qpid.framing.abstraction.MessagePublishInfoImpl; @@ -57,7 +56,7 @@ public class MethodConverter_0_9 extends AbstractMethodConverter implements Prot public AMQMethodBody convertToBody(MessagePublishInfo info) { - return new BasicPublishBodyImpl(0, + return new BasicPublishBody(0, info.getExchange(), info.getRoutingKey(), info.isMandatory(), diff --git a/java/common/src/main/java/org/apache/qpid/framing/amqp_0_9/MethodRegistry_0_9.java b/java/common/src/main/java/org/apache/qpid/framing/amqp_0_9/MethodRegistry_0_9.java index 5fb7695aee..6b016d316c 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/amqp_0_9/MethodRegistry_0_9.java +++ b/java/common/src/main/java/org/apache/qpid/framing/amqp_0_9/MethodRegistry_0_9.java @@ -62,14 +62,14 @@ public class MethodRegistry_0_9 extends MethodRegistry _factories[10] = new AMQMethodBodyInstanceFactory[52]; - _factories[10][10] = ConnectionStartBodyImpl.getFactory(); - _factories[10][11] = ConnectionStartOkBodyImpl.getFactory(); - _factories[10][20] = ConnectionSecureBodyImpl.getFactory(); - _factories[10][21] = ConnectionSecureOkBodyImpl.getFactory(); - _factories[10][30] = ConnectionTuneBodyImpl.getFactory(); - _factories[10][31] = ConnectionTuneOkBodyImpl.getFactory(); - _factories[10][40] = ConnectionOpenBodyImpl.getFactory(); - _factories[10][41] = ConnectionOpenOkBodyImpl.getFactory(); + _factories[10][10] = ConnectionStartBody.getFactory(); + _factories[10][11] = ConnectionStartOkBody.getFactory(); + _factories[10][20] = ConnectionSecureBody.getFactory(); + _factories[10][21] = ConnectionSecureOkBody.getFactory(); + _factories[10][30] = ConnectionTuneBody.getFactory(); + _factories[10][31] = ConnectionTuneOkBody.getFactory(); + _factories[10][40] = ConnectionOpenBody.getFactory(); + _factories[10][41] = ConnectionOpenOkBody.getFactory(); _factories[10][42] = ConnectionRedirectBodyImpl.getFactory(); _factories[10][50] = ConnectionCloseBodyImpl.getFactory(); _factories[10][51] = ConnectionCloseOkBodyImpl.getFactory(); @@ -80,12 +80,12 @@ public class MethodRegistry_0_9 extends MethodRegistry _factories[20] = new AMQMethodBodyInstanceFactory[81]; - _factories[20][10] = ChannelOpenBodyImpl.getFactory(); + _factories[20][10] = ChannelOpenBody.getFactory(); _factories[20][11] = ChannelOpenOkBodyImpl.getFactory(); - _factories[20][20] = ChannelFlowBodyImpl.getFactory(); - _factories[20][21] = ChannelFlowOkBodyImpl.getFactory(); - _factories[20][40] = ChannelCloseBodyImpl.getFactory(); - _factories[20][41] = ChannelCloseOkBodyImpl.getFactory(); + _factories[20][20] = ChannelFlowBody.getFactory(); + _factories[20][21] = ChannelFlowOkBody.getFactory(); + _factories[20][40] = ChannelCloseBody.getFactory(); + _factories[20][41] = ChannelCloseOkBody.getFactory(); @@ -102,12 +102,12 @@ public class MethodRegistry_0_9 extends MethodRegistry _factories[40] = new AMQMethodBodyInstanceFactory[24]; - _factories[40][10] = ExchangeDeclareBodyImpl.getFactory(); - _factories[40][11] = ExchangeDeclareOkBodyImpl.getFactory(); - _factories[40][20] = ExchangeDeleteBodyImpl.getFactory(); - _factories[40][21] = ExchangeDeleteOkBodyImpl.getFactory(); - _factories[40][22] = ExchangeBoundBodyImpl.getFactory(); - _factories[40][23] = ExchangeBoundOkBodyImpl.getFactory(); + _factories[40][10] = ExchangeDeclareBody.getFactory(); + _factories[40][11] = ExchangeDeclareOkBody.getFactory(); + _factories[40][20] = ExchangeDeleteBody.getFactory(); + _factories[40][21] = ExchangeDeleteOkBody.getFactory(); + _factories[40][22] = ExchangeBoundBody.getFactory(); + _factories[40][23] = ExchangeBoundOkBody.getFactory(); @@ -115,14 +115,14 @@ public class MethodRegistry_0_9 extends MethodRegistry _factories[50] = new AMQMethodBodyInstanceFactory[52]; - _factories[50][10] = QueueDeclareBodyImpl.getFactory(); - _factories[50][11] = QueueDeclareOkBodyImpl.getFactory(); - _factories[50][20] = QueueBindBodyImpl.getFactory(); - _factories[50][21] = QueueBindOkBodyImpl.getFactory(); - _factories[50][30] = QueuePurgeBodyImpl.getFactory(); - _factories[50][31] = QueuePurgeOkBodyImpl.getFactory(); - _factories[50][40] = QueueDeleteBodyImpl.getFactory(); - _factories[50][41] = QueueDeleteOkBodyImpl.getFactory(); + _factories[50][10] = QueueDeclareBody.getFactory(); + _factories[50][11] = QueueDeclareOkBody.getFactory(); + _factories[50][20] = QueueBindBody.getFactory(); + _factories[50][21] = QueueBindOkBody.getFactory(); + _factories[50][30] = QueuePurgeBody.getFactory(); + _factories[50][31] = QueuePurgeOkBody.getFactory(); + _factories[50][40] = QueueDeleteBody.getFactory(); + _factories[50][41] = QueueDeleteOkBody.getFactory(); _factories[50][50] = QueueUnbindBodyImpl.getFactory(); _factories[50][51] = QueueUnbindOkBodyImpl.getFactory(); @@ -132,21 +132,21 @@ public class MethodRegistry_0_9 extends MethodRegistry _factories[60] = new AMQMethodBodyInstanceFactory[103]; - _factories[60][10] = BasicQosBodyImpl.getFactory(); - _factories[60][11] = BasicQosOkBodyImpl.getFactory(); - _factories[60][20] = BasicConsumeBodyImpl.getFactory(); - _factories[60][21] = BasicConsumeOkBodyImpl.getFactory(); - _factories[60][30] = BasicCancelBodyImpl.getFactory(); - _factories[60][31] = BasicCancelOkBodyImpl.getFactory(); - _factories[60][40] = BasicPublishBodyImpl.getFactory(); - _factories[60][50] = BasicReturnBodyImpl.getFactory(); - _factories[60][60] = BasicDeliverBodyImpl.getFactory(); - _factories[60][70] = BasicGetBodyImpl.getFactory(); - _factories[60][71] = BasicGetOkBodyImpl.getFactory(); - _factories[60][72] = BasicGetEmptyBodyImpl.getFactory(); - _factories[60][80] = BasicAckBodyImpl.getFactory(); - _factories[60][90] = BasicRejectBodyImpl.getFactory(); - _factories[60][100] = BasicRecoverBodyImpl.getFactory(); + _factories[60][10] = BasicQosBody.getFactory(); + _factories[60][11] = BasicQosOkBody.getFactory(); + _factories[60][20] = BasicConsumeBody.getFactory(); + _factories[60][21] = BasicConsumeOkBody.getFactory(); + _factories[60][30] = BasicCancelBody.getFactory(); + _factories[60][31] = BasicCancelOkBody.getFactory(); + _factories[60][40] = BasicPublishBody.getFactory(); + _factories[60][50] = BasicReturnBody.getFactory(); + _factories[60][60] = BasicDeliverBody.getFactory(); + _factories[60][70] = BasicGetBody.getFactory(); + _factories[60][71] = BasicGetOkBody.getFactory(); + _factories[60][72] = BasicGetEmptyBody.getFactory(); + _factories[60][80] = BasicAckBody.getFactory(); + _factories[60][90] = BasicRejectBody.getFactory(); + _factories[60][100] = BasicRecoverBody.getFactory(); _factories[60][101] = BasicRecoverSyncOkBodyImpl.getFactory(); _factories[60][102] = BasicRecoverSyncBodyImpl.getFactory(); @@ -156,12 +156,12 @@ public class MethodRegistry_0_9 extends MethodRegistry _factories[90] = new AMQMethodBodyInstanceFactory[32]; - _factories[90][10] = TxSelectBodyImpl.getFactory(); - _factories[90][11] = TxSelectOkBodyImpl.getFactory(); - _factories[90][20] = TxCommitBodyImpl.getFactory(); - _factories[90][21] = TxCommitOkBodyImpl.getFactory(); - _factories[90][30] = TxRollbackBodyImpl.getFactory(); - _factories[90][31] = TxRollbackOkBodyImpl.getFactory(); + _factories[90][10] = TxSelectBody.getFactory(); + _factories[90][11] = TxSelectOkBody.getFactory(); + _factories[90][20] = TxCommitBody.getFactory(); + _factories[90][21] = TxCommitOkBody.getFactory(); + _factories[90][30] = TxRollbackBody.getFactory(); + _factories[90][31] = TxRollbackOkBody.getFactory(); } @@ -223,14 +223,14 @@ public class MethodRegistry_0_9 extends MethodRegistry public ConnectionStartBody createConnectionStartBody( - final short versionMajor, - final short versionMinor, - final FieldTable serverProperties, - final byte[] mechanisms, - final byte[] locales - ) - { - return new ConnectionStartBodyImpl( + final short versionMajor, + final short versionMinor, + final FieldTable serverProperties, + final byte[] mechanisms, + final byte[] locales + ) + { + return new ConnectionStartBody( versionMajor, versionMinor, serverProperties, @@ -240,13 +240,13 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ConnectionStartOkBody createConnectionStartOkBody( - final FieldTable clientProperties, - final AMQShortString mechanism, - final byte[] response, - final AMQShortString locale - ) + final FieldTable clientProperties, + final AMQShortString mechanism, + final byte[] response, + final AMQShortString locale + ) { - return new ConnectionStartOkBodyImpl( + return new ConnectionStartOkBody( clientProperties, mechanism, response, @@ -255,30 +255,30 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ConnectionSecureBody createConnectionSecureBody( - final byte[] challenge - ) + final byte[] challenge + ) { - return new ConnectionSecureBodyImpl( + return new ConnectionSecureBody( challenge ); } public ConnectionSecureOkBody createConnectionSecureOkBody( - final byte[] response - ) + final byte[] response + ) { - return new ConnectionSecureOkBodyImpl( + return new ConnectionSecureOkBody( response ); } public ConnectionTuneBody createConnectionTuneBody( - final int channelMax, - final long frameMax, - final int heartbeat - ) + final int channelMax, + final long frameMax, + final int heartbeat + ) { - return new ConnectionTuneBodyImpl( + return new ConnectionTuneBody( channelMax, frameMax, heartbeat @@ -286,12 +286,12 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ConnectionTuneOkBody createConnectionTuneOkBody( - final int channelMax, - final long frameMax, - final int heartbeat - ) + final int channelMax, + final long frameMax, + final int heartbeat + ) { - return new ConnectionTuneOkBodyImpl( + return new ConnectionTuneOkBody( channelMax, frameMax, heartbeat @@ -299,12 +299,12 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ConnectionOpenBody createConnectionOpenBody( - final AMQShortString virtualHost, - final AMQShortString capabilities, - final boolean insist - ) + final AMQShortString virtualHost, + final AMQShortString capabilities, + final boolean insist + ) { - return new ConnectionOpenBodyImpl( + return new ConnectionOpenBody( virtualHost, capabilities, insist @@ -312,10 +312,10 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ConnectionOpenOkBody createConnectionOpenOkBody( - final AMQShortString knownHosts - ) + final AMQShortString knownHosts + ) { - return new ConnectionOpenOkBodyImpl( + return new ConnectionOpenOkBody( knownHosts ); } @@ -357,10 +357,10 @@ public class MethodRegistry_0_9 extends MethodRegistry public ChannelOpenBody createChannelOpenBody( - final AMQShortString outOfBand - ) + final AMQShortString outOfBand + ) { - return new ChannelOpenBodyImpl( + return new ChannelOpenBody( outOfBand ); } @@ -375,31 +375,31 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ChannelFlowBody createChannelFlowBody( - final boolean active - ) + final boolean active + ) { - return new ChannelFlowBodyImpl( + return new ChannelFlowBody( active ); } public ChannelFlowOkBody createChannelFlowOkBody( - final boolean active - ) + final boolean active + ) { - return new ChannelFlowOkBodyImpl( + return new ChannelFlowOkBody( active ); } public ChannelCloseBody createChannelCloseBody( - final int replyCode, - final AMQShortString replyText, - final int classId, - final int methodId - ) + final int replyCode, + final AMQShortString replyText, + final int classId, + final int methodId + ) { - return new ChannelCloseBodyImpl( + return new ChannelCloseBody( replyCode, replyText, classId, @@ -408,9 +408,9 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ChannelCloseOkBody createChannelCloseOkBody( - ) + ) { - return new ChannelCloseOkBodyImpl( + return new ChannelCloseOkBody( ); } @@ -447,18 +447,18 @@ public class MethodRegistry_0_9 extends MethodRegistry public ExchangeDeclareBody createExchangeDeclareBody( - final int ticket, - final AMQShortString exchange, - final AMQShortString type, - final boolean passive, - final boolean durable, - final boolean autoDelete, - final boolean internal, - final boolean nowait, - final FieldTable arguments - ) - { - return new ExchangeDeclareBodyImpl( + final int ticket, + final AMQShortString exchange, + final AMQShortString type, + final boolean passive, + final boolean durable, + final boolean autoDelete, + final boolean internal, + final boolean nowait, + final FieldTable arguments + ) + { + return new ExchangeDeclareBody( ticket, exchange, type, @@ -472,20 +472,20 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ExchangeDeclareOkBody createExchangeDeclareOkBody( - ) + ) { - return new ExchangeDeclareOkBodyImpl( + return new ExchangeDeclareOkBody( ); } public ExchangeDeleteBody createExchangeDeleteBody( - final int ticket, - final AMQShortString exchange, - final boolean ifUnused, - final boolean nowait - ) + final int ticket, + final AMQShortString exchange, + final boolean ifUnused, + final boolean nowait + ) { - return new ExchangeDeleteBodyImpl( + return new ExchangeDeleteBody( ticket, exchange, ifUnused, @@ -494,19 +494,19 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ExchangeDeleteOkBody createExchangeDeleteOkBody( - ) + ) { - return new ExchangeDeleteOkBodyImpl( + return new ExchangeDeleteOkBody( ); } public ExchangeBoundBody createExchangeBoundBody( - final AMQShortString exchange, - final AMQShortString routingKey, - final AMQShortString queue - ) + final AMQShortString exchange, + final AMQShortString routingKey, + final AMQShortString queue + ) { - return new ExchangeBoundBodyImpl( + return new ExchangeBoundBody( exchange, routingKey, queue @@ -514,11 +514,11 @@ public class MethodRegistry_0_9 extends MethodRegistry } public ExchangeBoundOkBody createExchangeBoundOkBody( - final int replyCode, - final AMQShortString replyText - ) + final int replyCode, + final AMQShortString replyText + ) { - return new ExchangeBoundOkBodyImpl( + return new ExchangeBoundOkBody( replyCode, replyText ); @@ -528,17 +528,17 @@ public class MethodRegistry_0_9 extends MethodRegistry public QueueDeclareBody createQueueDeclareBody( - final int ticket, - final AMQShortString queue, - final boolean passive, - final boolean durable, - final boolean exclusive, - final boolean autoDelete, - final boolean nowait, - final FieldTable arguments - ) - { - return new QueueDeclareBodyImpl( + final int ticket, + final AMQShortString queue, + final boolean passive, + final boolean durable, + final boolean exclusive, + final boolean autoDelete, + final boolean nowait, + final FieldTable arguments + ) + { + return new QueueDeclareBody( ticket, queue, passive, @@ -551,12 +551,12 @@ public class MethodRegistry_0_9 extends MethodRegistry } public QueueDeclareOkBody createQueueDeclareOkBody( - final AMQShortString queue, - final long messageCount, - final long consumerCount - ) + final AMQShortString queue, + final long messageCount, + final long consumerCount + ) { - return new QueueDeclareOkBodyImpl( + return new QueueDeclareOkBody( queue, messageCount, consumerCount @@ -564,15 +564,15 @@ public class MethodRegistry_0_9 extends MethodRegistry } public QueueBindBody createQueueBindBody( - final int ticket, - final AMQShortString queue, - final AMQShortString exchange, - final AMQShortString routingKey, - final boolean nowait, - final FieldTable arguments - ) - { - return new QueueBindBodyImpl( + final int ticket, + final AMQShortString queue, + final AMQShortString exchange, + final AMQShortString routingKey, + final boolean nowait, + final FieldTable arguments + ) + { + return new QueueBindBody( ticket, queue, exchange, @@ -583,19 +583,19 @@ public class MethodRegistry_0_9 extends MethodRegistry } public QueueBindOkBody createQueueBindOkBody( - ) + ) { - return new QueueBindOkBodyImpl( + return new QueueBindOkBody( ); } public QueuePurgeBody createQueuePurgeBody( - final int ticket, - final AMQShortString queue, - final boolean nowait - ) + final int ticket, + final AMQShortString queue, + final boolean nowait + ) { - return new QueuePurgeBodyImpl( + return new QueuePurgeBody( ticket, queue, nowait @@ -603,23 +603,23 @@ public class MethodRegistry_0_9 extends MethodRegistry } public QueuePurgeOkBody createQueuePurgeOkBody( - final long messageCount - ) + final long messageCount + ) { - return new QueuePurgeOkBodyImpl( + return new QueuePurgeOkBody( messageCount ); } public QueueDeleteBody createQueueDeleteBody( - final int ticket, - final AMQShortString queue, - final boolean ifUnused, - final boolean ifEmpty, - final boolean nowait - ) - { - return new QueueDeleteBodyImpl( + final int ticket, + final AMQShortString queue, + final boolean ifUnused, + final boolean ifEmpty, + final boolean nowait + ) + { + return new QueueDeleteBody( ticket, queue, ifUnused, @@ -629,10 +629,10 @@ public class MethodRegistry_0_9 extends MethodRegistry } public QueueDeleteOkBody createQueueDeleteOkBody( - final long messageCount - ) + final long messageCount + ) { - return new QueueDeleteOkBodyImpl( + return new QueueDeleteOkBody( messageCount ); } @@ -665,12 +665,12 @@ public class MethodRegistry_0_9 extends MethodRegistry public BasicQosBody createBasicQosBody( - final long prefetchSize, - final int prefetchCount, - final boolean global - ) + final long prefetchSize, + final int prefetchCount, + final boolean global + ) { - return new BasicQosBodyImpl( + return new BasicQosBody( prefetchSize, prefetchCount, global @@ -678,24 +678,24 @@ public class MethodRegistry_0_9 extends MethodRegistry } public BasicQosOkBody createBasicQosOkBody( - ) + ) { - return new BasicQosOkBodyImpl( + return new BasicQosOkBody( ); } public BasicConsumeBody createBasicConsumeBody( - final int ticket, - final AMQShortString queue, - final AMQShortString consumerTag, - final boolean noLocal, - final boolean noAck, - final boolean exclusive, - final boolean nowait, - final FieldTable arguments - ) - { - return new BasicConsumeBodyImpl( + final int ticket, + final AMQShortString queue, + final AMQShortString consumerTag, + final boolean noLocal, + final boolean noAck, + final boolean exclusive, + final boolean nowait, + final FieldTable arguments + ) + { + return new BasicConsumeBody( ticket, queue, consumerTag, @@ -708,43 +708,43 @@ public class MethodRegistry_0_9 extends MethodRegistry } public BasicConsumeOkBody createBasicConsumeOkBody( - final AMQShortString consumerTag - ) + final AMQShortString consumerTag + ) { - return new BasicConsumeOkBodyImpl( + return new BasicConsumeOkBody( consumerTag ); } public BasicCancelBody createBasicCancelBody( - final AMQShortString consumerTag, - final boolean nowait - ) + final AMQShortString consumerTag, + final boolean nowait + ) { - return new BasicCancelBodyImpl( + return new BasicCancelBody( consumerTag, nowait ); } public BasicCancelOkBody createBasicCancelOkBody( - final AMQShortString consumerTag - ) + final AMQShortString consumerTag + ) { - return new BasicCancelOkBodyImpl( + return new BasicCancelOkBody( consumerTag ); } public BasicPublishBody createBasicPublishBody( - final int ticket, - final AMQShortString exchange, - final AMQShortString routingKey, - final boolean mandatory, - final boolean immediate - ) - { - return new BasicPublishBodyImpl( + final int ticket, + final AMQShortString exchange, + final AMQShortString routingKey, + final boolean mandatory, + final boolean immediate + ) + { + return new BasicPublishBody( ticket, exchange, routingKey, @@ -754,13 +754,13 @@ public class MethodRegistry_0_9 extends MethodRegistry } public BasicReturnBody createBasicReturnBody( - final int replyCode, - final AMQShortString replyText, - final AMQShortString exchange, - final AMQShortString routingKey - ) + final int replyCode, + final AMQShortString replyText, + final AMQShortString exchange, + final AMQShortString routingKey + ) { - return new BasicReturnBodyImpl( + return new BasicReturnBody( replyCode, replyText, exchange, @@ -769,14 +769,14 @@ public class MethodRegistry_0_9 extends MethodRegistry } public BasicDeliverBody createBasicDeliverBody( - final AMQShortString consumerTag, - final long deliveryTag, - final boolean redelivered, - final AMQShortString exchange, - final AMQShortString routingKey - ) - { - return new BasicDeliverBodyImpl( + final AMQShortString consumerTag, + final long deliveryTag, + final boolean redelivered, + final AMQShortString exchange, + final AMQShortString routingKey + ) + { + return new BasicDeliverBody( consumerTag, deliveryTag, redelivered, @@ -786,12 +786,12 @@ public class MethodRegistry_0_9 extends MethodRegistry } public BasicGetBody createBasicGetBody( - final int ticket, - final AMQShortString queue, - final boolean noAck - ) + final int ticket, + final AMQShortString queue, + final boolean noAck + ) { - return new BasicGetBodyImpl( + return new BasicGetBody( ticket, queue, noAck @@ -799,14 +799,14 @@ public class MethodRegistry_0_9 extends MethodRegistry } public BasicGetOkBody createBasicGetOkBody( - final long deliveryTag, - final boolean redelivered, - final AMQShortString exchange, - final AMQShortString routingKey, - final long messageCount - ) - { - return new BasicGetOkBodyImpl( + final long deliveryTag, + final boolean redelivered, + final AMQShortString exchange, + final AMQShortString routingKey, + final long messageCount + ) + { + return new BasicGetOkBody( deliveryTag, redelivered, exchange, @@ -816,41 +816,41 @@ public class MethodRegistry_0_9 extends MethodRegistry } public BasicGetEmptyBody createBasicGetEmptyBody( - final AMQShortString clusterId - ) + final AMQShortString clusterId + ) { - return new BasicGetEmptyBodyImpl( + return new BasicGetEmptyBody( clusterId ); } public BasicAckBody createBasicAckBody( - final long deliveryTag, - final boolean multiple - ) + final long deliveryTag, + final boolean multiple + ) { - return new BasicAckBodyImpl( + return new BasicAckBody( deliveryTag, multiple ); } public BasicRejectBody createBasicRejectBody( - final long deliveryTag, - final boolean requeue - ) + final long deliveryTag, + final boolean requeue + ) { - return new BasicRejectBodyImpl( + return new BasicRejectBody( deliveryTag, requeue ); } public BasicRecoverBody createBasicRecoverBody( - final boolean requeue - ) + final boolean requeue + ) { - return new BasicRecoverBodyImpl( + return new BasicRecoverBody( requeue ); } @@ -872,44 +872,44 @@ public class MethodRegistry_0_9 extends MethodRegistry } public TxSelectBody createTxSelectBody( - ) + ) { - return new TxSelectBodyImpl( + return new TxSelectBody( ); } public TxSelectOkBody createTxSelectOkBody( - ) + ) { - return new TxSelectOkBodyImpl( + return new TxSelectOkBody( ); } public TxCommitBody createTxCommitBody( - ) + ) { - return new TxCommitBodyImpl( + return new TxCommitBody( ); } public TxCommitOkBody createTxCommitOkBody( - ) + ) { - return new TxCommitOkBodyImpl( + return new TxCommitOkBody( ); } public TxRollbackBody createTxRollbackBody( - ) + ) { - return new TxRollbackBodyImpl( + return new TxRollbackBody( ); } public TxRollbackOkBody createTxRollbackOkBody( - ) + ) { - return new TxRollbackOkBodyImpl( + return new TxRollbackOkBody( ); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/amqp_0_91/MethodConverter_0_91.java b/java/common/src/main/java/org/apache/qpid/framing/amqp_0_91/MethodConverter_0_91.java index 3977013581..d6a4a2e78a 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/amqp_0_91/MethodConverter_0_91.java +++ b/java/common/src/main/java/org/apache/qpid/framing/amqp_0_91/MethodConverter_0_91.java @@ -24,7 +24,6 @@ package org.apache.qpid.framing.amqp_0_91; import org.apache.qpid.framing.AMQMethodBody; import org.apache.qpid.framing.AMQShortString; import org.apache.qpid.framing.BasicPublishBody; -import org.apache.qpid.framing.BasicPublishBodyImpl; import org.apache.qpid.framing.abstraction.AbstractMethodConverter; import org.apache.qpid.framing.abstraction.MessagePublishInfo; import org.apache.qpid.framing.abstraction.MessagePublishInfoImpl; @@ -56,7 +55,7 @@ public class MethodConverter_0_91 extends AbstractMethodConverter implements Pro public AMQMethodBody convertToBody(MessagePublishInfo info) { - return new BasicPublishBodyImpl(0, + return new BasicPublishBody(0, info.getExchange(), info.getRoutingKey(), info.isMandatory(), diff --git a/java/common/src/main/java/org/apache/qpid/framing/amqp_0_91/MethodRegistry_0_91.java b/java/common/src/main/java/org/apache/qpid/framing/amqp_0_91/MethodRegistry_0_91.java index 00ec40f8cc..0e0b1502df 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/amqp_0_91/MethodRegistry_0_91.java +++ b/java/common/src/main/java/org/apache/qpid/framing/amqp_0_91/MethodRegistry_0_91.java @@ -62,14 +62,14 @@ public class MethodRegistry_0_91 extends MethodRegistry _factories[10] = new AMQMethodBodyInstanceFactory[52]; - _factories[10][10] = ConnectionStartBodyImpl.getFactory(); - _factories[10][11] = ConnectionStartOkBodyImpl.getFactory(); - _factories[10][20] = ConnectionSecureBodyImpl.getFactory(); - _factories[10][21] = ConnectionSecureOkBodyImpl.getFactory(); - _factories[10][30] = ConnectionTuneBodyImpl.getFactory(); - _factories[10][31] = ConnectionTuneOkBodyImpl.getFactory(); - _factories[10][40] = ConnectionOpenBodyImpl.getFactory(); - _factories[10][41] = ConnectionOpenOkBodyImpl.getFactory(); + _factories[10][10] = ConnectionStartBody.getFactory(); + _factories[10][11] = ConnectionStartOkBody.getFactory(); + _factories[10][20] = ConnectionSecureBody.getFactory(); + _factories[10][21] = ConnectionSecureOkBody.getFactory(); + _factories[10][30] = ConnectionTuneBody.getFactory(); + _factories[10][31] = ConnectionTuneOkBody.getFactory(); + _factories[10][40] = ConnectionOpenBody.getFactory(); + _factories[10][41] = ConnectionOpenOkBody.getFactory(); _factories[10][50] = ConnectionCloseBodyImpl.getFactory(); _factories[10][51] = ConnectionCloseOkBodyImpl.getFactory(); @@ -79,12 +79,12 @@ public class MethodRegistry_0_91 extends MethodRegistry _factories[20] = new AMQMethodBodyInstanceFactory[42]; - _factories[20][10] = ChannelOpenBodyImpl.getFactory(); + _factories[20][10] = ChannelOpenBody.getFactory(); _factories[20][11] = ChannelOpenOkBodyImpl.getFactory(); - _factories[20][20] = ChannelFlowBodyImpl.getFactory(); - _factories[20][21] = ChannelFlowOkBodyImpl.getFactory(); - _factories[20][40] = ChannelCloseBodyImpl.getFactory(); - _factories[20][41] = ChannelCloseOkBodyImpl.getFactory(); + _factories[20][20] = ChannelFlowBody.getFactory(); + _factories[20][21] = ChannelFlowOkBody.getFactory(); + _factories[20][40] = ChannelCloseBody.getFactory(); + _factories[20][41] = ChannelCloseOkBody.getFactory(); @@ -92,12 +92,12 @@ public class MethodRegistry_0_91 extends MethodRegistry _factories[40] = new AMQMethodBodyInstanceFactory[24]; - _factories[40][10] = ExchangeDeclareBodyImpl.getFactory(); - _factories[40][11] = ExchangeDeclareOkBodyImpl.getFactory(); - _factories[40][20] = ExchangeDeleteBodyImpl.getFactory(); - _factories[40][21] = ExchangeDeleteOkBodyImpl.getFactory(); - _factories[40][22] = ExchangeBoundBodyImpl.getFactory(); - _factories[40][23] = ExchangeBoundOkBodyImpl.getFactory(); + _factories[40][10] = ExchangeDeclareBody.getFactory(); + _factories[40][11] = ExchangeDeclareOkBody.getFactory(); + _factories[40][20] = ExchangeDeleteBody.getFactory(); + _factories[40][21] = ExchangeDeleteOkBody.getFactory(); + _factories[40][22] = ExchangeBoundBody.getFactory(); + _factories[40][23] = ExchangeBoundOkBody.getFactory(); @@ -105,14 +105,14 @@ public class MethodRegistry_0_91 extends MethodRegistry _factories[50] = new AMQMethodBodyInstanceFactory[52]; - _factories[50][10] = QueueDeclareBodyImpl.getFactory(); - _factories[50][11] = QueueDeclareOkBodyImpl.getFactory(); - _factories[50][20] = QueueBindBodyImpl.getFactory(); - _factories[50][21] = QueueBindOkBodyImpl.getFactory(); - _factories[50][30] = QueuePurgeBodyImpl.getFactory(); - _factories[50][31] = QueuePurgeOkBodyImpl.getFactory(); - _factories[50][40] = QueueDeleteBodyImpl.getFactory(); - _factories[50][41] = QueueDeleteOkBodyImpl.getFactory(); + _factories[50][10] = QueueDeclareBody.getFactory(); + _factories[50][11] = QueueDeclareOkBody.getFactory(); + _factories[50][20] = QueueBindBody.getFactory(); + _factories[50][21] = QueueBindOkBody.getFactory(); + _factories[50][30] = QueuePurgeBody.getFactory(); + _factories[50][31] = QueuePurgeOkBody.getFactory(); + _factories[50][40] = QueueDeleteBody.getFactory(); + _factories[50][41] = QueueDeleteOkBody.getFactory(); _factories[50][50] = QueueUnbindBodyImpl.getFactory(); _factories[50][51] = QueueUnbindOkBodyImpl.getFactory(); @@ -122,21 +122,21 @@ public class MethodRegistry_0_91 extends MethodRegistry _factories[60] = new AMQMethodBodyInstanceFactory[112]; - _factories[60][10] = BasicQosBodyImpl.getFactory(); - _factories[60][11] = BasicQosOkBodyImpl.getFactory(); - _factories[60][20] = BasicConsumeBodyImpl.getFactory(); - _factories[60][21] = BasicConsumeOkBodyImpl.getFactory(); - _factories[60][30] = BasicCancelBodyImpl.getFactory(); - _factories[60][31] = BasicCancelOkBodyImpl.getFactory(); - _factories[60][40] = BasicPublishBodyImpl.getFactory(); - _factories[60][50] = BasicReturnBodyImpl.getFactory(); - _factories[60][60] = BasicDeliverBodyImpl.getFactory(); - _factories[60][70] = BasicGetBodyImpl.getFactory(); - _factories[60][71] = BasicGetOkBodyImpl.getFactory(); - _factories[60][72] = BasicGetEmptyBodyImpl.getFactory(); - _factories[60][80] = BasicAckBodyImpl.getFactory(); - _factories[60][90] = BasicRejectBodyImpl.getFactory(); - _factories[60][100] = BasicRecoverBodyImpl.getFactory(); + _factories[60][10] = BasicQosBody.getFactory(); + _factories[60][11] = BasicQosOkBody.getFactory(); + _factories[60][20] = BasicConsumeBody.getFactory(); + _factories[60][21] = BasicConsumeOkBody.getFactory(); + _factories[60][30] = BasicCancelBody.getFactory(); + _factories[60][31] = BasicCancelOkBody.getFactory(); + _factories[60][40] = BasicPublishBody.getFactory(); + _factories[60][50] = BasicReturnBody.getFactory(); + _factories[60][60] = BasicDeliverBody.getFactory(); + _factories[60][70] = BasicGetBody.getFactory(); + _factories[60][71] = BasicGetOkBody.getFactory(); + _factories[60][72] = BasicGetEmptyBody.getFactory(); + _factories[60][80] = BasicAckBody.getFactory(); + _factories[60][90] = BasicRejectBody.getFactory(); + _factories[60][100] = BasicRecoverBody.getFactory(); _factories[60][110] = BasicRecoverSyncBodyImpl.getFactory(); _factories[60][111] = BasicRecoverSyncOkBodyImpl.getFactory(); @@ -146,12 +146,12 @@ public class MethodRegistry_0_91 extends MethodRegistry _factories[90] = new AMQMethodBodyInstanceFactory[32]; - _factories[90][10] = TxSelectBodyImpl.getFactory(); - _factories[90][11] = TxSelectOkBodyImpl.getFactory(); - _factories[90][20] = TxCommitBodyImpl.getFactory(); - _factories[90][21] = TxCommitOkBodyImpl.getFactory(); - _factories[90][30] = TxRollbackBodyImpl.getFactory(); - _factories[90][31] = TxRollbackOkBodyImpl.getFactory(); + _factories[90][10] = TxSelectBody.getFactory(); + _factories[90][11] = TxSelectOkBody.getFactory(); + _factories[90][20] = TxCommitBody.getFactory(); + _factories[90][21] = TxCommitOkBody.getFactory(); + _factories[90][30] = TxRollbackBody.getFactory(); + _factories[90][31] = TxRollbackOkBody.getFactory(); } public AMQMethodBody convertToBody(MarkableDataInput in, long size) @@ -212,14 +212,14 @@ public class MethodRegistry_0_91 extends MethodRegistry public ConnectionStartBody createConnectionStartBody( - final short versionMajor, - final short versionMinor, - final FieldTable serverProperties, - final byte[] mechanisms, - final byte[] locales - ) - { - return new ConnectionStartBodyImpl( + final short versionMajor, + final short versionMinor, + final FieldTable serverProperties, + final byte[] mechanisms, + final byte[] locales + ) + { + return new ConnectionStartBody( versionMajor, versionMinor, serverProperties, @@ -229,13 +229,13 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ConnectionStartOkBody createConnectionStartOkBody( - final FieldTable clientProperties, - final AMQShortString mechanism, - final byte[] response, - final AMQShortString locale - ) + final FieldTable clientProperties, + final AMQShortString mechanism, + final byte[] response, + final AMQShortString locale + ) { - return new ConnectionStartOkBodyImpl( + return new ConnectionStartOkBody( clientProperties, mechanism, response, @@ -244,30 +244,30 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ConnectionSecureBody createConnectionSecureBody( - final byte[] challenge - ) + final byte[] challenge + ) { - return new ConnectionSecureBodyImpl( + return new ConnectionSecureBody( challenge ); } public ConnectionSecureOkBody createConnectionSecureOkBody( - final byte[] response - ) + final byte[] response + ) { - return new ConnectionSecureOkBodyImpl( + return new ConnectionSecureOkBody( response ); } public ConnectionTuneBody createConnectionTuneBody( - final int channelMax, - final long frameMax, - final int heartbeat - ) + final int channelMax, + final long frameMax, + final int heartbeat + ) { - return new ConnectionTuneBodyImpl( + return new ConnectionTuneBody( channelMax, frameMax, heartbeat @@ -275,12 +275,12 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ConnectionTuneOkBody createConnectionTuneOkBody( - final int channelMax, - final long frameMax, - final int heartbeat - ) + final int channelMax, + final long frameMax, + final int heartbeat + ) { - return new ConnectionTuneOkBodyImpl( + return new ConnectionTuneOkBody( channelMax, frameMax, heartbeat @@ -288,12 +288,12 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ConnectionOpenBody createConnectionOpenBody( - final AMQShortString virtualHost, - final AMQShortString capabilities, - final boolean insist - ) + final AMQShortString virtualHost, + final AMQShortString capabilities, + final boolean insist + ) { - return new ConnectionOpenBodyImpl( + return new ConnectionOpenBody( virtualHost, capabilities, insist @@ -301,10 +301,10 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ConnectionOpenOkBody createConnectionOpenOkBody( - final AMQShortString knownHosts - ) + final AMQShortString knownHosts + ) { - return new ConnectionOpenOkBodyImpl( + return new ConnectionOpenOkBody( knownHosts ); } @@ -335,10 +335,10 @@ public class MethodRegistry_0_91 extends MethodRegistry public ChannelOpenBody createChannelOpenBody( - final AMQShortString outOfBand - ) + final AMQShortString outOfBand + ) { - return new ChannelOpenBodyImpl( + return new ChannelOpenBody( outOfBand ); } @@ -353,31 +353,31 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ChannelFlowBody createChannelFlowBody( - final boolean active - ) + final boolean active + ) { - return new ChannelFlowBodyImpl( + return new ChannelFlowBody( active ); } public ChannelFlowOkBody createChannelFlowOkBody( - final boolean active - ) + final boolean active + ) { - return new ChannelFlowOkBodyImpl( + return new ChannelFlowOkBody( active ); } public ChannelCloseBody createChannelCloseBody( - final int replyCode, - final AMQShortString replyText, - final int classId, - final int methodId - ) + final int replyCode, + final AMQShortString replyText, + final int classId, + final int methodId + ) { - return new ChannelCloseBodyImpl( + return new ChannelCloseBody( replyCode, replyText, classId, @@ -386,9 +386,9 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ChannelCloseOkBody createChannelCloseOkBody( - ) + ) { - return new ChannelCloseOkBodyImpl( + return new ChannelCloseOkBody( ); } @@ -396,18 +396,18 @@ public class MethodRegistry_0_91 extends MethodRegistry public ExchangeDeclareBody createExchangeDeclareBody( - final int ticket, - final AMQShortString exchange, - final AMQShortString type, - final boolean passive, - final boolean durable, - final boolean autoDelete, - final boolean internal, - final boolean nowait, - final FieldTable arguments - ) - { - return new ExchangeDeclareBodyImpl( + final int ticket, + final AMQShortString exchange, + final AMQShortString type, + final boolean passive, + final boolean durable, + final boolean autoDelete, + final boolean internal, + final boolean nowait, + final FieldTable arguments + ) + { + return new ExchangeDeclareBody( ticket, exchange, type, @@ -421,20 +421,20 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ExchangeDeclareOkBody createExchangeDeclareOkBody( - ) + ) { - return new ExchangeDeclareOkBodyImpl( + return new ExchangeDeclareOkBody( ); } public ExchangeDeleteBody createExchangeDeleteBody( - final int ticket, - final AMQShortString exchange, - final boolean ifUnused, - final boolean nowait - ) + final int ticket, + final AMQShortString exchange, + final boolean ifUnused, + final boolean nowait + ) { - return new ExchangeDeleteBodyImpl( + return new ExchangeDeleteBody( ticket, exchange, ifUnused, @@ -443,19 +443,19 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ExchangeDeleteOkBody createExchangeDeleteOkBody( - ) + ) { - return new ExchangeDeleteOkBodyImpl( + return new ExchangeDeleteOkBody( ); } public ExchangeBoundBody createExchangeBoundBody( - final AMQShortString exchange, - final AMQShortString routingKey, - final AMQShortString queue - ) + final AMQShortString exchange, + final AMQShortString routingKey, + final AMQShortString queue + ) { - return new ExchangeBoundBodyImpl( + return new ExchangeBoundBody( exchange, routingKey, queue @@ -463,11 +463,11 @@ public class MethodRegistry_0_91 extends MethodRegistry } public ExchangeBoundOkBody createExchangeBoundOkBody( - final int replyCode, - final AMQShortString replyText - ) + final int replyCode, + final AMQShortString replyText + ) { - return new ExchangeBoundOkBodyImpl( + return new ExchangeBoundOkBody( replyCode, replyText ); @@ -477,17 +477,17 @@ public class MethodRegistry_0_91 extends MethodRegistry public QueueDeclareBody createQueueDeclareBody( - final int ticket, - final AMQShortString queue, - final boolean passive, - final boolean durable, - final boolean exclusive, - final boolean autoDelete, - final boolean nowait, - final FieldTable arguments - ) - { - return new QueueDeclareBodyImpl( + final int ticket, + final AMQShortString queue, + final boolean passive, + final boolean durable, + final boolean exclusive, + final boolean autoDelete, + final boolean nowait, + final FieldTable arguments + ) + { + return new QueueDeclareBody( ticket, queue, passive, @@ -500,12 +500,12 @@ public class MethodRegistry_0_91 extends MethodRegistry } public QueueDeclareOkBody createQueueDeclareOkBody( - final AMQShortString queue, - final long messageCount, - final long consumerCount - ) + final AMQShortString queue, + final long messageCount, + final long consumerCount + ) { - return new QueueDeclareOkBodyImpl( + return new QueueDeclareOkBody( queue, messageCount, consumerCount @@ -513,15 +513,15 @@ public class MethodRegistry_0_91 extends MethodRegistry } public QueueBindBody createQueueBindBody( - final int ticket, - final AMQShortString queue, - final AMQShortString exchange, - final AMQShortString routingKey, - final boolean nowait, - final FieldTable arguments - ) - { - return new QueueBindBodyImpl( + final int ticket, + final AMQShortString queue, + final AMQShortString exchange, + final AMQShortString routingKey, + final boolean nowait, + final FieldTable arguments + ) + { + return new QueueBindBody( ticket, queue, exchange, @@ -532,19 +532,19 @@ public class MethodRegistry_0_91 extends MethodRegistry } public QueueBindOkBody createQueueBindOkBody( - ) + ) { - return new QueueBindOkBodyImpl( + return new QueueBindOkBody( ); } public QueuePurgeBody createQueuePurgeBody( - final int ticket, - final AMQShortString queue, - final boolean nowait - ) + final int ticket, + final AMQShortString queue, + final boolean nowait + ) { - return new QueuePurgeBodyImpl( + return new QueuePurgeBody( ticket, queue, nowait @@ -552,23 +552,23 @@ public class MethodRegistry_0_91 extends MethodRegistry } public QueuePurgeOkBody createQueuePurgeOkBody( - final long messageCount - ) + final long messageCount + ) { - return new QueuePurgeOkBodyImpl( + return new QueuePurgeOkBody( messageCount ); } public QueueDeleteBody createQueueDeleteBody( - final int ticket, - final AMQShortString queue, - final boolean ifUnused, - final boolean ifEmpty, - final boolean nowait - ) - { - return new QueueDeleteBodyImpl( + final int ticket, + final AMQShortString queue, + final boolean ifUnused, + final boolean ifEmpty, + final boolean nowait + ) + { + return new QueueDeleteBody( ticket, queue, ifUnused, @@ -578,10 +578,10 @@ public class MethodRegistry_0_91 extends MethodRegistry } public QueueDeleteOkBody createQueueDeleteOkBody( - final long messageCount - ) + final long messageCount + ) { - return new QueueDeleteOkBodyImpl( + return new QueueDeleteOkBody( messageCount ); } @@ -614,12 +614,12 @@ public class MethodRegistry_0_91 extends MethodRegistry public BasicQosBody createBasicQosBody( - final long prefetchSize, - final int prefetchCount, - final boolean global - ) + final long prefetchSize, + final int prefetchCount, + final boolean global + ) { - return new BasicQosBodyImpl( + return new BasicQosBody( prefetchSize, prefetchCount, global @@ -627,24 +627,24 @@ public class MethodRegistry_0_91 extends MethodRegistry } public BasicQosOkBody createBasicQosOkBody( - ) + ) { - return new BasicQosOkBodyImpl( + return new BasicQosOkBody( ); } public BasicConsumeBody createBasicConsumeBody( - final int ticket, - final AMQShortString queue, - final AMQShortString consumerTag, - final boolean noLocal, - final boolean noAck, - final boolean exclusive, - final boolean nowait, - final FieldTable arguments - ) - { - return new BasicConsumeBodyImpl( + final int ticket, + final AMQShortString queue, + final AMQShortString consumerTag, + final boolean noLocal, + final boolean noAck, + final boolean exclusive, + final boolean nowait, + final FieldTable arguments + ) + { + return new BasicConsumeBody( ticket, queue, consumerTag, @@ -657,43 +657,43 @@ public class MethodRegistry_0_91 extends MethodRegistry } public BasicConsumeOkBody createBasicConsumeOkBody( - final AMQShortString consumerTag - ) + final AMQShortString consumerTag + ) { - return new BasicConsumeOkBodyImpl( + return new BasicConsumeOkBody( consumerTag ); } public BasicCancelBody createBasicCancelBody( - final AMQShortString consumerTag, - final boolean nowait - ) + final AMQShortString consumerTag, + final boolean nowait + ) { - return new BasicCancelBodyImpl( + return new BasicCancelBody( consumerTag, nowait ); } public BasicCancelOkBody createBasicCancelOkBody( - final AMQShortString consumerTag - ) + final AMQShortString consumerTag + ) { - return new BasicCancelOkBodyImpl( + return new BasicCancelOkBody( consumerTag ); } public BasicPublishBody createBasicPublishBody( - final int ticket, - final AMQShortString exchange, - final AMQShortString routingKey, - final boolean mandatory, - final boolean immediate - ) - { - return new BasicPublishBodyImpl( + final int ticket, + final AMQShortString exchange, + final AMQShortString routingKey, + final boolean mandatory, + final boolean immediate + ) + { + return new BasicPublishBody( ticket, exchange, routingKey, @@ -703,13 +703,13 @@ public class MethodRegistry_0_91 extends MethodRegistry } public BasicReturnBody createBasicReturnBody( - final int replyCode, - final AMQShortString replyText, - final AMQShortString exchange, - final AMQShortString routingKey - ) + final int replyCode, + final AMQShortString replyText, + final AMQShortString exchange, + final AMQShortString routingKey + ) { - return new BasicReturnBodyImpl( + return new BasicReturnBody( replyCode, replyText, exchange, @@ -718,14 +718,14 @@ public class MethodRegistry_0_91 extends MethodRegistry } public BasicDeliverBody createBasicDeliverBody( - final AMQShortString consumerTag, - final long deliveryTag, - final boolean redelivered, - final AMQShortString exchange, - final AMQShortString routingKey - ) - { - return new BasicDeliverBodyImpl( + final AMQShortString consumerTag, + final long deliveryTag, + final boolean redelivered, + final AMQShortString exchange, + final AMQShortString routingKey + ) + { + return new BasicDeliverBody( consumerTag, deliveryTag, redelivered, @@ -735,12 +735,12 @@ public class MethodRegistry_0_91 extends MethodRegistry } public BasicGetBody createBasicGetBody( - final int ticket, - final AMQShortString queue, - final boolean noAck - ) + final int ticket, + final AMQShortString queue, + final boolean noAck + ) { - return new BasicGetBodyImpl( + return new BasicGetBody( ticket, queue, noAck @@ -748,14 +748,14 @@ public class MethodRegistry_0_91 extends MethodRegistry } public BasicGetOkBody createBasicGetOkBody( - final long deliveryTag, - final boolean redelivered, - final AMQShortString exchange, - final AMQShortString routingKey, - final long messageCount - ) - { - return new BasicGetOkBodyImpl( + final long deliveryTag, + final boolean redelivered, + final AMQShortString exchange, + final AMQShortString routingKey, + final long messageCount + ) + { + return new BasicGetOkBody( deliveryTag, redelivered, exchange, @@ -765,41 +765,41 @@ public class MethodRegistry_0_91 extends MethodRegistry } public BasicGetEmptyBody createBasicGetEmptyBody( - final AMQShortString clusterId - ) + final AMQShortString clusterId + ) { - return new BasicGetEmptyBodyImpl( + return new BasicGetEmptyBody( clusterId ); } public BasicAckBody createBasicAckBody( - final long deliveryTag, - final boolean multiple - ) + final long deliveryTag, + final boolean multiple + ) { - return new BasicAckBodyImpl( + return new BasicAckBody( deliveryTag, multiple ); } public BasicRejectBody createBasicRejectBody( - final long deliveryTag, - final boolean requeue - ) + final long deliveryTag, + final boolean requeue + ) { - return new BasicRejectBodyImpl( + return new BasicRejectBody( deliveryTag, requeue ); } public BasicRecoverBody createBasicRecoverBody( - final boolean requeue - ) + final boolean requeue + ) { - return new BasicRecoverBodyImpl( + return new BasicRecoverBody( requeue ); } @@ -824,44 +824,44 @@ public class MethodRegistry_0_91 extends MethodRegistry public TxSelectBody createTxSelectBody( - ) + ) { - return new TxSelectBodyImpl( + return new TxSelectBody( ); } public TxSelectOkBody createTxSelectOkBody( - ) + ) { - return new TxSelectOkBodyImpl( + return new TxSelectOkBody( ); } public TxCommitBody createTxCommitBody( - ) + ) { - return new TxCommitBodyImpl( + return new TxCommitBody( ); } public TxCommitOkBody createTxCommitOkBody( - ) + ) { - return new TxCommitOkBodyImpl( + return new TxCommitOkBody( ); } public TxRollbackBody createTxRollbackBody( - ) + ) { - return new TxRollbackBodyImpl( + return new TxRollbackBody( ); } public TxRollbackOkBody createTxRollbackOkBody( - ) + ) { - return new TxRollbackOkBodyImpl( + return new TxRollbackOkBody( ); } diff --git a/java/common/src/main/java/org/apache/qpid/framing/amqp_8_0/MethodConverter_8_0.java b/java/common/src/main/java/org/apache/qpid/framing/amqp_8_0/MethodConverter_8_0.java index 761c39172e..2432160001 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/amqp_8_0/MethodConverter_8_0.java +++ b/java/common/src/main/java/org/apache/qpid/framing/amqp_8_0/MethodConverter_8_0.java @@ -24,7 +24,6 @@ package org.apache.qpid.framing.amqp_8_0; import org.apache.qpid.framing.AMQMethodBody; import org.apache.qpid.framing.AMQShortString; import org.apache.qpid.framing.BasicPublishBody; -import org.apache.qpid.framing.BasicPublishBodyImpl; import org.apache.qpid.framing.abstraction.AbstractMethodConverter; import org.apache.qpid.framing.abstraction.MessagePublishInfo; import org.apache.qpid.framing.abstraction.MessagePublishInfoImpl; @@ -55,7 +54,7 @@ public class MethodConverter_8_0 extends AbstractMethodConverter implements Prot public AMQMethodBody convertToBody(MessagePublishInfo info) { - return new BasicPublishBodyImpl(0, + return new BasicPublishBody(0, info.getExchange(), info.getRoutingKey(), info.isMandatory(), diff --git a/java/common/src/main/java/org/apache/qpid/framing/amqp_8_0/MethodRegistry_8_0.java b/java/common/src/main/java/org/apache/qpid/framing/amqp_8_0/MethodRegistry_8_0.java index a4c901d19b..b075b84c55 100644 --- a/java/common/src/main/java/org/apache/qpid/framing/amqp_8_0/MethodRegistry_8_0.java +++ b/java/common/src/main/java/org/apache/qpid/framing/amqp_8_0/MethodRegistry_8_0.java @@ -62,14 +62,14 @@ public class MethodRegistry_8_0 extends MethodRegistry _factories[10] = new AMQMethodBodyInstanceFactory[62]; - _factories[10][10] = ConnectionStartBodyImpl.getFactory(); - _factories[10][11] = ConnectionStartOkBodyImpl.getFactory(); - _factories[10][20] = ConnectionSecureBodyImpl.getFactory(); - _factories[10][21] = ConnectionSecureOkBodyImpl.getFactory(); - _factories[10][30] = ConnectionTuneBodyImpl.getFactory(); - _factories[10][31] = ConnectionTuneOkBodyImpl.getFactory(); - _factories[10][40] = ConnectionOpenBodyImpl.getFactory(); - _factories[10][41] = ConnectionOpenOkBodyImpl.getFactory(); + _factories[10][10] = ConnectionStartBody.getFactory(); + _factories[10][11] = ConnectionStartOkBody.getFactory(); + _factories[10][20] = ConnectionSecureBody.getFactory(); + _factories[10][21] = ConnectionSecureOkBody.getFactory(); + _factories[10][30] = ConnectionTuneBody.getFactory(); + _factories[10][31] = ConnectionTuneOkBody.getFactory(); + _factories[10][40] = ConnectionOpenBody.getFactory(); + _factories[10][41] = ConnectionOpenOkBody.getFactory(); _factories[10][50] = ConnectionRedirectBodyImpl.getFactory(); _factories[10][60] = ConnectionCloseBodyImpl.getFactory(); _factories[10][61] = ConnectionCloseOkBodyImpl.getFactory(); @@ -80,13 +80,13 @@ public class MethodRegistry_8_0 extends MethodRegistry _factories[20] = new AMQMethodBodyInstanceFactory[42]; - _factories[20][10] = ChannelOpenBodyImpl.getFactory(); + _factories[20][10] = ChannelOpenBody.getFactory(); _factories[20][11] = ChannelOpenOkBodyImpl.getFactory(); - _factories[20][20] = ChannelFlowBodyImpl.getFactory(); - _factories[20][21] = ChannelFlowOkBodyImpl.getFactory(); + _factories[20][20] = ChannelFlowBody.getFactory(); + _factories[20][21] = ChannelFlowOkBody.getFactory(); _factories[20][30] = ChannelAlertBodyImpl.getFactory(); - _factories[20][40] = ChannelCloseBodyImpl.getFactory(); - _factories[20][41] = ChannelCloseOkBodyImpl.getFactory(); + _factories[20][40] = ChannelCloseBody.getFactory(); + _factories[20][41] = ChannelCloseOkBody.getFactory(); @@ -103,12 +103,12 @@ public class MethodRegistry_8_0 extends MethodRegistry _factories[40] = new AMQMethodBodyInstanceFactory[24]; - _factories[40][10] = ExchangeDeclareBodyImpl.getFactory(); - _factories[40][11] = ExchangeDeclareOkBodyImpl.getFactory(); - _factories[40][20] = ExchangeDeleteBodyImpl.getFactory(); - _factories[40][21] = ExchangeDeleteOkBodyImpl.getFactory(); - _factories[40][22] = ExchangeBoundBodyImpl.getFactory(); - _factories[40][23] = ExchangeBoundOkBodyImpl.getFactory(); + _factories[40][10] = ExchangeDeclareBody.getFactory(); + _factories[40][11] = ExchangeDeclareOkBody.getFactory(); + _factories[40][20] = ExchangeDeleteBody.getFactory(); + _factories[40][21] = ExchangeDeleteOkBody.getFactory(); + _factories[40][22] = ExchangeBoundBody.getFactory(); + _factories[40][23] = ExchangeBoundOkBody.getFactory(); @@ -116,14 +116,14 @@ public class MethodRegistry_8_0 extends MethodRegistry _factories[50] = new AMQMethodBodyInstanceFactory[42]; - _factories[50][10] = QueueDeclareBodyImpl.getFactory(); - _factories[50][11] = QueueDeclareOkBodyImpl.getFactory(); - _factories[50][20] = QueueBindBodyImpl.getFactory(); - _factories[50][21] = QueueBindOkBodyImpl.getFactory(); - _factories[50][30] = QueuePurgeBodyImpl.getFactory(); - _factories[50][31] = QueuePurgeOkBodyImpl.getFactory(); - _factories[50][40] = QueueDeleteBodyImpl.getFactory(); - _factories[50][41] = QueueDeleteOkBodyImpl.getFactory(); + _factories[50][10] = QueueDeclareBody.getFactory(); + _factories[50][11] = QueueDeclareOkBody.getFactory(); + _factories[50][20] = QueueBindBody.getFactory(); + _factories[50][21] = QueueBindOkBody.getFactory(); + _factories[50][30] = QueuePurgeBody.getFactory(); + _factories[50][31] = QueuePurgeOkBody.getFactory(); + _factories[50][40] = QueueDeleteBody.getFactory(); + _factories[50][41] = QueueDeleteOkBody.getFactory(); @@ -131,21 +131,21 @@ public class MethodRegistry_8_0 extends MethodRegistry _factories[60] = new AMQMethodBodyInstanceFactory[102]; - _factories[60][10] = BasicQosBodyImpl.getFactory(); - _factories[60][11] = BasicQosOkBodyImpl.getFactory(); - _factories[60][20] = BasicConsumeBodyImpl.getFactory(); - _factories[60][21] = BasicConsumeOkBodyImpl.getFactory(); - _factories[60][30] = BasicCancelBodyImpl.getFactory(); - _factories[60][31] = BasicCancelOkBodyImpl.getFactory(); - _factories[60][40] = BasicPublishBodyImpl.getFactory(); - _factories[60][50] = BasicReturnBodyImpl.getFactory(); - _factories[60][60] = BasicDeliverBodyImpl.getFactory(); - _factories[60][70] = BasicGetBodyImpl.getFactory(); - _factories[60][71] = BasicGetOkBodyImpl.getFactory(); - _factories[60][72] = BasicGetEmptyBodyImpl.getFactory(); - _factories[60][80] = BasicAckBodyImpl.getFactory(); - _factories[60][90] = BasicRejectBodyImpl.getFactory(); - _factories[60][100] = BasicRecoverBodyImpl.getFactory(); + _factories[60][10] = BasicQosBody.getFactory(); + _factories[60][11] = BasicQosOkBody.getFactory(); + _factories[60][20] = BasicConsumeBody.getFactory(); + _factories[60][21] = BasicConsumeOkBody.getFactory(); + _factories[60][30] = BasicCancelBody.getFactory(); + _factories[60][31] = BasicCancelOkBody.getFactory(); + _factories[60][40] = BasicPublishBody.getFactory(); + _factories[60][50] = BasicReturnBody.getFactory(); + _factories[60][60] = BasicDeliverBody.getFactory(); + _factories[60][70] = BasicGetBody.getFactory(); + _factories[60][71] = BasicGetOkBody.getFactory(); + _factories[60][72] = BasicGetEmptyBody.getFactory(); + _factories[60][80] = BasicAckBody.getFactory(); + _factories[60][90] = BasicRejectBody.getFactory(); + _factories[60][100] = BasicRecoverBody.getFactory(); _factories[60][101] = BasicRecoverOkBodyImpl.getFactory(); @@ -154,12 +154,12 @@ public class MethodRegistry_8_0 extends MethodRegistry _factories[90] = new AMQMethodBodyInstanceFactory[32]; - _factories[90][10] = TxSelectBodyImpl.getFactory(); - _factories[90][11] = TxSelectOkBodyImpl.getFactory(); - _factories[90][20] = TxCommitBodyImpl.getFactory(); - _factories[90][21] = TxCommitOkBodyImpl.getFactory(); - _factories[90][30] = TxRollbackBodyImpl.getFactory(); - _factories[90][31] = TxRollbackOkBodyImpl.getFactory(); + _factories[90][10] = TxSelectBody.getFactory(); + _factories[90][11] = TxSelectOkBody.getFactory(); + _factories[90][20] = TxCommitBody.getFactory(); + _factories[90][21] = TxCommitOkBody.getFactory(); + _factories[90][30] = TxRollbackBody.getFactory(); + _factories[90][31] = TxRollbackOkBody.getFactory(); } @@ -221,14 +221,14 @@ public class MethodRegistry_8_0 extends MethodRegistry public ConnectionStartBody createConnectionStartBody( - final short versionMajor, - final short versionMinor, - final FieldTable serverProperties, - final byte[] mechanisms, - final byte[] locales - ) - { - return new ConnectionStartBodyImpl( + final short versionMajor, + final short versionMinor, + final FieldTable serverProperties, + final byte[] mechanisms, + final byte[] locales + ) + { + return new ConnectionStartBody( versionMajor, versionMinor, serverProperties, @@ -238,13 +238,13 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ConnectionStartOkBody createConnectionStartOkBody( - final FieldTable clientProperties, - final AMQShortString mechanism, - final byte[] response, - final AMQShortString locale - ) + final FieldTable clientProperties, + final AMQShortString mechanism, + final byte[] response, + final AMQShortString locale + ) { - return new ConnectionStartOkBodyImpl( + return new ConnectionStartOkBody( clientProperties, mechanism, response, @@ -253,30 +253,30 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ConnectionSecureBody createConnectionSecureBody( - final byte[] challenge - ) + final byte[] challenge + ) { - return new ConnectionSecureBodyImpl( + return new ConnectionSecureBody( challenge ); } public ConnectionSecureOkBody createConnectionSecureOkBody( - final byte[] response - ) + final byte[] response + ) { - return new ConnectionSecureOkBodyImpl( + return new ConnectionSecureOkBody( response ); } public ConnectionTuneBody createConnectionTuneBody( - final int channelMax, - final long frameMax, - final int heartbeat - ) + final int channelMax, + final long frameMax, + final int heartbeat + ) { - return new ConnectionTuneBodyImpl( + return new ConnectionTuneBody( channelMax, frameMax, heartbeat @@ -284,12 +284,12 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ConnectionTuneOkBody createConnectionTuneOkBody( - final int channelMax, - final long frameMax, - final int heartbeat - ) + final int channelMax, + final long frameMax, + final int heartbeat + ) { - return new ConnectionTuneOkBodyImpl( + return new ConnectionTuneOkBody( channelMax, frameMax, heartbeat @@ -297,12 +297,12 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ConnectionOpenBody createConnectionOpenBody( - final AMQShortString virtualHost, - final AMQShortString capabilities, - final boolean insist - ) + final AMQShortString virtualHost, + final AMQShortString capabilities, + final boolean insist + ) { - return new ConnectionOpenBodyImpl( + return new ConnectionOpenBody( virtualHost, capabilities, insist @@ -310,10 +310,10 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ConnectionOpenOkBody createConnectionOpenOkBody( - final AMQShortString knownHosts - ) + final AMQShortString knownHosts + ) { - return new ConnectionOpenOkBodyImpl( + return new ConnectionOpenOkBody( knownHosts ); } @@ -355,10 +355,10 @@ public class MethodRegistry_8_0 extends MethodRegistry public ChannelOpenBody createChannelOpenBody( - final AMQShortString outOfBand - ) + final AMQShortString outOfBand + ) { - return new ChannelOpenBodyImpl( + return new ChannelOpenBody( outOfBand ); } @@ -371,19 +371,19 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ChannelFlowBody createChannelFlowBody( - final boolean active - ) + final boolean active + ) { - return new ChannelFlowBodyImpl( + return new ChannelFlowBody( active ); } public ChannelFlowOkBody createChannelFlowOkBody( - final boolean active - ) + final boolean active + ) { - return new ChannelFlowOkBodyImpl( + return new ChannelFlowOkBody( active ); } @@ -402,13 +402,13 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ChannelCloseBody createChannelCloseBody( - final int replyCode, - final AMQShortString replyText, - final int classId, - final int methodId - ) + final int replyCode, + final AMQShortString replyText, + final int classId, + final int methodId + ) { - return new ChannelCloseBodyImpl( + return new ChannelCloseBody( replyCode, replyText, classId, @@ -417,9 +417,9 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ChannelCloseOkBody createChannelCloseOkBody( - ) + ) { - return new ChannelCloseOkBodyImpl( + return new ChannelCloseOkBody( ); } @@ -458,18 +458,18 @@ public class MethodRegistry_8_0 extends MethodRegistry public ExchangeDeclareBody createExchangeDeclareBody( - final int ticket, - final AMQShortString exchange, - final AMQShortString type, - final boolean passive, - final boolean durable, - final boolean autoDelete, - final boolean internal, - final boolean nowait, - final FieldTable arguments - ) - { - return new ExchangeDeclareBodyImpl( + final int ticket, + final AMQShortString exchange, + final AMQShortString type, + final boolean passive, + final boolean durable, + final boolean autoDelete, + final boolean internal, + final boolean nowait, + final FieldTable arguments + ) + { + return new ExchangeDeclareBody( ticket, exchange, type, @@ -483,20 +483,20 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ExchangeDeclareOkBody createExchangeDeclareOkBody( - ) + ) { - return new ExchangeDeclareOkBodyImpl( + return new ExchangeDeclareOkBody( ); } public ExchangeDeleteBody createExchangeDeleteBody( - final int ticket, - final AMQShortString exchange, - final boolean ifUnused, - final boolean nowait - ) + final int ticket, + final AMQShortString exchange, + final boolean ifUnused, + final boolean nowait + ) { - return new ExchangeDeleteBodyImpl( + return new ExchangeDeleteBody( ticket, exchange, ifUnused, @@ -505,19 +505,19 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ExchangeDeleteOkBody createExchangeDeleteOkBody( - ) + ) { - return new ExchangeDeleteOkBodyImpl( + return new ExchangeDeleteOkBody( ); } public ExchangeBoundBody createExchangeBoundBody( - final AMQShortString exchange, - final AMQShortString routingKey, - final AMQShortString queue - ) + final AMQShortString exchange, + final AMQShortString routingKey, + final AMQShortString queue + ) { - return new ExchangeBoundBodyImpl( + return new ExchangeBoundBody( exchange, routingKey, queue @@ -525,11 +525,11 @@ public class MethodRegistry_8_0 extends MethodRegistry } public ExchangeBoundOkBody createExchangeBoundOkBody( - final int replyCode, - final AMQShortString replyText - ) + final int replyCode, + final AMQShortString replyText + ) { - return new ExchangeBoundOkBodyImpl( + return new ExchangeBoundOkBody( replyCode, replyText ); @@ -539,17 +539,17 @@ public class MethodRegistry_8_0 extends MethodRegistry public QueueDeclareBody createQueueDeclareBody( - final int ticket, - final AMQShortString queue, - final boolean passive, - final boolean durable, - final boolean exclusive, - final boolean autoDelete, - final boolean nowait, - final FieldTable arguments - ) - { - return new QueueDeclareBodyImpl( + final int ticket, + final AMQShortString queue, + final boolean passive, + final boolean durable, + final boolean exclusive, + final boolean autoDelete, + final boolean nowait, + final FieldTable arguments + ) + { + return new QueueDeclareBody( ticket, queue, passive, @@ -562,12 +562,12 @@ public class MethodRegistry_8_0 extends MethodRegistry } public QueueDeclareOkBody createQueueDeclareOkBody( - final AMQShortString queue, - final long messageCount, - final long consumerCount - ) + final AMQShortString queue, + final long messageCount, + final long consumerCount + ) { - return new QueueDeclareOkBodyImpl( + return new QueueDeclareOkBody( queue, messageCount, consumerCount @@ -575,15 +575,15 @@ public class MethodRegistry_8_0 extends MethodRegistry } public QueueBindBody createQueueBindBody( - final int ticket, - final AMQShortString queue, - final AMQShortString exchange, - final AMQShortString routingKey, - final boolean nowait, - final FieldTable arguments - ) - { - return new QueueBindBodyImpl( + final int ticket, + final AMQShortString queue, + final AMQShortString exchange, + final AMQShortString routingKey, + final boolean nowait, + final FieldTable arguments + ) + { + return new QueueBindBody( ticket, queue, exchange, @@ -594,19 +594,19 @@ public class MethodRegistry_8_0 extends MethodRegistry } public QueueBindOkBody createQueueBindOkBody( - ) + ) { - return new QueueBindOkBodyImpl( + return new QueueBindOkBody( ); } public QueuePurgeBody createQueuePurgeBody( - final int ticket, - final AMQShortString queue, - final boolean nowait - ) + final int ticket, + final AMQShortString queue, + final boolean nowait + ) { - return new QueuePurgeBodyImpl( + return new QueuePurgeBody( ticket, queue, nowait @@ -614,23 +614,23 @@ public class MethodRegistry_8_0 extends MethodRegistry } public QueuePurgeOkBody createQueuePurgeOkBody( - final long messageCount - ) + final long messageCount + ) { - return new QueuePurgeOkBodyImpl( + return new QueuePurgeOkBody( messageCount ); } public QueueDeleteBody createQueueDeleteBody( - final int ticket, - final AMQShortString queue, - final boolean ifUnused, - final boolean ifEmpty, - final boolean nowait - ) - { - return new QueueDeleteBodyImpl( + final int ticket, + final AMQShortString queue, + final boolean ifUnused, + final boolean ifEmpty, + final boolean nowait + ) + { + return new QueueDeleteBody( ticket, queue, ifUnused, @@ -640,10 +640,10 @@ public class MethodRegistry_8_0 extends MethodRegistry } public QueueDeleteOkBody createQueueDeleteOkBody( - final long messageCount - ) + final long messageCount + ) { - return new QueueDeleteOkBodyImpl( + return new QueueDeleteOkBody( messageCount ); } @@ -652,12 +652,12 @@ public class MethodRegistry_8_0 extends MethodRegistry public BasicQosBody createBasicQosBody( - final long prefetchSize, - final int prefetchCount, - final boolean global - ) + final long prefetchSize, + final int prefetchCount, + final boolean global + ) { - return new BasicQosBodyImpl( + return new BasicQosBody( prefetchSize, prefetchCount, global @@ -665,24 +665,24 @@ public class MethodRegistry_8_0 extends MethodRegistry } public BasicQosOkBody createBasicQosOkBody( - ) + ) { - return new BasicQosOkBodyImpl( + return new BasicQosOkBody( ); } public BasicConsumeBody createBasicConsumeBody( - final int ticket, - final AMQShortString queue, - final AMQShortString consumerTag, - final boolean noLocal, - final boolean noAck, - final boolean exclusive, - final boolean nowait, - final FieldTable arguments - ) - { - return new BasicConsumeBodyImpl( + final int ticket, + final AMQShortString queue, + final AMQShortString consumerTag, + final boolean noLocal, + final boolean noAck, + final boolean exclusive, + final boolean nowait, + final FieldTable arguments + ) + { + return new BasicConsumeBody( ticket, queue, consumerTag, @@ -695,43 +695,43 @@ public class MethodRegistry_8_0 extends MethodRegistry } public BasicConsumeOkBody createBasicConsumeOkBody( - final AMQShortString consumerTag - ) + final AMQShortString consumerTag + ) { - return new BasicConsumeOkBodyImpl( + return new BasicConsumeOkBody( consumerTag ); } public BasicCancelBody createBasicCancelBody( - final AMQShortString consumerTag, - final boolean nowait - ) + final AMQShortString consumerTag, + final boolean nowait + ) { - return new BasicCancelBodyImpl( + return new BasicCancelBody( consumerTag, nowait ); } public BasicCancelOkBody createBasicCancelOkBody( - final AMQShortString consumerTag - ) + final AMQShortString consumerTag + ) { - return new BasicCancelOkBodyImpl( + return new BasicCancelOkBody( consumerTag ); } public BasicPublishBody createBasicPublishBody( - final int ticket, - final AMQShortString exchange, - final AMQShortString routingKey, - final boolean mandatory, - final boolean immediate - ) - { - return new BasicPublishBodyImpl( + final int ticket, + final AMQShortString exchange, + final AMQShortString routingKey, + final boolean mandatory, + final boolean immediate + ) + { + return new BasicPublishBody( ticket, exchange, routingKey, @@ -741,13 +741,13 @@ public class MethodRegistry_8_0 extends MethodRegistry } public BasicReturnBody createBasicReturnBody( - final int replyCode, - final AMQShortString replyText, - final AMQShortString exchange, - final AMQShortString routingKey - ) + final int replyCode, + final AMQShortString replyText, + final AMQShortString exchange, + final AMQShortString routingKey + ) { - return new BasicReturnBodyImpl( + return new BasicReturnBody( replyCode, replyText, exchange, @@ -756,14 +756,14 @@ public class MethodRegistry_8_0 extends MethodRegistry } public BasicDeliverBody createBasicDeliverBody( - final AMQShortString consumerTag, - final long deliveryTag, - final boolean redelivered, - final AMQShortString exchange, - final AMQShortString routingKey - ) - { - return new BasicDeliverBodyImpl( + final AMQShortString consumerTag, + final long deliveryTag, + final boolean redelivered, + final AMQShortString exchange, + final AMQShortString routingKey + ) + { + return new BasicDeliverBody( consumerTag, deliveryTag, redelivered, @@ -773,12 +773,12 @@ public class MethodRegistry_8_0 extends MethodRegistry } public BasicGetBody createBasicGetBody( - final int ticket, - final AMQShortString queue, - final boolean noAck - ) + final int ticket, + final AMQShortString queue, + final boolean noAck + ) { - return new BasicGetBodyImpl( + return new BasicGetBody( ticket, queue, noAck @@ -786,14 +786,14 @@ public class MethodRegistry_8_0 extends MethodRegistry } public BasicGetOkBody createBasicGetOkBody( - final long deliveryTag, - final boolean redelivered, - final AMQShortString exchange, - final AMQShortString routingKey, - final long messageCount - ) - { - return new BasicGetOkBodyImpl( + final long deliveryTag, + final boolean redelivered, + final AMQShortString exchange, + final AMQShortString routingKey, + final long messageCount + ) + { + return new BasicGetOkBody( deliveryTag, redelivered, exchange, @@ -803,41 +803,41 @@ public class MethodRegistry_8_0 extends MethodRegistry } public BasicGetEmptyBody createBasicGetEmptyBody( - final AMQShortString clusterId - ) + final AMQShortString clusterId + ) { - return new BasicGetEmptyBodyImpl( + return new BasicGetEmptyBody( clusterId ); } public BasicAckBody createBasicAckBody( - final long deliveryTag, - final boolean multiple - ) + final long deliveryTag, + final boolean multiple + ) { - return new BasicAckBodyImpl( + return new BasicAckBody( deliveryTag, multiple ); } public BasicRejectBody createBasicRejectBody( - final long deliveryTag, - final boolean requeue - ) + final long deliveryTag, + final boolean requeue + ) { - return new BasicRejectBodyImpl( + return new BasicRejectBody( deliveryTag, requeue ); } public BasicRecoverBody createBasicRecoverBody( - final boolean requeue - ) + final boolean requeue + ) { - return new BasicRecoverBodyImpl( + return new BasicRecoverBody( requeue ); } @@ -851,44 +851,44 @@ public class MethodRegistry_8_0 extends MethodRegistry public TxSelectBody createTxSelectBody( - ) + ) { - return new TxSelectBodyImpl( + return new TxSelectBody( ); } public TxSelectOkBody createTxSelectOkBody( - ) + ) { - return new TxSelectOkBodyImpl( + return new TxSelectOkBody( ); } public TxCommitBody createTxCommitBody( - ) + ) { - return new TxCommitBodyImpl( + return new TxCommitBody( ); } public TxCommitOkBody createTxCommitOkBody( - ) + ) { - return new TxCommitOkBodyImpl( + return new TxCommitOkBody( ); } public TxRollbackBody createTxRollbackBody( - ) + ) { - return new TxRollbackBodyImpl( + return new TxRollbackBody( ); } public TxRollbackOkBody createTxRollbackOkBody( - ) + ) { - return new TxRollbackOkBodyImpl( + return new TxRollbackOkBody( ); } diff --git a/java/systests/src/test/java/org/apache/qpid/server/store/VirtualHostMessageStoreTest.java b/java/systests/src/test/java/org/apache/qpid/server/store/VirtualHostMessageStoreTest.java index ad3f2139b5..73ce5b9f05 100644 --- a/java/systests/src/test/java/org/apache/qpid/server/store/VirtualHostMessageStoreTest.java +++ b/java/systests/src/test/java/org/apache/qpid/server/store/VirtualHostMessageStoreTest.java @@ -38,11 +38,11 @@ import org.codehaus.jackson.map.ObjectMapper; import org.apache.qpid.common.AMQPFilterTypes; import org.apache.qpid.exchange.ExchangeDefaults; import org.apache.qpid.framing.AMQShortString; +import org.apache.qpid.framing.BasicConsumeBody; import org.apache.qpid.framing.BasicContentHeaderProperties; import org.apache.qpid.framing.ContentHeaderBody; import org.apache.qpid.framing.FieldTable; import org.apache.qpid.framing.abstraction.MessagePublishInfo; -import org.apache.qpid.framing.BasicConsumeBodyImpl; import org.apache.qpid.server.configuration.updater.TaskExecutor; import org.apache.qpid.server.configuration.updater.TaskExecutorImpl; import org.apache.qpid.server.connection.SessionPrincipal; @@ -599,7 +599,7 @@ public class VirtualHostMessageStoreTest extends QpidTestCase MessagePublishInfo messageInfo = new TestMessagePublishInfo(exchange, false, false, routingKey); - ContentHeaderBody headerBody = new ContentHeaderBody(BasicConsumeBodyImpl.CLASS_ID,0,properties,0l); + ContentHeaderBody headerBody = new ContentHeaderBody(BasicConsumeBody.CLASS_ID,0,properties,0l); MessageMetaData mmd = new MessageMetaData(messageInfo, headerBody, System.currentTimeMillis()); diff --git a/java/systests/src/test/java/org/apache/qpid/test/unit/close/JavaServerCloseRaceConditionTest.java b/java/systests/src/test/java/org/apache/qpid/test/unit/close/JavaServerCloseRaceConditionTest.java index b43fe35a09..3fe45143d5 100644 --- a/java/systests/src/test/java/org/apache/qpid/test/unit/close/JavaServerCloseRaceConditionTest.java +++ b/java/systests/src/test/java/org/apache/qpid/test/unit/close/JavaServerCloseRaceConditionTest.java @@ -86,8 +86,16 @@ public class JavaServerCloseRaceConditionTest extends QpidBrokerTestCase // Set no wait true so that we block the connection // Also set a different exchange class string so the attempt to declare // the exchange causes an exchange. - ExchangeDeclareBody body = session.getMethodRegistry().createExchangeDeclareBody(session.getTicket(), new AMQShortString(EXCHANGE_NAME), null, - true, false, false, false, true, null); + ExchangeDeclareBody body = session.getMethodRegistry().createExchangeDeclareBody(session.getTicket(), + new AMQShortString( + EXCHANGE_NAME), + null, + true, + false, + false, + false, + true, + null); AMQFrame exchangeDeclare = body.generateFrame(session.getChannelId()); diff --git a/java/systests/src/test/java/org/apache/qpid/transport/MaxFrameSizeTest.java b/java/systests/src/test/java/org/apache/qpid/transport/MaxFrameSizeTest.java index 74beb7cd58..639f53e0b6 100644 --- a/java/systests/src/test/java/org/apache/qpid/transport/MaxFrameSizeTest.java +++ b/java/systests/src/test/java/org/apache/qpid/transport/MaxFrameSizeTest.java @@ -54,8 +54,6 @@ import org.apache.qpid.framing.ConnectionCloseBody; import org.apache.qpid.framing.ConnectionStartOkBody; import org.apache.qpid.framing.ConnectionTuneOkBody; import org.apache.qpid.framing.FieldTable; -import org.apache.qpid.framing.ConnectionStartOkBodyImpl; -import org.apache.qpid.framing.ConnectionTuneOkBodyImpl; import org.apache.qpid.framing.amqp_0_91.MethodRegistry_0_91; import org.apache.qpid.jms.BrokerDetails; import org.apache.qpid.server.model.AuthenticationProvider; @@ -220,12 +218,12 @@ public class MaxFrameSizeTest extends QpidBrokerTestCase response[i++] = b; } - ConnectionStartOkBody startOK = new ConnectionStartOkBodyImpl(new FieldTable(), AMQShortString.valueOf("PLAIN"), response, AMQShortString.valueOf("en_US")); + ConnectionStartOkBody startOK = new ConnectionStartOkBody(new FieldTable(), AMQShortString.valueOf("PLAIN"), response, AMQShortString.valueOf("en_US")); DataOutputStream dos = new DataOutputStream(os); new AMQFrame(0, startOK).writePayload(dos); dos.flush(); - ConnectionTuneOkBody tuneOk = new ConnectionTuneOkBodyImpl(256, frameSize, 0); + ConnectionTuneOkBody tuneOk = new ConnectionTuneOkBody(256, frameSize, 0); new AMQFrame(0, tuneOk).writePayload(dos); dos.flush(); socket.setSoTimeout(5000); |