cafe-1.12.5 release

This commit is contained in:
2021-03-16 09:30:56 +01:00
parent 7504b0a539
commit 7ba4128448
106 changed files with 185064 additions and 183247 deletions

View File

@@ -13,7 +13,8 @@
#include <string>
#include <map>
enum CAFE_DATATYPE {
enum CAFE_DATATYPE
{
CAFE_TYPENOTCONN = TYPENOTCONN, // -1 val returned by ca_field_type when channel not connected
CAFE_STRING = DBF_STRING, // 0
CAFE_SHORT = DBF_SHORT, // 1
@@ -34,7 +35,8 @@ enum CAFE_DATATYPE {
* Provides methods to convert between
* the CAFE_DATATYPES and text equivalent
*/
class CAFEDataTypeCode {
class CAFEDataTypeCode
{
typedef std::map<int, std::string> mapLongString;
private:
mapLongString mapDataType;
@@ -97,12 +99,13 @@ public:
void print ( )
{
std::cout << "------------------" << std::endl;
std::cout << "CAFE_DATATYPE LIST" << std::endl;
std::cout << "-----------------" << std::endl;
for (pos=mapDataType.begin(); pos != mapDataType.end(); ++pos) {
std::cout << "CAFE_DATATYPE LIST" << std::endl;
std::cout << "------------------" << std::endl;
for (pos=mapDataType.begin(); pos != mapDataType.end(); ++pos)
{
std::cout << pos->first << " " << pos->second << std::endl;
}
std::cout << "-----------------" << std::endl;
std::cout << "------------------" << std::endl;
};
};
@@ -110,7 +113,8 @@ public:
/**
* A union of CAFE primitive datatypes
*/
union CAFE_DATATYPE_UNION {
union CAFE_DATATYPE_UNION
{
dbr_string_t str;
dbr_short_t s;
dbr_float_t f;
@@ -124,4 +128,5 @@ typedef CAFE_DATATYPE_UNION * CAFE_DATATYPE_UNION_SEQ;
#endif