BLPAPI C++ 3.26.5
Loading...
Searching...
No Matches
blpapi_zfputil.h
Go to the documentation of this file.
1/* Copyright 2018. Bloomberg Finance L.P.
2 *
3 * Permission is hereby granted, free of charge, to any person obtaining a copy
4 * of this software and associated documentation files (the "Software"), to
5 * deal in the Software without restriction, including without limitation the
6 * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
7 * sell copies of the Software, and to permit persons to whom the Software is
8 * furnished to do so, subject to the following conditions: The above
9 * copyright notice and this permission notice shall be included in all copies
10 * or substantial portions of the Software.
11 *
12 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
13 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
14 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
15 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
16 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
17 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
18 * IN THE SOFTWARE.
19 */
20
35
36#ifndef INCLUDED_BLPAPI_ZFPUTIL
37#define INCLUDED_BLPAPI_ZFPUTIL
38
90
93
94#ifndef INCLUDED_BLPAPI_ABSTRACTSESSION
96#endif
97
98#ifndef INCLUDED_BLPAPI_CALL
99#include <blpapi_call.h>
100#endif
101
102#ifndef INCLUDED_BLPAPI_EXCEPTION
103#include <blpapi_exception.h>
104#endif
105
106#ifndef INCLUDED_BLPAPI_DEFS
107#include <blpapi_defs.h>
108#endif
109
110#ifndef INCLUDED_BLPAPI_SESSIONOPTIONS
112#endif
113
114#ifndef INCLUDED_BLPAPI_TLSOPTIONS
115#include <blpapi_tlsoptions.h>
116#endif
117
118#ifndef INCLUDED_BLPAPI_VERSIONMACROS
119#include <blpapi_versionmacros.h>
120#endif
121
122#ifdef __cplusplus
123extern "C" {
124#endif
125
127
130
131BLPAPI_EXPORT
132int blpapi_ZfpUtil_getOptionsForLeasedLines(
133 blpapi_SessionOptions_t *sessionOptions,
134 const blpapi_TlsOptions_t *tlsOptions,
135 int remote);
136
139
140#ifdef __cplusplus
141}
142
149
150namespace BloombergLP {
151namespace blpapi {
152
159class ZfpUtil {
160
161 public:
162 enum Remote {
163 REMOTE_8194 = BLPAPI_ZFPUTIL_REMOTE_8194,
164 REMOTE_8196 = BLPAPI_ZFPUTIL_REMOTE_8196
165 };
166
168 Remote remote, const TlsOptions& tlsOptions);
179};
180
183
184// ============================================================================
185// INLINE FUNCTION DEFINITIONS
186// ============================================================================
187
188// -------------
189// class ZfpUtil
190// -------------
192 Remote remote, const TlsOptions& tlsOptions)
193{
194 // Ignore the return value
195 BLPAPI_CALL(blpapi_UserAgentInfo_setNativeSdkLanguageAndVersion)
196 ("C++", BLPAPI_SDK_VERSION_STRING);
197
200 BLPAPI_CALL(blpapi_ZfpUtil_getOptionsForLeasedLines)(
201 so.handle(), tlsOptions.handle(), remote));
202 return so;
203}
204
205} // close namespace blpapi
206} // close namespace BloombergLP
207
208#endif // #ifdef __cplusplus
209#endif // #ifndef INCLUDED_BLPAPI_ZFPUTIL
A common interface shared between publisher and consumer sessions.
Provide functions for dispatchtbl.
#define BLPAPI_CALL(FUNCNAME)
Definition blpapi_call.h:361
Common definitions used by the library.
Defines Exceptions that can be thrown by the blpapi library.
A common interface shared between publish and consumer sessions.
Maintain client credentials and trust material.
Provide preprocessor macros for BLPAPI library version information.
static void throwOnError(int errorCode)
Definition blpapi_exception.h:541
Definition blpapi_sessionoptions.h:447
blpapi_SessionOptions_t * handle() const
Definition blpapi_sessionoptions.h:1416
Definition blpapi_tlsoptions.h:204
blpapi_TlsOptions_t * handle() const
Definition blpapi_tlsoptions.h:360
Definition blpapi_zfputil.h:159
Remote
Definition blpapi_zfputil.h:162
@ REMOTE_8196
Use port 8196.
Definition blpapi_zfputil.h:164
@ REMOTE_8194
Use port 8194.
Definition blpapi_zfputil.h:163
static SessionOptions getZfpOptionsForLeasedLines(Remote remote, const TlsOptions &tlsOptions)
Definition blpapi_zfputil.h:191
Definition blpapi_abstractsession.h:212
Definition blpapi_abstractsession.h:211