69 m_communicator = null_communicator;
74 explicit Communicator(
void* acommunicator)
77 m_communicator.v = acommunicator;
80 explicit Communicator(
const void* acommunicator)
83 m_communicator.cv = acommunicator;
86 explicit Communicator(
int acommunicator)
89 m_communicator.i = acommunicator;
92 explicit Communicator(
long acommunicator)
95 m_communicator.l = acommunicator;
98 explicit Communicator(std::size_t acommunicator)
101 m_communicator.st = acommunicator;
108 operator const T*()
const {
return (
const T*)m_communicator.cv; }
110 operator T*()
const {
return (T*)m_communicator.v; }
111 operator int()
const {
return m_communicator.i; }
112 operator long()
const {
return m_communicator.l; }
113 operator size_t()
const {
return m_communicator.st; }
114 void* communicatorAddress() {
return &m_communicator; }
130 if (m_type!=null_communicator_type)
133 return m_communicator.i!=null_communicator.i;
135 return m_communicator.l!=null_communicator.l;
137 return m_communicator.st!=null_communicator.st;
139 return m_communicator.cv!=null_communicator.cv;
145 null_communicator = r.m_communicator;
146 null_communicator_type = r.m_type;
151 m_communicator = null_communicator;
155 void print(std::ostream& o)
const;
157 friend inline std::ostream& operator<<(std::ostream& o,
const Communicator& pcommunicator)
159 pcommunicator.print(o);
169 _Communicator m_communicator;
170 static _Communicator null_communicator;
171 static int null_communicator_type;