-
Notifications
You must be signed in to change notification settings - Fork 174
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[core] prepare api for ecal6 #1399
Conversation
C API subscriber functions eCAL_Sub_GetTypeName and eCAL_Sub_GetEncoding added C publisher/subscriber callback structures SPubEventCallbackDataC and SSubEventCallbackDataC completed with tname, tencoding and tdesc
ecal_event samples removed (we should not demonstrate deprecated api)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang-tidy made some suggestions
@@ -27,6 +27,8 @@ | |||
#include <ecal/ecal_os.h> | |||
#include <ecal/ecal_deprecate.h> | |||
#include <ecal/types/monitoring.h> | |||
#include <ecal/ecal_deprecate.h> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: duplicate include [readability-duplicate-include]
ecal/core/include/ecal/ecal_monitoring.h:28:
- #include <ecal/types/monitoring.h>
- #include <ecal/ecal_deprecate.h>
+ #include <ecal/types/monitoring.h>
if (handle_ == nullptr) return(0); | ||
auto* sub = static_cast<eCAL::CSubscriber*>(handle_); | ||
const eCAL::SDataTypeInformation datatype_info = sub->GetDataTypeInformation(); | ||
int buffer_len = CopyBuffer(buf_, buf_len_, datatype_info.name); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: variable 'buffer_len' of type 'int' can be declared 'const' [misc-const-correctness]
int buffer_len = CopyBuffer(buf_, buf_len_, datatype_info.name); | |
int const buffer_len = CopyBuffer(buf_, buf_len_, datatype_info.name); |
if (handle_ == nullptr) return(0); | ||
auto* sub = static_cast<eCAL::CSubscriber*>(handle_); | ||
const eCAL::SDataTypeInformation datatype_info = sub->GetDataTypeInformation(); | ||
int buffer_len = CopyBuffer(buf_, buf_len_, datatype_info.encoding); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: variable 'buffer_len' of type 'int' can be declared 'const' [misc-const-correctness]
int buffer_len = CopyBuffer(buf_, buf_len_, datatype_info.encoding); | |
int const buffer_len = CopyBuffer(buf_, buf_len_, datatype_info.encoding); |
if (handle_ == nullptr) return(0); | ||
auto* sub = static_cast<eCAL::CSubscriber*>(handle_); | ||
const eCAL::SDataTypeInformation datatype_info = sub->GetDataTypeInformation(); | ||
int buffer_len = CopyBuffer(buf_, buf_len_, datatype_info.descriptor); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: variable 'buffer_len' of type 'int' can be declared 'const' [misc-const-correctness]
int buffer_len = CopyBuffer(buf_, buf_len_, datatype_info.descriptor); | |
int const buffer_len = CopyBuffer(buf_, buf_len_, datatype_info.descriptor); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Description
All API functions (C & C++) deprecated that are no longer part of the future eCAL6 API.
deprecated header files:
deprecated API:
ecal_callback_cimpl.h:
ecal_client_cimpl.h:
int eCAL_Client_AddResponseCallbackC(ECAL_HANDLE handle_, ResponseCallbackCT callback_, void* par_);
ecal_init_cimpl.h:
ecal_log_cimpl.h:
void eCAL_Logging_StartCoreTimer();
void eCAL_Logging_StopCoreTimer();
void eCAL_Logging_SetCoreTime(double time_);
double eCAL_Logging_GetCoreTime();
ecal_process_cimpl.h:
int eCAL_Process_GetHostID();
float eCAL_Process_GetProcessCpuUsage();
unsigned long eCAL_Process_GetProcessMemory();
long long eCAL_Process_GetSClock();
long long eCAL_Process_GetSBytes();
long long eCAL_Process_GetWClock();
long long eCAL_Process_GetWBytes();
long long eCAL_Process_GetRClock();
long long eCAL_Process_GetRBytes();
ecal_publisher_cimpl.h:
int eCAL_Pub_SetQOS(ECAL_HANDLE handle_, struct SWriterQOSC qos_);
int eCAL_Pub_GetQOS(ECAL_HANDLE handle_, struct SWriterQOSC* qos_);
int eCAL_Pub_SetMaxBandwidthUDP(ECAL_HANDLE handle_, long bandwidth_);
ecal_server_cimpl.h:
int eCAL_Server_AddMethodCallbackC(ECAL_HANDLE handle_, const char* method_, const char* req_type_, const char* resp_type_, MethodCallbackCT callback_, void* par_);
int eCAL_Server_RemMethodCallbackC(ECAL_HANDLE handle_, const char* method_);
ecal_subscriber_cimpl.h:
int eCAL_Sub_SetQOS(ECAL_HANDLE handle_, struct SReaderQOSC qos_);
int eCAL_Sub_GetQOS(ECAL_HANDLE handle_, struct SReaderQOSC* qos_);
int eCAL_Sub_SetTimeout(ECAL_HANDLE handle_, int timeout_);
ecal_tlayer_cimpl.h:
ecal_log.h:
void StartCoreTimer();
void StopCoreTimer();
void SetCoreTime(double time_);
double GetCoreTime();
ecal_monitoring.h:
int GetMonitoring(std::string& mon_);
ecal_process.h:
int GetHostID();
float GetProcessCpuUsage();
unsigned long GetProcessMemory();
long long GetWClock();
long long GetWBytes();
long long GetRClock();
long long GetRBytes();
ecal_publisher.h:
bool SetQOS(const QOS::SWriterQOS& qos_);
QOS::SWriterQOS GetQOS();
bool SetMaxBandwidthUDP(long bandwidth_);
ecal_subscriber.h:
bool SetQOS(const QOS::SReaderQOS& qos_);
QOS::SReaderQOS GetQOS();
bool SetTimeout(int timeout_);
ecal_tlayer.h:
added API:
ecal_subscriber_cimpl.h:
ECALC_API int eCAL_Sub_GetTypeName(ECAL_HANDLE handle_, void* buf_, int buf_len_);
ECALC_API int eCAL_Sub_GetEncoding(ECAL_HANDLE handle_, void* buf_, int buf_len_);
ecal_util_cimpl.h:
ECALC_API int eCAL_Util_GetTopicEncoding(const char* topic_name_, void* topic_encoding_, int topic_encoding_len_);
ECALC_API int eCAL_Util_GetTopicDescription(const char* topic_name_, void* topic_desc_, int topic_desc_len_);