Loading...
Searching...
No Matches
disposition.h
Go to the documentation of this file.
#ifndef PROTON_DISPOSITION_H
#define PROTON_DISPOSITION_H 1
/*
*
* 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.
*
*/
#include <proton/import_export.h>
#include <proton/type_compat.h>
#include <proton/condition.h>
#include <stddef.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef struct pn_disposition_t pn_disposition_t;
#define PN_RECEIVED (0x0000000000000023)
#define PN_ACCEPTED (0x0000000000000024)
#define PN_REJECTED (0x0000000000000025)
#define PN_RELEASED (0x0000000000000026)
#define PN_MODIFIED (0x0000000000000027)
PN_EXTERN uint64_t pn_disposition_type(pn_disposition_t *disposition);
PN_EXTERN const char *pn_disposition_type_name(uint64_t disposition_type);
PN_EXTERN pn_condition_t *pn_disposition_condition(pn_disposition_t *disposition);
PN_EXTERN pn_data_t *pn_disposition_data(pn_disposition_t *disposition);
PN_EXTERN uint32_t pn_disposition_get_section_number(pn_disposition_t *disposition);
PN_EXTERN void pn_disposition_set_section_number(pn_disposition_t *disposition, uint32_t section_number);
PN_EXTERN uint64_t pn_disposition_get_section_offset(pn_disposition_t *disposition);
PN_EXTERN void pn_disposition_set_section_offset(pn_disposition_t *disposition, uint64_t section_offset);
PN_EXTERN bool pn_disposition_is_failed(pn_disposition_t *disposition);
PN_EXTERN void pn_disposition_set_failed(pn_disposition_t *disposition, bool failed);
PN_EXTERN bool pn_disposition_is_undeliverable(pn_disposition_t *disposition);
PN_EXTERN void pn_disposition_set_undeliverable(pn_disposition_t *disposition, bool undeliverable);
PN_EXTERN pn_data_t *pn_disposition_annotations(pn_disposition_t *disposition);
#ifdef __cplusplus
}
#endif
#endif /* disposition.h */
condition.h
An endpoint error state.
pn_condition_t
struct pn_condition_t pn_condition_t
An AMQP Condition object.
Definition condition.h:64
pn_data_t
struct pn_data_t pn_data_t
An AMQP Data object.
Definition codec.h:375
pn_disposition_set_section_number
void pn_disposition_set_section_number(pn_disposition_t *disposition, uint32_t section_number)
Set the section number associated with a disposition.
pn_disposition_type
uint64_t pn_disposition_type(pn_disposition_t *disposition)
Get the type of a disposition.
pn_disposition_t
struct pn_disposition_t pn_disposition_t
A delivery state.
Definition disposition.h:52
pn_disposition_type_name
const char * pn_disposition_type_name(uint64_t disposition_type)
Name of a disposition type for logging and debugging: "received", "accepted" etc.
pn_disposition_set_section_offset
void pn_disposition_set_section_offset(pn_disposition_t *disposition, uint64_t section_offset)
Set the section offset associated with a disposition.
pn_disposition_get_section_number
uint32_t pn_disposition_get_section_number(pn_disposition_t *disposition)
Get the section number associated with a disposition.
pn_disposition_is_failed
bool pn_disposition_is_failed(pn_disposition_t *disposition)
Check if a disposition has the failed flag set.
pn_disposition_get_section_offset
uint64_t pn_disposition_get_section_offset(pn_disposition_t *disposition)
Get the section offset associated with a disposition.
pn_disposition_set_failed
void pn_disposition_set_failed(pn_disposition_t *disposition, bool failed)
Set the failed flag on a disposition.
pn_disposition_set_undeliverable
void pn_disposition_set_undeliverable(pn_disposition_t *disposition, bool undeliverable)
Set the undeliverable flag on a disposition.
pn_disposition_condition
pn_condition_t * pn_disposition_condition(pn_disposition_t *disposition)
Access the condition object associated with a disposition.
pn_disposition_annotations
pn_data_t * pn_disposition_annotations(pn_disposition_t *disposition)
Access the annotations associated with a disposition.
pn_disposition_data
pn_data_t * pn_disposition_data(pn_disposition_t *disposition)
Access the disposition as a raw pn_data_t.
pn_disposition_is_undeliverable
bool pn_disposition_is_undeliverable(pn_disposition_t *disposition)
Check if a disposition has the undeliverable flag set.