Apache Qpid - AMQP Messaging for Java JMS, C++, Python, Ruby, and .NET
Apache Qpid Documentation
Main Page
Modules
Namespaces
Classes
Files
File List
File Members
qpid
framing
ExchangeQueryResult.h
Go to the documentation of this file.
1
#ifndef QPID_FRAMING_EXCHANGEQUERYRESULT_H
2
#define QPID_FRAMING_EXCHANGEQUERYRESULT_H
3
/*
4
*
5
* Licensed to the Apache Software Foundation (ASF) under one
6
* or more contributor license agreements. See the NOTICE file
7
* distributed with this work for additional information
8
* regarding copyright ownership. The ASF licenses this file
9
* to you under the Apache License, Version 2.0 (the
10
* "License"); you may not use this file except in compliance
11
* with the License. You may obtain a copy of the License at
12
*
13
* http://www.apache.org/licenses/LICENSE-2.0
14
*
15
* Unless required by applicable law or agreed to in writing,
16
* software distributed under the License is distributed on an
17
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
18
* KIND, either express or implied. See the License for the
19
* specific language governing permissions and limitations
20
* under the License.
21
*
22
*/
23
28
29
30
31
#include <ostream>
32
#include "
qpid/framing/amqp_types_full.h
"
33
#include "
qpid/framing/reply_exceptions.h
"
34
#include "
qpid/CommonImportExport.h
"
35
36
namespace
qpid {
37
namespace
framing {
38
39
class
QPID_COMMON_CLASS_EXTERN
ExchangeQueryResult
{
40
std::string type;
41
FieldTable
arguments;
42
uint16_t
flags;
43
public
:
44
static
const
uint16_t
TYPE = 1793;
45
ExchangeQueryResult
(
46
const
std::string& _type,
47
bool
_durable,
48
bool
_notFound,
49
const
FieldTable
& _arguments) :
50
type(_type),
51
arguments(_arguments),
52
flags(0){
53
setDurable(_durable);
54
setNotFound(_notFound);
55
flags |= (1 << 8);
56
flags |= (1 << 11);
57
if
(type.size() >= 256)
throw
IllegalArgumentException
(
"Value for type is too large"
);
58
}
59
ExchangeQueryResult
() : flags(0) {}
60
61
QPID_COMMON_EXTERN
void
setType(
const
std::string& _type);
62
QPID_COMMON_EXTERN
const
std::string& getType()
const
;
63
QPID_COMMON_EXTERN
bool
hasType()
const
;
64
QPID_COMMON_EXTERN
void
clearTypeFlag();
65
QPID_COMMON_EXTERN
void
setDurable(
bool
_durable);
66
QPID_COMMON_EXTERN
bool
getDurable()
const
;
67
QPID_COMMON_EXTERN
void
setNotFound(
bool
_notFound);
68
QPID_COMMON_EXTERN
bool
getNotFound()
const
;
69
QPID_COMMON_EXTERN
void
setArguments(
const
FieldTable
& _arguments);
70
QPID_COMMON_EXTERN
const
FieldTable
& getArguments()
const
;
71
QPID_COMMON_EXTERN
FieldTable
& getArguments();
72
QPID_COMMON_EXTERN
bool
hasArguments()
const
;
73
QPID_COMMON_EXTERN
void
clearArgumentsFlag();
74
QPID_COMMON_EXTERN
friend
std::ostream&
operator<<
(std::ostream&,
const
ExchangeQueryResult
&);
75
QPID_COMMON_EXTERN
void
encode
(
Buffer
&)
const
;
76
QPID_COMMON_EXTERN
void
decode
(
Buffer
&,
uint32_t
=0);
77
QPID_COMMON_EXTERN
void
encodeStructBody(
Buffer
&)
const
;
78
QPID_COMMON_EXTERN
void
decodeStructBody(
Buffer
&,
uint32_t
=0);
79
QPID_COMMON_EXTERN
uint32_t
encodedSize()
const
;
80
QPID_COMMON_EXTERN
uint32_t
bodySize()
const
;
81
QPID_COMMON_EXTERN
void
print(std::ostream& out)
const
;
82
};
/* class ExchangeQueryResult */
83
84
}}
85
#endif
Qpid C++ API Reference
Generated on Tue Mar 26 2013 for Qpid C++ Client API by
1.8.3.1