]> git.proxmox.com Git - ceph.git/blame - ceph/src/jaegertracing/thrift/lib/c_glib/src/thrift/c_glib/transport/thrift_framed_transport_factory.h
update source to Ceph Pacific 16.2.2
[ceph.git] / ceph / src / jaegertracing / thrift / lib / c_glib / src / thrift / c_glib / transport / thrift_framed_transport_factory.h
CommitLineData
f67539c2
TL
1/*
2 * Licensed to the Apache Software Foundation (ASF) under one
3 * or more contributor license agreements. See the NOTICE file
4 * distributed with this work for additional information
5 * regarding copyright ownership. The ASF licenses this file
6 * to you under the Apache License, Version 2.0 (the
7 * "License"); you may not use this file except in compliance
8 * with the License. You may obtain a copy of the License at
9 *
10 * http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing,
13 * software distributed under the License is distributed on an
14 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15 * KIND, either express or implied. See the License for the
16 * specific language governing permissions and limitations
17 * under the License.
18 */
19
20#ifndef _THRIFT_FRAMED_TRANSPORT_FACTORY_H
21#define _THRIFT_FRAMED_TRANSPORT_FACTORY_H
22
23#include <glib-object.h>
24
25#include <thrift/c_glib/transport/thrift_transport.h>
26#include <thrift/c_glib/transport/thrift_transport_factory.h>
27
28G_BEGIN_DECLS
29
30/*! \file thrift_framed_transport_factory.h
31 * \brief Wraps a transport with a ThriftFramedTransport.
32 */
33
34/* type macros */
35#define THRIFT_TYPE_FRAMED_TRANSPORT_FACTORY \
36 (thrift_framed_transport_factory_get_type ())
37#define THRIFT_FRAMED_TRANSPORT_FACTORY(obj) \
38 (G_TYPE_CHECK_INSTANCE_CAST ((obj), \
39 THRIFT_TYPE_FRAMED_TRANSPORT_FACTORY, \
40 ThriftFramedTransportFactory))
41#define THRIFT_IS_FRAMED_TRANSPORT_FACTORY(obj) \
42 (G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
43 THRIFT_TYPE_FRAMED_TRANSPORT_FACTORY))
44#define THRIFT_FRAMED_TRANSPORT_FACTORY_CLASS(c) \
45 (G_TYPE_CHECK_CLASS_CAST ((c), \
46 THRIFT_TYPE_FRAMED_TRANSPORT_FACTORY, \
47 ThriftFramedTransportFactoryClass))
48#define THRIFT_IS_FRAMED_TRANSPORT_FACTORY_CLASS(c) \
49 (G_TYPE_CHECK_CLASS_TYPE ((c), \
50 THRIFT_TYPE_FRAMED_TRANSPORT_FACTORY))
51#define THRIFT_FRAMED_TRANSPORT_FACTORY_GET_CLASS(obj) \
52 (G_TYPE_INSTANCE_GET_CLASS ((obj), \
53 THRIFT_TYPE_FRAMED_TRANSPORT_FACTORY, \
54 ThriftFramedTransportFactoryClass))
55
56typedef struct _ThriftFramedTransportFactory ThriftFramedTransportFactory;
57
58/* Thrift Framed-Transport Factory instance */
59struct _ThriftFramedTransportFactory
60{
61 ThriftTransportFactory parent;
62};
63
64typedef struct _ThriftFramedTransportFactoryClass ThriftFramedTransportFactoryClass;
65
66/* Thrift Framed-Transport Factory class */
67struct _ThriftFramedTransportFactoryClass
68{
69 ThriftTransportFactoryClass parent;
70
71 /* vtable */
72 ThriftTransport *(*get_transport) (ThriftTransportFactory *factory,
73 ThriftTransport *transport);
74};
75
76/* used by THRIFT_TYPE_FRAMED_TRANSPORT_FACTORY */
77GType thrift_framed_transport_factory_get_type (void);
78
79/* virtual public methods */
80ThriftTransport *
81thrift_framed_transport_factory_get_transport (ThriftTransportFactory *factory,
82 ThriftTransport *transport);
83
84G_END_DECLS
85
86#endif /* _THRIFT_FRAMED_TRANSPORT_FACTORY_H */