RoadLogEvent.h
Go to the documentation of this file.
1 /****************************************************************************
2 **
3 ** Copyright (c) 2008-2015 C.B. Barber. All rights reserved.
4 ** $Id: //main/2015/qhull/src/libqhullcpp/RoadLogEvent.h#1 $$Change: 1981 $
5 ** $DateTime: 2015/09/28 20:26:32 $$Author: bbarber $
6 **
7 ****************************************************************************/
8 
9 #ifndef ROADLOGEVENT_H
10 #define ROADLOGEVENT_H
11 
12 #include <ostream>
13 #include <stdexcept>
14 #include <string>
15 
16 namespace orgQhull {
17 
18 #
19  struct RoadLogEvent;
21 
22 struct RoadLogEvent {
23 
24 public:
25 #
26  const char * format_string;
27  int int_1;
28  int int_2;
29  float float_1;
30  union {
31  const char *cstr_1;
32  const void *void_1;
33  long long int64_1;
34  double double_1;
35  };
36 
37 #
38 
39 #
40  RoadLogEvent() : format_string(0), int_1(0), int_2(0), float_1(0), int64_1(0) {};
41  explicit RoadLogEvent(const char *fmt) : format_string(fmt), int_1(0), int_2(0), float_1(0), int64_1(0) {};
42  RoadLogEvent(const char *fmt, int d) : format_string(fmt), int_1(d), int_2(0), float_1(0), int64_1(0) {};
43  RoadLogEvent(const char *fmt, int d, int d2) : format_string(fmt), int_1(d), int_2(d2), float_1(0), int64_1(0) {};
44  RoadLogEvent(const char *fmt, int d, int d2, float f) : format_string(fmt), int_1(d), int_2(d2), float_1(f), int64_1(0) {};
45  RoadLogEvent(const char *fmt, int d, int d2, float f, const char *s) : format_string(fmt), int_1(d), int_2(d2), float_1(f), cstr_1(s) {};
46  RoadLogEvent(const char *fmt, int d, int d2, float f, const void *x) : format_string(fmt), int_1(d), int_2(d2), float_1(f), void_1(x) {};
47  RoadLogEvent(const char *fmt, int d, int d2, float f, int i) : format_string(fmt), int_1(d), int_2(d2), float_1(f), int64_1(i) {};
48  RoadLogEvent(const char *fmt, int d, int d2, float f, long long i) : format_string(fmt), int_1(d), int_2(d2), float_1(f), int64_1(i) {};
49  RoadLogEvent(const char *fmt, int d, int d2, float f, double g) : format_string(fmt), int_1(d), int_2(d2), float_1(f), double_1(g) {};
52 
53 #
54  bool isValid() const { return format_string!=0; }
55  int int1() const { return int_1; };
56  int int2() const { return int_2; };
57  float float1() const { return float_1; };
58  const char * format() const { return format_string; };
59  const char * cstr1() const { return cstr_1; };
60  const void * void1() const { return void_1; };
61  long long int64() const { return int64_1; };
62  double double1() const { return double_1; };
63 
64 #
65 
66  std::string toString(const char* tag, int code) const;
67 
68 private:
69 #
70  static bool firstExtraCode(std::ostream &os, char c, char *extraCode);
71 
72 
73 };//class RoadLogEvent
74 
75 }//namespace orgQhull
76 
77 #endif // ROADLOGEVENT_H
orgQhull::RoadLogEvent::double_1
double double_1
signed int64 (i). Ambiguous if unsigned is also defined.
Definition: RoadLogEvent.h:40
orgQhull::RoadLogEvent::format_string
const char * format_string
Definition: RoadLogEvent.h:32
obb.fmt
fmt
Definition: obb.py:145
orgQhull
QhullRidge – Qhull's ridge structure, ridgeT, as a C++ class.
Definition: Coordinates.cpp:21
orgQhull::RoadLogEvent::int64
long long int64() const
Definition: RoadLogEvent.h:67
orgQhull::RoadLogEvent::toString
std::string toString(const char *tag, int code) const
Definition: RoadLogEvent.cpp:29
orgQhull::RoadLogEvent::RoadLogEvent
RoadLogEvent(const char *fmt)
Definition: RoadLogEvent.h:47
orgQhull::RoadLogEvent::RoadLogEvent
RoadLogEvent(const char *fmt, int d, int d2)
Definition: RoadLogEvent.h:49
orgQhull::RoadLogEvent::float_1
float float_1
Integer argument (d, for logging)
Definition: RoadLogEvent.h:35
orgQhull::RoadLogEvent::cstr1
const char * cstr1() const
Definition: RoadLogEvent.h:65
orgQhull::RoadLogEvent::RoadLogEvent
RoadLogEvent()
Definition: RoadLogEvent.h:46
orgQhull::RoadLogEvent::~RoadLogEvent
~RoadLogEvent()
Definition: RoadLogEvent.h:56
orgQhull::RoadLogEvent::double1
double double1() const
Definition: RoadLogEvent.h:68
orgQhull::RoadLogEvent::RoadLogEvent
RoadLogEvent(const char *fmt, int d)
Definition: RoadLogEvent.h:48
x
x
orgQhull::RoadLogEvent::int1
int int1() const
Definition: RoadLogEvent.h:61
orgQhull::RoadLogEvent::format
const char * format() const
Definition: RoadLogEvent.h:64
orgQhull::RoadLogEvent::float1
float float1() const
Definition: RoadLogEvent.h:63
orgQhull::RoadLogEvent::int64_1
long long int64_1
Void* argument (x) – Use upper-case codes for object types.
Definition: RoadLogEvent.h:39
orgQhull::RoadLogEvent::int_2
int int_2
Integer argument (d, for logging)
Definition: RoadLogEvent.h:34
orgQhull::RoadLogEvent::void_1
const void * void_1
Cstr argument (s) – type checked at construct-time.
Definition: RoadLogEvent.h:38
orgQhull::RoadLogEvent::cstr_1
const char * cstr_1
One additional argument (for logging)
Definition: RoadLogEvent.h:37
orgQhull::RoadLogEvent::int2
int int2() const
Definition: RoadLogEvent.h:62
orgQhull::RoadLogEvent::int_1
int int_1
Format string (a literal with format codes, for logging)
Definition: RoadLogEvent.h:33
orgQhull::RoadLogEvent::void1
const void * void1() const
Definition: RoadLogEvent.h:66


hpp-fcl
Author(s):
autogenerated on Fri Aug 2 2024 02:45:15