start of Win32 port
This commit is contained in:
@@ -7,6 +7,7 @@
|
||||
* @author mes
|
||||
*/
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/convert.h>
|
||||
|
||||
#include <algorithm>
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
#include <vector>
|
||||
#include <stdexcept>
|
||||
#include <typeinfo>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/lock.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
#include <stdexcept>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/lock.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/convert.h>
|
||||
@@ -124,7 +126,7 @@ void Scalar::serialize(ByteBuffer *buffer, SerializableControl *control) const {
|
||||
buffer->putByte(getTypeCodeLUT());
|
||||
}
|
||||
|
||||
void Scalar::deserialize(ByteBuffer */*buffer*/, DeserializableControl */*control*/) {
|
||||
void Scalar::deserialize(ByteBuffer* /*buffer*/, DeserializableControl* /*control*/) {
|
||||
// must be done via FieldCreate
|
||||
throw std::runtime_error("not valid operation, use FieldCreate::deserialize instead");
|
||||
}
|
||||
@@ -270,7 +272,7 @@ void ScalarArray::serialize(ByteBuffer *buffer, SerializableControl *control) co
|
||||
buffer->putByte(0x10 | getTypeCodeLUT());
|
||||
}
|
||||
|
||||
void ScalarArray::deserialize(ByteBuffer */*buffer*/, DeserializableControl */*control*/) {
|
||||
void ScalarArray::deserialize(ByteBuffer* /*buffer*/, DeserializableControl* /*control*/) {
|
||||
throw std::runtime_error("not valid operation, use FieldCreate::deserialize instead");
|
||||
}
|
||||
|
||||
@@ -300,7 +302,7 @@ void StructureArray::serialize(ByteBuffer *buffer, SerializableControl *control)
|
||||
control->cachedSerialize(pstructure, buffer);
|
||||
}
|
||||
|
||||
void StructureArray::deserialize(ByteBuffer */*buffer*/, DeserializableControl */*control*/) {
|
||||
void StructureArray::deserialize(ByteBuffer* /*buffer*/, DeserializableControl* /*control*/) {
|
||||
throw std::runtime_error("not valid operation, use FieldCreate::deserialize instead");
|
||||
}
|
||||
|
||||
@@ -338,7 +340,7 @@ void UnionArray::serialize(ByteBuffer *buffer, SerializableControl *control) con
|
||||
}
|
||||
}
|
||||
|
||||
void UnionArray::deserialize(ByteBuffer */*buffer*/, DeserializableControl */*control*/) {
|
||||
void UnionArray::deserialize(ByteBuffer* /*buffer*/, DeserializableControl* /*control*/) {
|
||||
throw std::runtime_error("not valid operation, use FieldCreate::deserialize instead");
|
||||
}
|
||||
|
||||
@@ -456,7 +458,7 @@ void Structure::serialize(ByteBuffer *buffer, SerializableControl *control) cons
|
||||
serializeStructureField(this, buffer, control);
|
||||
}
|
||||
|
||||
void Structure::deserialize(ByteBuffer */*buffer*/, DeserializableControl */*control*/) {
|
||||
void Structure::deserialize(ByteBuffer* /*buffer*/, DeserializableControl* /*control*/) {
|
||||
throw std::runtime_error("not valid operation, use FieldCreate::deserialize instead");
|
||||
}
|
||||
|
||||
@@ -601,7 +603,7 @@ void Union::serialize(ByteBuffer *buffer, SerializableControl *control) const {
|
||||
}
|
||||
}
|
||||
|
||||
void Union::deserialize(ByteBuffer */*buffer*/, DeserializableControl */*control*/) {
|
||||
void Union::deserialize(ByteBuffer* /*buffer*/, DeserializableControl* /*control*/) {
|
||||
throw std::runtime_error("not valid operation, use FieldCreate::deserialize instead");
|
||||
}
|
||||
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/factory.h>
|
||||
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/noDefaultMethods.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/convert.h>
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/lock.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/lock.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/factory.h>
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/factory.h>
|
||||
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/factory.h>
|
||||
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
#include <vector>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/convert.h>
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/convert.h>
|
||||
#include <pv/factory.h>
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
#include <vector>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/convert.h>
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
#include <cstdlib>
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/convert.h>
|
||||
#include <pv/factory.h>
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
#include <stdexcept>
|
||||
#include <epicsThread.h>
|
||||
#include <epicsExit.h>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/lock.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/standardField.h>
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
#include <stdexcept>
|
||||
#include <epicsThread.h>
|
||||
#include <epicsExit.h>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/lock.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/epicsException.h>
|
||||
#include <pv/sharedVector.h>
|
||||
|
||||
@@ -1,7 +1,14 @@
|
||||
|
||||
/* printer.cpp */
|
||||
/**
|
||||
* Copyright - See the COPYRIGHT that is included with this distribution.
|
||||
* EPICS pvData is distributed subject to a Software License Agreement found
|
||||
* in file LICENSE that is included with this distribution.
|
||||
*/
|
||||
|
||||
#include <deque>
|
||||
|
||||
#include "pv/printer.h"
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/printer.h>
|
||||
|
||||
namespace {
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
#include <stdexcept>
|
||||
#include <memory>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvSubArrayCopy.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
@@ -7,12 +7,14 @@
|
||||
/**
|
||||
* @author mes
|
||||
*/
|
||||
#include "string.h"
|
||||
#include "stdio.h"
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
#include <iostream>
|
||||
#include <pv/bitSet.h>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/lock.h>
|
||||
#include <pv/serializeHelper.h>
|
||||
#include <pv/bitSet.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
|
||||
@@ -9,11 +9,15 @@
|
||||
*/
|
||||
#ifndef BITSET_H
|
||||
#define BITSET_H
|
||||
|
||||
#include <stdexcept>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/serialize.h>
|
||||
#include <pv/sharedPtr.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class BitSet;
|
||||
@@ -42,7 +46,7 @@ namespace epics { namespace pvData {
|
||||
*
|
||||
* Based on Java implementation.
|
||||
*/
|
||||
class BitSet : public Serializable {
|
||||
class epicsShareClass BitSet : public Serializable {
|
||||
public:
|
||||
POINTER_DEFINITIONS(BitSet);
|
||||
static BitSetPtr create(uint32 nbits);
|
||||
|
||||
@@ -12,11 +12,21 @@
|
||||
|
||||
#include <string>
|
||||
#include <pv/pvType.h>
|
||||
#include <epicsEndian.h>
|
||||
#include <string.h>
|
||||
|
||||
#include <pv/epicsException.h>
|
||||
|
||||
#ifdef epicsExportSharedSymbols
|
||||
#define byteBufferepicsExportSharedSymbols
|
||||
#undef epicsExportSharedSymbols
|
||||
#endif
|
||||
|
||||
#include <epicsEndian.h>
|
||||
|
||||
#ifdef byteBufferepicsExportSharedSymbols
|
||||
#define epicsExportSharedSymbols
|
||||
#undef byteBufferepicsExportSharedSymbols
|
||||
#endif
|
||||
#include <shareLib.h>
|
||||
|
||||
namespace epics {
|
||||
namespace pvData {
|
||||
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
|
||||
#include <pv/sharedPtr.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
|
||||
@@ -19,7 +21,7 @@ namespace epics { namespace pvData {
|
||||
* Instance declaring destroy method.
|
||||
* @author mse
|
||||
*/
|
||||
class Destroyable {
|
||||
class epicsShareClass Destroyable {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Destroyable);
|
||||
/**
|
||||
|
||||
@@ -7,14 +7,15 @@
|
||||
* @author mes
|
||||
*/
|
||||
|
||||
#include <pv/epicsException.h>
|
||||
|
||||
#include <sstream>
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstring>
|
||||
|
||||
namespace epics{namespace pvData{
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/epicsException.h>
|
||||
|
||||
|
||||
namespace epics{ namespace pvData {
|
||||
|
||||
void
|
||||
ExceptionMixin::print(FILE *fp) const
|
||||
|
||||
@@ -43,6 +43,8 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
// Users may redefine this for a large size if desired
|
||||
#ifndef EXCEPT_DEPTH
|
||||
# define EXCEPT_DEPTH 20
|
||||
@@ -67,7 +69,7 @@ namespace epics { namespace pvData {
|
||||
/* Stores file and line number given, and when possible the call stack
|
||||
* at the point where it was constructed
|
||||
*/
|
||||
class ExceptionMixin {
|
||||
class epicsShareClass ExceptionMixin {
|
||||
const char *m_file;
|
||||
int m_line;
|
||||
#ifndef EXCEPT_USE_NONE
|
||||
@@ -197,7 +199,7 @@ do { \
|
||||
|
||||
#endif // THROW_EXCEPTION_COMPAT
|
||||
|
||||
class BaseException : public std::logic_error {
|
||||
class epicsShareClass BaseException : public std::logic_error {
|
||||
public:
|
||||
explicit BaseException(const std::string msg) : std::logic_error(msg) {}
|
||||
|
||||
|
||||
@@ -19,6 +19,8 @@
|
||||
#include <epicsThread.h>
|
||||
#include <epicsMutex.h>
|
||||
#include <epicsEvent.h>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/noDefaultMethods.h>
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/lock.h>
|
||||
|
||||
@@ -9,18 +9,22 @@
|
||||
*/
|
||||
#ifndef EVENT_H
|
||||
#define EVENT_H
|
||||
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
#include <epicsEvent.h>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/sharedPtr.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class Event;
|
||||
typedef std::tr1::shared_ptr<Event> EventPtr;
|
||||
|
||||
class Event {
|
||||
class epicsShareClass Event {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Event);
|
||||
explicit Event(bool = false);
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/executor.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
@@ -9,13 +9,17 @@
|
||||
*/
|
||||
#ifndef EXECUTOR_H
|
||||
#define EXECUTOR_H
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/lock.h>
|
||||
#include <pv/event.h>
|
||||
#include <pv/thread.h>
|
||||
#include <pv/sharedPtr.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class Command;
|
||||
@@ -23,7 +27,7 @@ class Executor;
|
||||
typedef std::tr1::shared_ptr<Command> CommandPtr;
|
||||
typedef std::tr1::shared_ptr<Executor> ExecutorPtr;
|
||||
|
||||
class Command {
|
||||
class epicsShareClass Command {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Command);
|
||||
virtual ~Command(){}
|
||||
@@ -33,7 +37,7 @@ private:
|
||||
friend class Executor;
|
||||
};
|
||||
|
||||
class Executor : public Runnable{
|
||||
class epicsShareClass Executor : public Runnable{
|
||||
public:
|
||||
POINTER_DEFINITIONS(Executor);
|
||||
Executor(String threadName,ThreadPriority priority);
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
* @author mse
|
||||
*/
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/localStaticLock.h>
|
||||
|
||||
static int nifty_counter;
|
||||
|
||||
@@ -12,7 +12,9 @@
|
||||
|
||||
#include <pv/lock.h>
|
||||
|
||||
extern epics::pvData::Mutex& getLocalStaticInitMutex();
|
||||
#include <sharelib.h>
|
||||
|
||||
epicsShareExtern epics::pvData::Mutex& getLocalStaticInitMutex();
|
||||
|
||||
#if defined(__GNUC__) && __GNUC__ >= 4
|
||||
// noop
|
||||
@@ -21,7 +23,7 @@ extern epics::pvData::Mutex& getLocalStaticInitMutex();
|
||||
#define LOCAL_STATIC_LOCK epics::pvData::Lock localStaticInitMutexLock(getLocalStaticInitMutex());
|
||||
#endif
|
||||
|
||||
static class MutexInitializer {
|
||||
static class epicsShareClass MutexInitializer {
|
||||
public:
|
||||
MutexInitializer ();
|
||||
~MutexInitializer ();
|
||||
|
||||
@@ -9,9 +9,14 @@
|
||||
*/
|
||||
#ifndef LOCK_H
|
||||
#define LOCK_H
|
||||
|
||||
#include <stdexcept>
|
||||
#include <epicsMutex.h>
|
||||
|
||||
#include <pv/noDefaultMethods.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
/* This is based on item 14 of
|
||||
* Effective C++, Third Edition, Scott Meyers
|
||||
*/
|
||||
@@ -22,7 +27,7 @@ namespace epics { namespace pvData {
|
||||
|
||||
typedef epicsMutex Mutex;
|
||||
|
||||
class Lock : private NoDefaultMethods {
|
||||
class epicsShareClass Lock : private NoDefaultMethods {
|
||||
public:
|
||||
explicit Lock(Mutex &m)
|
||||
: mutexPtr(m), locked(true)
|
||||
|
||||
@@ -8,7 +8,10 @@
|
||||
* @author mrk
|
||||
*/
|
||||
#include <string>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/messageQueue.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
MessageNode::MessageNode()
|
||||
|
||||
@@ -18,6 +18,8 @@
|
||||
#include <pv/requester.h>
|
||||
#include <pv/queue.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class MessageNode;
|
||||
@@ -26,7 +28,7 @@ typedef std::tr1::shared_ptr<MessageNode> MessageNodePtr;
|
||||
typedef std::vector<MessageNodePtr> MessageNodePtrArray;
|
||||
typedef std::tr1::shared_ptr<MessageQueue> MessageQueuePtr;
|
||||
|
||||
class MessageNode {
|
||||
class epicsShareClass MessageNode {
|
||||
public:
|
||||
MessageNode();
|
||||
String getMessage() const;
|
||||
@@ -37,7 +39,7 @@ private:
|
||||
friend class MessageQueue;
|
||||
};
|
||||
|
||||
class MessageQueue : public Queue<MessageNode> {
|
||||
class epicsShareClass MessageQueue : public Queue<MessageNode> {
|
||||
public:
|
||||
POINTER_DEFINITIONS(MessageQueue);
|
||||
static MessageQueuePtr create(int size);
|
||||
|
||||
@@ -9,13 +9,16 @@
|
||||
*/
|
||||
#ifndef NO_DEFAULT_METHODS_H
|
||||
#define NO_DEFAULT_METHODS_H
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
/* This is based on Item 6 of
|
||||
* Effective C++, Third Edition, Scott Meyers
|
||||
*/
|
||||
|
||||
|
||||
class NoDefaultMethods {
|
||||
class epicsShareClass NoDefaultMethods {
|
||||
protected:
|
||||
// allow by derived objects
|
||||
NoDefaultMethods(){};
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
#include "typeCast.h"
|
||||
|
||||
// need to use "long long" when sizeof(int)==sizeof(long)
|
||||
// TODO does not work on Darwin 10.6
|
||||
#if ULONG_MAX == 0xfffffffful
|
||||
#define NEED_LONGLONG
|
||||
#endif
|
||||
|
||||
@@ -7,12 +7,15 @@
|
||||
/**
|
||||
* @author mrk
|
||||
*/
|
||||
#ifndef QUEUE_H
|
||||
#define QUEUE_H
|
||||
|
||||
#include <vector>
|
||||
#include <cstddef>
|
||||
#include <stdexcept>
|
||||
|
||||
#include <pv/sharedPtr.h>
|
||||
#ifndef QUEUE_H
|
||||
#define QUEUE_H
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
template <typename T>
|
||||
|
||||
@@ -9,15 +9,18 @@
|
||||
*/
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/lock.h>
|
||||
#include <pv/requester.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
const size_t messageTypeCount = 4;
|
||||
static StringArray messageTypeName(messageTypeCount);
|
||||
static StringArray messageTypeName(MESSAGE_TYPE_COUNT);
|
||||
|
||||
String getMessageTypeName(MessageType messageType)
|
||||
{
|
||||
// TODO not thread-safe
|
||||
static Mutex mutex;
|
||||
Lock xx(mutex);
|
||||
if(messageTypeName[0].size()==0) {
|
||||
|
||||
@@ -10,9 +10,12 @@
|
||||
#ifndef REQUESTER_H
|
||||
#define REQUESTER_H
|
||||
#include <string>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/sharedPtr.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class Requester;
|
||||
@@ -21,10 +24,11 @@ typedef std::tr1::shared_ptr<Requester> RequesterPtr;
|
||||
enum MessageType {
|
||||
infoMessage,warningMessage,errorMessage,fatalErrorMessage
|
||||
};
|
||||
#define MESSAGE_TYPE_COUNT 4
|
||||
|
||||
extern String getMessageTypeName(MessageType messageType);
|
||||
extern const size_t messageTypeCount;
|
||||
class Requester {
|
||||
epicsShareExtern String getMessageTypeName(MessageType messageType);
|
||||
|
||||
class epicsShareClass Requester {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Requester);
|
||||
virtual ~Requester(){}
|
||||
|
||||
@@ -9,8 +9,12 @@
|
||||
*/
|
||||
#ifndef SERIALIZE_H
|
||||
#define SERIALIZE_H
|
||||
|
||||
#include <pv/byteBuffer.h>
|
||||
#include <pv/sharedPtr.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class SerializableControl;
|
||||
@@ -21,7 +25,7 @@ namespace epics { namespace pvData {
|
||||
class BitSet;
|
||||
class Field;
|
||||
|
||||
class SerializableControl {
|
||||
class epicsShareClass SerializableControl {
|
||||
public:
|
||||
virtual ~SerializableControl(){}
|
||||
virtual void flushSerializeBuffer() =0;
|
||||
@@ -32,7 +36,7 @@ namespace epics { namespace pvData {
|
||||
virtual void cachedSerialize(std::tr1::shared_ptr<const Field> const & field, ByteBuffer* buffer) = 0;
|
||||
};
|
||||
|
||||
class DeserializableControl {
|
||||
class epicsShareClass DeserializableControl {
|
||||
public:
|
||||
virtual ~DeserializableControl(){}
|
||||
virtual void ensureData(std::size_t size) =0;
|
||||
@@ -42,7 +46,7 @@ namespace epics { namespace pvData {
|
||||
virtual std::tr1::shared_ptr<const Field> cachedDeserialize(ByteBuffer* buffer) = 0;
|
||||
};
|
||||
|
||||
class Serializable {
|
||||
class epicsShareClass Serializable {
|
||||
public:
|
||||
virtual ~Serializable(){}
|
||||
virtual void serialize(ByteBuffer *buffer,
|
||||
@@ -51,7 +55,7 @@ namespace epics { namespace pvData {
|
||||
DeserializableControl *flusher) = 0;
|
||||
};
|
||||
|
||||
class BitSetSerializable {
|
||||
class epicsShareClass BitSetSerializable {
|
||||
public:
|
||||
virtual ~BitSetSerializable(){}
|
||||
virtual void serialize(ByteBuffer *buffer,
|
||||
@@ -61,7 +65,7 @@ namespace epics { namespace pvData {
|
||||
};
|
||||
|
||||
|
||||
class SerializableArray : virtual public Serializable {
|
||||
class epicsShareClass SerializableArray : virtual public Serializable {
|
||||
public:
|
||||
virtual ~SerializableArray(){}
|
||||
virtual void serialize(ByteBuffer *buffer,
|
||||
|
||||
@@ -11,13 +11,13 @@
|
||||
*/
|
||||
|
||||
#include <algorithm>
|
||||
#include <pv/pvType.h>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/epicsException.h>
|
||||
#include <pv/byteBuffer.h>
|
||||
#include <pv/serializeHelper.h>
|
||||
|
||||
|
||||
using namespace std;
|
||||
|
||||
namespace epics {
|
||||
|
||||
@@ -18,10 +18,12 @@
|
||||
#include <pv/noDefaultMethods.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics {
|
||||
namespace pvData {
|
||||
|
||||
class SerializeHelper : public NoDefaultMethods {
|
||||
class epicsShareClass SerializeHelper : public NoDefaultMethods {
|
||||
public:
|
||||
|
||||
/**
|
||||
|
||||
@@ -1,3 +1,9 @@
|
||||
/* sharedVector.h */
|
||||
/**
|
||||
* Copyright - See the COPYRIGHT that is included with this distribution.
|
||||
* EPICS pvData is distributed subject to a Software License Agreement found
|
||||
* in file LICENSE that is included with this distribution.
|
||||
*/
|
||||
#ifndef SHAREDVECTOR_H
|
||||
#define SHAREDVECTOR_H
|
||||
|
||||
|
||||
@@ -7,9 +7,10 @@
|
||||
/**
|
||||
* @author mrk
|
||||
*/
|
||||
#include <pv/status.h>
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/epicsException.h>
|
||||
#include <pv/serializeHelper.h>
|
||||
#include <pv/status.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
|
||||
@@ -14,13 +14,15 @@
|
||||
#include <pv/byteBuffer.h>
|
||||
#include <pv/sharedPtr.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
/**
|
||||
* Status.
|
||||
* @author mse
|
||||
*/
|
||||
class Status : public epics::pvData::Serializable {
|
||||
class epicsShareClass Status : public epics::pvData::Serializable {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Status);
|
||||
/**
|
||||
|
||||
@@ -9,11 +9,15 @@
|
||||
*/
|
||||
#ifndef THREAD_H
|
||||
#define THREAD_H
|
||||
|
||||
#include <memory>
|
||||
|
||||
#include <epicsThread.h>
|
||||
|
||||
#include <pv/noDefaultMethods.h>
|
||||
#include <pv/pvType.h>
|
||||
|
||||
#include <epicsThread.h>
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
@@ -33,7 +37,7 @@ typedef std::tr1::shared_ptr<epicsThread> EpicsThreadPtr;
|
||||
|
||||
typedef epicsThreadRunable Runnable;
|
||||
|
||||
class Thread : public epicsThread, private NoDefaultMethods {
|
||||
class epicsShareClass Thread : public epicsThread, private NoDefaultMethods {
|
||||
public:
|
||||
|
||||
Thread(String name,
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
#include <string>
|
||||
#include <cstdio>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/timeStamp.h>
|
||||
#include <pv/timeFunction.h>
|
||||
|
||||
@@ -9,8 +9,11 @@
|
||||
*/
|
||||
#ifndef TIMEFUNCTION_H
|
||||
#define TIMEFUNCTION_H
|
||||
|
||||
#include <pv/sharedPtr.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class TimeFunctionRequester;
|
||||
@@ -18,7 +21,7 @@ class TimeFunction;
|
||||
typedef std::tr1::shared_ptr<TimeFunctionRequester> TimeFunctionRequesterPtr;
|
||||
typedef std::tr1::shared_ptr<TimeFunction> TimeFunctionPtr;
|
||||
|
||||
class TimeFunctionRequester {
|
||||
class epicsShareClass TimeFunctionRequester {
|
||||
public:
|
||||
POINTER_DEFINITIONS(TimeFunctionRequester);
|
||||
virtual ~TimeFunctionRequester(){}
|
||||
@@ -26,7 +29,7 @@ public:
|
||||
};
|
||||
|
||||
|
||||
class TimeFunction {
|
||||
class epicsShareClass TimeFunction {
|
||||
public:
|
||||
POINTER_DEFINITIONS(TimeFunction);
|
||||
TimeFunction(TimeFunctionRequesterPtr const & requester);
|
||||
|
||||
@@ -14,8 +14,9 @@
|
||||
#include <stdio.h>
|
||||
#include <stdexcept>
|
||||
|
||||
#include <pv/timer.h>
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/convert.h>
|
||||
#include <pv/timer.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
|
||||
@@ -23,6 +23,8 @@
|
||||
#include <pv/lock.h>
|
||||
#include <pv/sharedPtr.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class TimerCallback;
|
||||
@@ -30,7 +32,7 @@ class Timer;
|
||||
typedef std::tr1::shared_ptr<TimerCallback> TimerCallbackPtr;
|
||||
typedef std::tr1::shared_ptr<Timer> TimerPtr;
|
||||
|
||||
class TimerCallback {
|
||||
class epicsShareClass TimerCallback {
|
||||
public:
|
||||
POINTER_DEFINITIONS(TimerCallback);
|
||||
TimerCallback();
|
||||
@@ -45,7 +47,7 @@ private:
|
||||
friend class Timer;
|
||||
};
|
||||
|
||||
class Timer : public Runnable {
|
||||
class epicsShareClass Timer : public Runnable {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Timer);
|
||||
Timer(String threadName, ThreadPriority priority);
|
||||
|
||||
@@ -16,6 +16,8 @@
|
||||
#include <pv/sharedPtr.h>
|
||||
#include <pv/bitSet.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class MonitorElement;
|
||||
@@ -30,7 +32,7 @@ typedef std::tr1::shared_ptr<Monitor> MonitorPtr;
|
||||
* Class instance representing monitor element.
|
||||
* @author mrk
|
||||
*/
|
||||
class MonitorElement {
|
||||
class epicsShareClass MonitorElement {
|
||||
public:
|
||||
POINTER_DEFINITIONS(MonitorElement);
|
||||
MonitorElement(){}
|
||||
@@ -48,7 +50,7 @@ class MonitorElement {
|
||||
* Interface for Monitor.
|
||||
* @author mrk
|
||||
*/
|
||||
class Monitor : public Destroyable{
|
||||
class epicsShareClass Monitor : public Destroyable{
|
||||
public:
|
||||
POINTER_DEFINITIONS(Monitor);
|
||||
virtual ~Monitor(){}
|
||||
@@ -80,7 +82,7 @@ class Monitor : public Destroyable{
|
||||
* Requester for ChannelMonitor.
|
||||
* @author mrk
|
||||
*/
|
||||
class MonitorRequester : public virtual Requester {
|
||||
class epicsShareClass MonitorRequester : public virtual Requester {
|
||||
public:
|
||||
POINTER_DEFINITIONS(MonitorRequester);
|
||||
virtual ~MonitorRequester(){}
|
||||
|
||||
@@ -9,13 +9,15 @@
|
||||
*/
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/lock.h>
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/alarm.h>
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
AlarmSeverity AlarmSeverityFunc::getSeverity(int value)
|
||||
{
|
||||
@@ -34,7 +36,7 @@ AlarmSeverity AlarmSeverityFunc::getSeverity(int value)
|
||||
|
||||
StringArrayPtr AlarmSeverityFunc::getSeverityNames()
|
||||
{
|
||||
static size_t severityCount = 5;
|
||||
static size_t severityCount = 5;
|
||||
static StringArrayPtr severityNames;
|
||||
static Mutex mutex;
|
||||
Lock xx(mutex);
|
||||
@@ -82,7 +84,7 @@ AlarmStatus AlarmStatusFunc::getStatus(int value)
|
||||
|
||||
StringArrayPtr AlarmStatusFunc::getStatusNames()
|
||||
{
|
||||
static size_t statusCount = 8;
|
||||
static size_t statusCount = 8;
|
||||
static StringArrayPtr statusNames;
|
||||
static Mutex mutex;
|
||||
Lock xx(mutex);
|
||||
|
||||
@@ -7,10 +7,15 @@
|
||||
/**
|
||||
* @author mrk
|
||||
*/
|
||||
#include <string>
|
||||
#include <pv/pvType.h>
|
||||
#ifndef ALARM_H
|
||||
#define ALARM_H
|
||||
|
||||
#include <string>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
enum AlarmSeverity {
|
||||
@@ -23,21 +28,19 @@ enum AlarmStatus {
|
||||
};
|
||||
|
||||
|
||||
extern const size_t severityCount;
|
||||
class AlarmSeverityFunc {
|
||||
class epicsShareClass AlarmSeverityFunc {
|
||||
public:
|
||||
static AlarmSeverity getSeverity(int value);
|
||||
static StringArrayPtr getSeverityNames();
|
||||
};
|
||||
|
||||
extern const size_t statusCount;
|
||||
class AlarmStatusFunc {
|
||||
class epicsShareClass AlarmStatusFunc {
|
||||
public:
|
||||
static AlarmStatus getStatus(int value);
|
||||
static StringArrayPtr getStatusNames();
|
||||
};
|
||||
|
||||
class Alarm {
|
||||
class epicsShareClass Alarm {
|
||||
public:
|
||||
Alarm() : severity(0),status(0), message(String("")) {}
|
||||
//default constructors and destructor are OK
|
||||
|
||||
@@ -9,9 +9,12 @@
|
||||
*/
|
||||
#ifndef CONTROL_H
|
||||
#define CONTROL_H
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class Control {
|
||||
class epicsShareClass Control {
|
||||
public:
|
||||
Control() : low(0.0), high(0.0) {}
|
||||
//default constructors and destructor are OK
|
||||
|
||||
@@ -7,14 +7,19 @@
|
||||
/**
|
||||
* @author mrk
|
||||
*/
|
||||
#include <string>
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvData.h>
|
||||
#ifndef DISPLAY_H
|
||||
#define DISPLAY_H
|
||||
|
||||
#include <string>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvData.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class Display {
|
||||
class epicsShareClass Display {
|
||||
public:
|
||||
Display()
|
||||
: description(String("")),format(String("")),units(String("")),
|
||||
|
||||
@@ -9,10 +9,13 @@
|
||||
*/
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/pvAlarm.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
using std::tr1::static_pointer_cast;
|
||||
|
||||
@@ -9,14 +9,18 @@
|
||||
*/
|
||||
#ifndef PVALARM_H
|
||||
#define PVALARM_H
|
||||
|
||||
#include <string>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/alarm.h>
|
||||
#include <pv/pvData.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class PVAlarm {
|
||||
class epicsShareClass PVAlarm {
|
||||
public:
|
||||
PVAlarm() {}
|
||||
//default constructors and destructor are OK
|
||||
|
||||
@@ -9,10 +9,13 @@
|
||||
*/
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/pvControl.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
using std::tr1::static_pointer_cast;
|
||||
|
||||
@@ -7,13 +7,17 @@
|
||||
/**
|
||||
* @author mrk
|
||||
*/
|
||||
#include <pv/control.h>
|
||||
#include <pv/pvData.h>
|
||||
#ifndef PVCONTROL_H
|
||||
#define PVCONTROL_H
|
||||
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/control.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class PVControl {
|
||||
class epicsShareClass PVControl {
|
||||
public:
|
||||
PVControl(){}
|
||||
//default constructors and destructor are OK
|
||||
|
||||
@@ -9,10 +9,13 @@
|
||||
*/
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/pvDisplay.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
using std::tr1::static_pointer_cast;
|
||||
|
||||
@@ -7,15 +7,20 @@
|
||||
/**
|
||||
* @author mrk
|
||||
*/
|
||||
#ifndef PVDISPLAY_H
|
||||
#define PVDISPLAY_H
|
||||
|
||||
#include <string>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/display.h>
|
||||
#ifndef PVDISPLAY_H
|
||||
#define PVDISPLAY_H
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class PVDisplay {
|
||||
class epicsShareClass PVDisplay {
|
||||
public:
|
||||
PVDisplay() {}
|
||||
//default constructors and destructor are OK
|
||||
|
||||
@@ -9,10 +9,13 @@
|
||||
*/
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/pvEnumerated.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
using std::tr1::static_pointer_cast;
|
||||
|
||||
@@ -7,14 +7,19 @@
|
||||
/**
|
||||
* @author mrk
|
||||
*/
|
||||
#include <string>
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvData.h>
|
||||
#ifndef PVENUMERATED_H
|
||||
#define PVENUMERATED_H
|
||||
|
||||
#include <string>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvData.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class PVEnumerated {
|
||||
class epicsShareClass PVEnumerated {
|
||||
public:
|
||||
PVEnumerated() {}
|
||||
//default constructors and destructor are OK
|
||||
|
||||
@@ -9,10 +9,13 @@
|
||||
*/
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/timeStamp.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/pvTimeStamp.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
using std::tr1::static_pointer_cast;
|
||||
|
||||
@@ -7,16 +7,21 @@
|
||||
/**
|
||||
* @author mrk
|
||||
*/
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/timeStamp.h>
|
||||
#include <pv/pvData.h>
|
||||
#ifndef PVTIMESTAMP_H
|
||||
#define PVTIMESTAMP_H
|
||||
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/timeStamp.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class PVTimeStamp {
|
||||
class epicsShareClass PVTimeStamp {
|
||||
public:
|
||||
PVTimeStamp(){}
|
||||
//default constructors and destructor are OK
|
||||
|
||||
@@ -14,6 +14,8 @@
|
||||
#include <cstdio>
|
||||
|
||||
#include <epicsTime.h>
|
||||
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/noDefaultMethods.h>
|
||||
#include <pv/pvType.h>
|
||||
#include <pv/timeStamp.h>
|
||||
|
||||
@@ -9,18 +9,22 @@
|
||||
*/
|
||||
#ifndef TIMESTAMP_H
|
||||
#define TIMESTAMP_H
|
||||
|
||||
#include <ctime>
|
||||
#include "epicsTime.h"
|
||||
#include <epicsTime.h>
|
||||
|
||||
#include <pv/pvType.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
extern int32 milliSecPerSec;
|
||||
extern int32 microSecPerSec;
|
||||
extern int32 nanoSecPerSec;
|
||||
extern int64 posixEpochAtEpicsEpoch;
|
||||
epicsShareExtern int32 milliSecPerSec;
|
||||
epicsShareExtern int32 microSecPerSec;
|
||||
epicsShareExtern int32 nanoSecPerSec;
|
||||
epicsShareExtern int64 posixEpochAtEpicsEpoch;
|
||||
|
||||
class TimeStamp {
|
||||
class epicsShareClass TimeStamp {
|
||||
public:
|
||||
TimeStamp()
|
||||
:secondsPastEpoch(0), nanoSeconds(0), userTag(0) {}
|
||||
|
||||
@@ -10,28 +10,31 @@
|
||||
*/
|
||||
#ifndef CONVERT_H
|
||||
#define CONVERT_H
|
||||
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
#include <vector>
|
||||
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <vector>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
bool operator==(const PVField&, const PVField&);
|
||||
bool epicsShareExtern operator==(const PVField&, const PVField&);
|
||||
|
||||
static inline bool operator!=(const PVField& a, const PVField& b)
|
||||
{return !(a==b);}
|
||||
|
||||
|
||||
bool operator==(const Field&, const Field&);
|
||||
bool operator==(const Scalar&, const Scalar&);
|
||||
bool operator==(const ScalarArray&, const ScalarArray&);
|
||||
bool operator==(const Structure&, const Structure&);
|
||||
bool operator==(const StructureArray&, const StructureArray&);
|
||||
bool operator==(const Union&, const Union&);
|
||||
bool operator==(const UnionArray&, const UnionArray&);
|
||||
bool epicsShareExtern operator==(const Field&, const Field&);
|
||||
bool epicsShareExtern operator==(const Scalar&, const Scalar&);
|
||||
bool epicsShareExtern operator==(const ScalarArray&, const ScalarArray&);
|
||||
bool epicsShareExtern operator==(const Structure&, const Structure&);
|
||||
bool epicsShareExtern operator==(const StructureArray&, const StructureArray&);
|
||||
bool epicsShareExtern operator==(const Union&, const Union&);
|
||||
bool epicsShareExtern operator==(const UnionArray&, const UnionArray&);
|
||||
|
||||
static inline bool operator!=(const Field& a, const Field& b)
|
||||
{return !(a==b);}
|
||||
@@ -74,7 +77,7 @@ static inline bool operator!=(const UnionArray& a, const UnionArray& b)
|
||||
class Convert;
|
||||
typedef std::tr1::shared_ptr<Convert> ConvertPtr;
|
||||
|
||||
class Convert {
|
||||
class epicsShareClass Convert {
|
||||
public:
|
||||
static ConvertPtr getConvert();
|
||||
/**
|
||||
|
||||
@@ -25,11 +25,14 @@
|
||||
#include <iterator>
|
||||
#include <iostream>
|
||||
#include <iomanip>
|
||||
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/requester.h>
|
||||
#include <pv/typeCast.h>
|
||||
#include <pv/sharedVector.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
#if defined(__vxworks) && !defined(_WRS_VXWORKS_MAJOR)
|
||||
typedef class std::ios std::ios_base;
|
||||
#endif
|
||||
@@ -52,7 +55,8 @@ inline long& indent_value(std::ios_base& ios)
|
||||
return ios.iword(indent_index);
|
||||
}
|
||||
|
||||
std::ostream& operator<<(std::ostream& os, indent_level const& indent);
|
||||
epicsShareExtern std::ostream& operator<<(std::ostream& os, indent_level const& indent);
|
||||
|
||||
struct indent_scope
|
||||
{
|
||||
long saved_level;
|
||||
@@ -76,7 +80,7 @@ struct indent
|
||||
{
|
||||
};
|
||||
|
||||
std::ostream& operator<<(std::ostream& os, indent const&);
|
||||
epicsShareExtern std::ostream& operator<<(std::ostream& os, indent const&);
|
||||
|
||||
struct array_at
|
||||
{
|
||||
@@ -195,7 +199,7 @@ typedef std::tr1::shared_ptr<PVDataCreate> PVDataCreatePtr;
|
||||
* Each item is stored as a PVScalar.
|
||||
* A (key,value) is provided for accessing the items where the key is a String.
|
||||
*/
|
||||
class PVAuxInfo : private NoDefaultMethods {
|
||||
class epicsShareClass PVAuxInfo : private NoDefaultMethods {
|
||||
public:
|
||||
typedef std::map<String,PVScalarPtr> PVInfoMap;
|
||||
typedef std::map<String,PVScalarPtr>::iterator PVInfoIter;
|
||||
@@ -254,7 +258,7 @@ private:
|
||||
/**
|
||||
* This class is implemented by code that calls setPostHander
|
||||
*/
|
||||
class PostHandler
|
||||
class epicsShareClass PostHandler
|
||||
{
|
||||
public:
|
||||
POINTER_DEFINITIONS(PostHandler);
|
||||
@@ -272,7 +276,7 @@ public:
|
||||
* PVField is the base class for each PVData field.
|
||||
* Each PVData field has an interface that extends PVField.
|
||||
*/
|
||||
class PVField
|
||||
class epicsShareClass PVField
|
||||
: virtual public Serializable,
|
||||
public std::tr1::enable_shared_from_this<PVField>
|
||||
{
|
||||
@@ -424,12 +428,12 @@ private:
|
||||
friend class PVStructure;
|
||||
};
|
||||
|
||||
std::ostream& operator<<(std::ostream& o, const PVField& f);
|
||||
epicsShareExtern std::ostream& operator<<(std::ostream& o, const PVField& f);
|
||||
|
||||
/**
|
||||
* PVScalar is the base class for each scalar field.
|
||||
*/
|
||||
class PVScalar : public PVField {
|
||||
class epicsShareClass PVScalar : public PVField {
|
||||
// friend our child class(s) so that it
|
||||
// can call protected methods of other
|
||||
// PVScalar instances.
|
||||
@@ -608,7 +612,7 @@ typedef std::tr1::shared_ptr<PVDouble> PVDoublePtr;
|
||||
/**
|
||||
* PVString is special case, since it implements SerializableArray
|
||||
*/
|
||||
class PVString : public PVScalarValue<String>, SerializableArray {
|
||||
class epicsShareClass PVString : public PVScalarValue<String>, SerializableArray {
|
||||
public:
|
||||
/**
|
||||
* Destructor
|
||||
@@ -624,7 +628,7 @@ typedef std::tr1::shared_ptr<PVString> PVStringPtr;
|
||||
/**
|
||||
* PVArray is the base class for all array types, i.e. the scalarArray types and structureArray.
|
||||
*/
|
||||
class PVArray : public PVField, public SerializableArray {
|
||||
class epicsShareClass PVArray : public PVField, public SerializableArray {
|
||||
public:
|
||||
POINTER_DEFINITIONS(PVArray);
|
||||
/**
|
||||
@@ -676,7 +680,7 @@ private:
|
||||
friend class PVDataCreate;
|
||||
};
|
||||
|
||||
std::ostream& operator<<(format::array_at_internal const& manip, const PVArray& array);
|
||||
epicsShareExtern std::ostream& operator<<(format::array_at_internal const& manip, const PVArray& array);
|
||||
|
||||
/**
|
||||
* Class provided by caller of get
|
||||
@@ -707,7 +711,7 @@ public:
|
||||
/**
|
||||
* Base class for a scalarArray.
|
||||
*/
|
||||
class PVScalarArray : public PVArray {
|
||||
class epicsShareClass PVScalarArray : public PVArray {
|
||||
public:
|
||||
POINTER_DEFINITIONS(PVScalarArray);
|
||||
/**
|
||||
@@ -783,7 +787,7 @@ private:
|
||||
};
|
||||
|
||||
|
||||
class PVStructure : public PVField, public BitSetSerializable
|
||||
class epicsShareClass PVStructure : public PVField, public BitSetSerializable
|
||||
{
|
||||
public:
|
||||
POINTER_DEFINITIONS(PVStructure);
|
||||
@@ -1408,7 +1412,7 @@ typedef PVArrayData<PVStructurePtr> StructureArrayData;
|
||||
* Data class for a structureArray
|
||||
*/
|
||||
template<>
|
||||
class PVValueArray<PVStructurePtr> : public detail::PVVectorStorage<PVStructurePtr,PVArray>
|
||||
class epicsShareClass PVValueArray<PVStructurePtr> : public detail::PVVectorStorage<PVStructurePtr,PVArray>
|
||||
{
|
||||
typedef detail::PVVectorStorage<PVStructurePtr,PVArray> base_t;
|
||||
public:
|
||||
@@ -1506,7 +1510,7 @@ typedef PVArrayData<PVUnionPtr> UnionArrayData;
|
||||
* Data class for a unionArray
|
||||
*/
|
||||
template<>
|
||||
class PVValueArray<PVUnionPtr> : public detail::PVVectorStorage<PVUnionPtr,PVArray>
|
||||
class epicsShareClass PVValueArray<PVUnionPtr> : public detail::PVVectorStorage<PVUnionPtr,PVArray>
|
||||
{
|
||||
typedef detail::PVVectorStorage<PVUnionPtr,PVArray> base_t;
|
||||
public:
|
||||
@@ -1649,7 +1653,7 @@ typedef std::tr1::shared_ptr<PVStringArray> PVStringArrayPtr;
|
||||
/**
|
||||
* This is a singlton class for creating data instances.
|
||||
*/
|
||||
class PVDataCreate {
|
||||
class epicsShareClass PVDataCreate {
|
||||
public:
|
||||
static PVDataCreatePtr getPVDataCreate();
|
||||
/**
|
||||
@@ -1794,7 +1798,7 @@ private:
|
||||
* @param The PVDataCreate factory.
|
||||
*/
|
||||
|
||||
extern PVDataCreatePtr getPVDataCreate();
|
||||
epicsShareExtern PVDataCreatePtr getPVDataCreate();
|
||||
|
||||
#undef USAGE_DEPRECATED
|
||||
#undef USAGE_ERROR
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
*/
|
||||
#ifndef PVINTROSPECT_H
|
||||
#define PVINTROSPECT_H
|
||||
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
@@ -17,6 +18,8 @@
|
||||
#include <pv/byteBuffer.h>
|
||||
#include <pv/serialize.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class Field;
|
||||
@@ -99,13 +102,13 @@ namespace TypeFunc {
|
||||
* @param type The type.
|
||||
* @return The name for the type.
|
||||
*/
|
||||
const char* name(Type type);
|
||||
epicsShareExtern const char* name(Type type);
|
||||
/**
|
||||
* Convert the type to a string and add it to builder.
|
||||
* @param builder The string builder.
|
||||
* @param type The type.
|
||||
*/
|
||||
void toString(StringBuilder builder,const Type type);
|
||||
epicsShareExtern void toString(StringBuilder builder,const Type type);
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -173,53 +176,53 @@ namespace ScalarTypeFunc {
|
||||
* @param scalarType The type.
|
||||
* @return (false,true) if the scalarType is an integer.
|
||||
*/
|
||||
bool isInteger(ScalarType scalarType);
|
||||
epicsShareExtern bool isInteger(ScalarType scalarType);
|
||||
/**
|
||||
* Is the type an unsigned integer, i. e. is it one of ubyte,...ulong
|
||||
* @param scalarType The type.
|
||||
* @return (false,true) if the scalarType is an integer.
|
||||
*/
|
||||
bool isUInteger(ScalarType scalarType);
|
||||
epicsShareExtern bool isUInteger(ScalarType scalarType);
|
||||
/**
|
||||
* Is the type numeric, i. e. is it one of byte,...,double
|
||||
* @param scalarType The type.
|
||||
* @return (false,true) if the scalarType is a numeric
|
||||
*/
|
||||
bool isNumeric(ScalarType scalarType);
|
||||
epicsShareExtern bool isNumeric(ScalarType scalarType);
|
||||
/**
|
||||
* Is the type primitive, i. e. not string
|
||||
* @param scalarType The type.
|
||||
* @return (false,true) if the scalarType is primitive.
|
||||
*/
|
||||
bool isPrimitive(ScalarType scalarType);
|
||||
epicsShareExtern bool isPrimitive(ScalarType scalarType);
|
||||
/**
|
||||
* Get the scalarType for value.
|
||||
* @param value The name of the scalar type.
|
||||
* @return The scalarType.
|
||||
* An exception is thrown if the name is not the name of a scalar type.
|
||||
*/
|
||||
ScalarType getScalarType(String const &value);
|
||||
epicsShareExtern ScalarType getScalarType(String const &value);
|
||||
/**
|
||||
* Get a name for the scalarType.
|
||||
* @param scalarType The type.
|
||||
* @return The name for the scalarType.
|
||||
*/
|
||||
const char* name(ScalarType scalarType);
|
||||
epicsShareExtern const char* name(ScalarType scalarType);
|
||||
/**
|
||||
* Convert the scalarType to a string and add it to builder.
|
||||
* @param builder The string builder.
|
||||
* @param scalarType The type.
|
||||
*/
|
||||
void toString(StringBuilder builder,ScalarType scalarType);
|
||||
epicsShareExtern void toString(StringBuilder builder,ScalarType scalarType);
|
||||
|
||||
//! gives sizeof(T) where T depends on the scalar type id.
|
||||
size_t elementSize(ScalarType id);
|
||||
epicsShareExtern size_t elementSize(ScalarType id);
|
||||
};
|
||||
|
||||
/**
|
||||
* This class implements introspection object for field.
|
||||
*/
|
||||
class Field :
|
||||
class epicsShareClass Field :
|
||||
virtual public Serializable,
|
||||
public std::tr1::enable_shared_from_this<Field> {
|
||||
public:
|
||||
@@ -272,7 +275,7 @@ private:
|
||||
/**
|
||||
* This class implements introspection object for Scalar.
|
||||
*/
|
||||
class Scalar : public Field{
|
||||
class epicsShareClass Scalar : public Field{
|
||||
public:
|
||||
POINTER_DEFINITIONS(Scalar);
|
||||
/**
|
||||
@@ -314,7 +317,7 @@ private:
|
||||
/**
|
||||
* This class implements introspection object for field.
|
||||
*/
|
||||
class ScalarArray : public Field{
|
||||
class epicsShareClass ScalarArray : public Field{
|
||||
public:
|
||||
POINTER_DEFINITIONS(ScalarArray);
|
||||
typedef ScalarArray& reference;
|
||||
@@ -362,7 +365,7 @@ private:
|
||||
/**
|
||||
* This class implements introspection object for a structureArray
|
||||
*/
|
||||
class StructureArray : public Field{
|
||||
class epicsShareClass StructureArray : public Field{
|
||||
public:
|
||||
POINTER_DEFINITIONS(StructureArray);
|
||||
typedef StructureArray& reference;
|
||||
@@ -404,7 +407,7 @@ private:
|
||||
/**
|
||||
* This class implements introspection object for a unionArray
|
||||
*/
|
||||
class UnionArray : public Field{
|
||||
class epicsShareClass UnionArray : public Field{
|
||||
public:
|
||||
POINTER_DEFINITIONS(UnionArray);
|
||||
typedef UnionArray& reference;
|
||||
@@ -446,7 +449,7 @@ private:
|
||||
/**
|
||||
* This class implements introspection object for a structure.
|
||||
*/
|
||||
class Structure : public Field {
|
||||
class epicsShareClass Structure : public Field {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Structure);
|
||||
|
||||
@@ -536,7 +539,7 @@ private:
|
||||
/**
|
||||
* This class implements introspection object for a union.
|
||||
*/
|
||||
class Union : public Field {
|
||||
class epicsShareClass Union : public Field {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Union);
|
||||
|
||||
@@ -649,7 +652,7 @@ typedef std::tr1::shared_ptr<FieldBuilder> FieldBuilderPtr;
|
||||
* An instance of this object must not be used concurrently (an object has a state).
|
||||
* @author mse
|
||||
*/
|
||||
class FieldBuilder :
|
||||
class epicsShareClass FieldBuilder :
|
||||
public std::tr1::enable_shared_from_this<FieldBuilder>
|
||||
{
|
||||
public:
|
||||
@@ -781,7 +784,7 @@ private:
|
||||
|
||||
};
|
||||
|
||||
class FieldCreate {
|
||||
class epicsShareClass FieldCreate {
|
||||
public:
|
||||
static FieldCreatePtr getFieldCreate();
|
||||
/**
|
||||
@@ -908,7 +911,7 @@ private:
|
||||
* Get the single class that implemnents FieldCreate,
|
||||
* @param The fieldCreate factory.
|
||||
*/
|
||||
extern FieldCreatePtr getFieldCreate();
|
||||
epicsShareExtern FieldCreatePtr getFieldCreate();
|
||||
|
||||
/** Define a compile time mapping from
|
||||
* type to enum value.
|
||||
|
||||
@@ -10,8 +10,11 @@
|
||||
*/
|
||||
#ifndef PVSUBARRAYCOPY_H
|
||||
#define PVSUBARRAYCOPY_H
|
||||
|
||||
#include <pv/pvData.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
/** @brief Copy a subarray from one PVValueArray to another.
|
||||
@@ -38,7 +41,7 @@ void copy(
|
||||
* @param toOffset The offset in the destination
|
||||
* @param len The total number of elements to copy
|
||||
*/
|
||||
void copy(
|
||||
epicsShareExtern void copy(
|
||||
PVScalarArray & from,
|
||||
size_t fromOffset,
|
||||
PVScalarArray & to,
|
||||
@@ -54,7 +57,7 @@ void copy(
|
||||
* @param toOffset The offset in the destination
|
||||
* @param len The total number of elements to copy
|
||||
*/
|
||||
void copy(
|
||||
epicsShareExtern void copy(
|
||||
PVStructureArray & from,
|
||||
size_t fromOffset,
|
||||
PVStructureArray & to,
|
||||
@@ -70,7 +73,7 @@ void copy(
|
||||
* @param toOffset The offset in the destination
|
||||
* @param len The total number of elements to copy
|
||||
*/
|
||||
void copy(
|
||||
epicsShareExtern void copy(
|
||||
PVArray & from,
|
||||
size_t fromOffset,
|
||||
PVArray & to,
|
||||
|
||||
@@ -10,10 +10,14 @@
|
||||
*/
|
||||
#ifndef STANDARDFIELD_H
|
||||
#define STANDARDFIELD_H
|
||||
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
#include <pv/pvIntrospect.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
/**
|
||||
@@ -57,7 +61,7 @@ namespace epics { namespace pvData {
|
||||
class StandardField;
|
||||
typedef std::tr1::shared_ptr<StandardField> StandardFieldPtr;
|
||||
|
||||
class StandardField {
|
||||
class epicsShareClass StandardField {
|
||||
public:
|
||||
static StandardFieldPtr getStandardField();
|
||||
~StandardField();
|
||||
@@ -124,7 +128,7 @@ private:
|
||||
friend StandardFieldPtr getStandardField();
|
||||
};
|
||||
|
||||
extern StandardFieldPtr getStandardField();
|
||||
epicsShareExtern StandardFieldPtr getStandardField();
|
||||
|
||||
}}
|
||||
#endif /* STANDARDFIELD_H */
|
||||
|
||||
@@ -9,12 +9,16 @@
|
||||
*/
|
||||
#ifndef STANDARDPVFIELD_H
|
||||
#define STANDARDPVFIELD_H
|
||||
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
|
||||
#include <pv/pvIntrospect.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/standardField.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
/**
|
||||
* StandardPVField is a class or creating standard data fields.
|
||||
@@ -31,7 +35,7 @@ namespace epics { namespace pvData {
|
||||
class StandardPVField;
|
||||
typedef std::tr1::shared_ptr<StandardPVField> StandardPVFieldPtr;
|
||||
|
||||
class StandardPVField : private NoDefaultMethods {
|
||||
class epicsShareClass StandardPVField : private NoDefaultMethods {
|
||||
public:
|
||||
static StandardPVFieldPtr getStandardPVField();
|
||||
~StandardPVField();
|
||||
@@ -48,7 +52,7 @@ private:
|
||||
String notImplemented;
|
||||
};
|
||||
|
||||
extern StandardPVFieldPtr getStandardPVField();
|
||||
epicsShareExtern StandardPVFieldPtr getStandardPVField();
|
||||
|
||||
}}
|
||||
#endif /* STANDARDPVFIELD_H */
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
/**
|
||||
* @author mrk
|
||||
*/
|
||||
#define epicsExportSharedSymbols
|
||||
#include <pv/noDefaultMethods.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/bitSetUtil.h>
|
||||
|
||||
@@ -9,13 +9,16 @@
|
||||
*/
|
||||
#ifndef BITSETUTIL_H
|
||||
#define BITSETUTIL_H
|
||||
|
||||
#include <pv/noDefaultMethods.h>
|
||||
#include <pv/pvData.h>
|
||||
#include <pv/bitSet.h>
|
||||
|
||||
#include <sharelib.h>
|
||||
|
||||
namespace epics { namespace pvData {
|
||||
|
||||
class BitSetUtil : private NoDefaultMethods {
|
||||
class epicsShareClass BitSetUtil : private NoDefaultMethods {
|
||||
public:
|
||||
static bool compress(BitSetPtr const &bitSet,PVStructurePtr const &pvStructure);
|
||||
};
|
||||
|
||||
@@ -67,7 +67,7 @@ public:
|
||||
buffer->align(alignment);
|
||||
}
|
||||
|
||||
virtual bool directSerialize(ByteBuffer */*existingBuffer*/, const char* /*toSerialize*/,
|
||||
virtual bool directSerialize(ByteBuffer* /*existingBuffer*/, const char* /*toSerialize*/,
|
||||
std::size_t /*elementCount*/, std::size_t /*elementSize*/)
|
||||
{
|
||||
return false;
|
||||
@@ -95,7 +95,7 @@ public:
|
||||
buffer->align(alignment);
|
||||
}
|
||||
|
||||
virtual bool directDeserialize(ByteBuffer */*existingBuffer*/, char* /*deserializeTo*/,
|
||||
virtual bool directDeserialize(ByteBuffer* /*existingBuffer*/, char* /*deserializeTo*/,
|
||||
std::size_t /*elementCount*/, std::size_t /*elementSize*/)
|
||||
{
|
||||
return false;
|
||||
|
||||
@@ -48,7 +48,7 @@ static String allProperties("alarm,timeStamp,display,control");
|
||||
static PVStructurePtr doubleRecord;
|
||||
static PVStructurePtr enumeratedRecord;
|
||||
|
||||
static void createRecords(FILE * fd,FILE */*auxfd*/)
|
||||
static void createRecords(FILE * fd,FILE* /*auxfd*/)
|
||||
{
|
||||
doubleRecord = standardPVField->scalar(pvDouble,allProperties);
|
||||
if(debug) {
|
||||
@@ -70,7 +70,7 @@ static void createRecords(FILE * fd,FILE */*auxfd*/)
|
||||
}
|
||||
}
|
||||
|
||||
static void printRecords(FILE * fd,FILE */*auxfd*/)
|
||||
static void printRecords(FILE * fd,FILE* /*auxfd*/)
|
||||
{
|
||||
fprintf(fd,"doubleRecord\n");
|
||||
builder.clear();
|
||||
@@ -82,7 +82,7 @@ static void printRecords(FILE * fd,FILE */*auxfd*/)
|
||||
fprintf(fd,"%s\n",builder.c_str());
|
||||
}
|
||||
|
||||
static void testAlarm(FILE * fd,FILE */*auxfd*/)
|
||||
static void testAlarm(FILE * fd,FILE* /*auxfd*/)
|
||||
{
|
||||
if(debug) fprintf(fd,"testAlarm\n");
|
||||
Alarm alarm;
|
||||
@@ -155,7 +155,7 @@ static void testTimeStamp(FILE * fd,FILE *auxfd)
|
||||
fprintf(fd,"testTimeStamp PASSED\n");
|
||||
}
|
||||
|
||||
static void testControl(FILE * fd,FILE */*auxfd*/)
|
||||
static void testControl(FILE * fd,FILE* /*auxfd*/)
|
||||
{
|
||||
if(debug) fprintf(fd,"testControl\n");
|
||||
Control control;
|
||||
@@ -182,7 +182,7 @@ static void testControl(FILE * fd,FILE */*auxfd*/)
|
||||
fprintf(fd,"testControl PASSED\n");
|
||||
}
|
||||
|
||||
static void testDisplay(FILE * fd,FILE */*auxfd*/)
|
||||
static void testDisplay(FILE * fd,FILE* /*auxfd*/)
|
||||
{
|
||||
if(debug) fprintf(fd,"testDisplay\n");
|
||||
Display display;
|
||||
@@ -215,7 +215,7 @@ static void testDisplay(FILE * fd,FILE */*auxfd*/)
|
||||
fprintf(fd,"testDisplay PASSED\n");
|
||||
}
|
||||
|
||||
static void testEnumerated(FILE * fd,FILE */*auxfd*/)
|
||||
static void testEnumerated(FILE * fd,FILE* /*auxfd*/)
|
||||
{
|
||||
if(debug) fprintf(fd,"testEnumerated\n");
|
||||
PVEnumerated pvEnumerated;
|
||||
|
||||
Reference in New Issue
Block a user