merge
This commit is contained in:
@@ -24,6 +24,7 @@
|
||||
# define INSTALL_LOCATION here
|
||||
#INSTALL_LOCATION=<fullpathname>
|
||||
|
||||
USR_INCLUDES += -I/usr/include/boost/tr1
|
||||
INSTALL_INCLUDE = $(INSTALL_LOCATION)/include/pv
|
||||
USR_INCLUDES += -I $(INSTALL_LOCATION)/include
|
||||
|
||||
|
||||
@@ -704,11 +704,11 @@ int8 Convert::toByte(PVScalar * pv)
|
||||
}
|
||||
case pvFloat: {
|
||||
PVFloat *value = static_cast<PVFloat *>(pv);
|
||||
return value->get();
|
||||
return static_cast<int8>(value->get());
|
||||
}
|
||||
case pvDouble: {
|
||||
PVDouble *value = static_cast<PVDouble *>(pv);
|
||||
return value->get();
|
||||
return static_cast<int8>(value->get());
|
||||
}
|
||||
case pvString:
|
||||
throw std::logic_error(String("string can not be converted to byte"));
|
||||
@@ -741,11 +741,11 @@ int16 Convert::toShort(PVScalar * pv)
|
||||
}
|
||||
case pvFloat: {
|
||||
PVFloat *value = static_cast<PVFloat *>(pv);
|
||||
return value->get();
|
||||
return static_cast<int16>(value->get());
|
||||
}
|
||||
case pvDouble: {
|
||||
PVDouble *value = static_cast<PVDouble *>(pv);
|
||||
return value->get();
|
||||
return static_cast<int16>(value->get());
|
||||
}
|
||||
case pvString:
|
||||
throw std::logic_error(String("string can not be converted to short"));
|
||||
@@ -778,11 +778,11 @@ int32 Convert::toInt(PVScalar * pv)
|
||||
}
|
||||
case pvFloat: {
|
||||
PVFloat *value = static_cast<PVFloat *>(pv);
|
||||
return value->get();
|
||||
return static_cast<int32>(value->get());
|
||||
}
|
||||
case pvDouble: {
|
||||
PVDouble *value = static_cast<PVDouble *>(pv);
|
||||
return value->get();
|
||||
return static_cast<int32>(value->get());
|
||||
}
|
||||
case pvString:
|
||||
throw std::logic_error(String("string can not be converted to int"));
|
||||
@@ -815,11 +815,11 @@ int64 Convert::toLong(PVScalar * pv)
|
||||
}
|
||||
case pvFloat: {
|
||||
PVFloat *value = static_cast<PVFloat *>(pv);
|
||||
return value->get();
|
||||
return static_cast<int64>(value->get());
|
||||
}
|
||||
case pvDouble: {
|
||||
PVDouble *value = static_cast<PVDouble *>(pv);
|
||||
return value->get();
|
||||
return static_cast<int64>(value->get());
|
||||
}
|
||||
case pvString:
|
||||
throw std::logic_error(String("string can not be converted to long"));
|
||||
@@ -1143,19 +1143,19 @@ void Convert::fromFloat(PVScalar* pv, float from)
|
||||
throw std::logic_error(String("float can not be converted to boolean"));
|
||||
case pvByte: {
|
||||
PVByte *value = static_cast<PVByte *>(pv);
|
||||
value->put(from); return;
|
||||
value->put(static_cast<int8>(from)); return;
|
||||
}
|
||||
case pvShort: {
|
||||
PVShort *value = static_cast<PVShort *>(pv);
|
||||
value->put(from); return;
|
||||
value->put(static_cast<int16>(from)); return;
|
||||
}
|
||||
case pvInt: {
|
||||
PVInt *value = static_cast<PVInt *>(pv);
|
||||
value->put(from); return;
|
||||
value->put(static_cast<int32>(from)); return;
|
||||
}
|
||||
case pvLong: {
|
||||
PVLong *value = static_cast<PVLong *>(pv);
|
||||
value->put(from); return;
|
||||
value->put(static_cast<int64>(from)); return;
|
||||
}
|
||||
case pvFloat: {
|
||||
PVFloat *value = static_cast<PVFloat *>(pv);
|
||||
@@ -1187,19 +1187,19 @@ void Convert::fromDouble(PVScalar *pv, double from)
|
||||
throw std::logic_error(String("double can not be converted to boolean"));
|
||||
case pvByte: {
|
||||
PVByte *value = static_cast<PVByte *>(pv);
|
||||
value->put(from); return;
|
||||
value->put(static_cast<int8>(from)); return;
|
||||
}
|
||||
case pvShort: {
|
||||
PVShort *value = static_cast<PVShort *>(pv);
|
||||
value->put(from); return;
|
||||
value->put(static_cast<int16>(from)); return;
|
||||
}
|
||||
case pvInt: {
|
||||
PVInt *value = static_cast<PVInt *>(pv);
|
||||
value->put(from); return;
|
||||
value->put(static_cast<int32>(from)); return;
|
||||
}
|
||||
case pvLong: {
|
||||
PVLong *value = static_cast<PVLong *>(pv);
|
||||
value->put(from); return;
|
||||
value->put(static_cast<int64>(from)); return;
|
||||
}
|
||||
case pvFloat: {
|
||||
PVFloat *value = static_cast<PVFloat *>(pv);
|
||||
@@ -1739,7 +1739,7 @@ int convertToByteArray(PVScalarArray * pv, int offset, int len,int8 to[], int to
|
||||
FloatArray dataArray = data.data;
|
||||
int dataOffset = data.offset;
|
||||
for (int i = 0; i < num; i++)
|
||||
to[i + toOffset] = dataArray[i + dataOffset];
|
||||
to[i + toOffset] = static_cast<int8>(dataArray[i + dataOffset]);
|
||||
len -= num;
|
||||
offset += num;
|
||||
toOffset += num;
|
||||
@@ -1757,7 +1757,7 @@ int convertToByteArray(PVScalarArray * pv, int offset, int len,int8 to[], int to
|
||||
DoubleArray dataArray = data.data;
|
||||
int dataOffset = data.offset;
|
||||
for (int i = 0; i < num; i++)
|
||||
to[i + toOffset] = dataArray[i + dataOffset];
|
||||
to[i + toOffset] = static_cast<int8>(dataArray[i + dataOffset]);
|
||||
len -= num;
|
||||
offset += num;
|
||||
toOffset += num;
|
||||
@@ -1962,7 +1962,7 @@ int convertToShortArray(PVScalarArray * pv, int offset, int len,int16 to[], int
|
||||
FloatArray dataArray = data.data;
|
||||
int dataOffset = data.offset;
|
||||
for (int i = 0; i < num; i++)
|
||||
to[i + toOffset] = dataArray[i + dataOffset];
|
||||
to[i + toOffset] = static_cast<int16>(dataArray[i + dataOffset]);
|
||||
len -= num;
|
||||
offset += num;
|
||||
toOffset += num;
|
||||
@@ -1980,7 +1980,7 @@ int convertToShortArray(PVScalarArray * pv, int offset, int len,int16 to[], int
|
||||
DoubleArray dataArray = data.data;
|
||||
int dataOffset = data.offset;
|
||||
for (int i = 0; i < num; i++)
|
||||
to[i + toOffset] = dataArray[i + dataOffset];
|
||||
to[i + toOffset] = static_cast<int16>(dataArray[i + dataOffset]);
|
||||
len -= num;
|
||||
offset += num;
|
||||
toOffset += num;
|
||||
@@ -2185,7 +2185,7 @@ int convertToIntArray(PVScalarArray * pv, int offset, int len,int32 to[], int to
|
||||
FloatArray dataArray = data.data;
|
||||
int dataOffset = data.offset;
|
||||
for (int i = 0; i < num; i++)
|
||||
to[i + toOffset] = dataArray[i + dataOffset];
|
||||
to[i + toOffset] = static_cast<int32>(dataArray[i + dataOffset]);
|
||||
len -= num;
|
||||
offset += num;
|
||||
toOffset += num;
|
||||
@@ -2203,7 +2203,7 @@ int convertToIntArray(PVScalarArray * pv, int offset, int len,int32 to[], int to
|
||||
DoubleArray dataArray = data.data;
|
||||
int dataOffset = data.offset;
|
||||
for (int i = 0; i < num; i++)
|
||||
to[i + toOffset] = dataArray[i + dataOffset];
|
||||
to[i + toOffset] = static_cast<int32>(dataArray[i + dataOffset]);
|
||||
len -= num;
|
||||
offset += num;
|
||||
toOffset += num;
|
||||
@@ -2408,7 +2408,7 @@ int convertToLongArray(PVScalarArray * pv, int offset, int len,int64 to[], int t
|
||||
FloatArray dataArray = data.data;
|
||||
int dataOffset = data.offset;
|
||||
for (int i = 0; i < num; i++)
|
||||
to[i + toOffset] = dataArray[i + dataOffset];
|
||||
to[i + toOffset] = static_cast<int64>(dataArray[i + dataOffset]);
|
||||
len -= num;
|
||||
offset += num;
|
||||
toOffset += num;
|
||||
@@ -2426,7 +2426,7 @@ int convertToLongArray(PVScalarArray * pv, int offset, int len,int64 to[], int t
|
||||
DoubleArray dataArray = data.data;
|
||||
int dataOffset = data.offset;
|
||||
for (int i = 0; i < num; i++)
|
||||
to[i + toOffset] = dataArray[i + dataOffset];
|
||||
to[i + toOffset] = static_cast<int64>(dataArray[i + dataOffset]);
|
||||
len -= num;
|
||||
offset += num;
|
||||
toOffset += num;
|
||||
@@ -2456,7 +2456,7 @@ int convertFromFloatArray(PVScalarArray *pv, int offset, int len,float from[], i
|
||||
PVByteArray *pvdata = static_cast<PVByteArray*>(pv);
|
||||
int8 data[1];
|
||||
while (len > 0) {
|
||||
data[0] = from[fromOffset];
|
||||
data[0] = static_cast<int8>(from[fromOffset]);
|
||||
if (pvdata->put(offset, 1, data, 0) == 0)
|
||||
return ntransfered;
|
||||
--len;
|
||||
@@ -2470,7 +2470,7 @@ int convertFromFloatArray(PVScalarArray *pv, int offset, int len,float from[], i
|
||||
PVShortArray *pvdata = static_cast<PVShortArray*>(pv);
|
||||
int16 data[1];
|
||||
while (len > 0) {
|
||||
data[0] = from[fromOffset];
|
||||
data[0] = static_cast<int16>(from[fromOffset]);
|
||||
if (pvdata->put(offset, 1, data, 0) == 0)
|
||||
return ntransfered;
|
||||
--len;
|
||||
@@ -2484,7 +2484,7 @@ int convertFromFloatArray(PVScalarArray *pv, int offset, int len,float from[], i
|
||||
PVIntArray *pvdata = static_cast<PVIntArray*>(pv);
|
||||
int32 data[1];
|
||||
while (len > 0) {
|
||||
data[0] = from[fromOffset];
|
||||
data[0] = static_cast<int32>(from[fromOffset]);
|
||||
if (pvdata->put(offset, 1, data, 0) == 0)
|
||||
return ntransfered;
|
||||
--len;
|
||||
@@ -2498,7 +2498,7 @@ int convertFromFloatArray(PVScalarArray *pv, int offset, int len,float from[], i
|
||||
PVLongArray *pvdata = static_cast<PVLongArray*>(pv);
|
||||
int64 data[1];
|
||||
while (len > 0) {
|
||||
data[0] = from[fromOffset];
|
||||
data[0] = static_cast<int64>(from[fromOffset]);
|
||||
if (pvdata->put(offset, 1, data, 0) == 0)
|
||||
return ntransfered;
|
||||
--len;
|
||||
@@ -2679,7 +2679,7 @@ int convertFromDoubleArray(PVScalarArray *pv, int offset, int len,double from[],
|
||||
PVByteArray *pvdata = static_cast<PVByteArray*>(pv);
|
||||
int8 data[1];
|
||||
while (len > 0) {
|
||||
data[0] = from[fromOffset];
|
||||
data[0] = static_cast<int8>(from[fromOffset]);
|
||||
if (pvdata->put(offset, 1, data, 0) == 0)
|
||||
return ntransfered;
|
||||
--len;
|
||||
@@ -2693,7 +2693,7 @@ int convertFromDoubleArray(PVScalarArray *pv, int offset, int len,double from[],
|
||||
PVShortArray *pvdata = static_cast<PVShortArray*>(pv);
|
||||
int16 data[1];
|
||||
while (len > 0) {
|
||||
data[0] = from[fromOffset];
|
||||
data[0] = static_cast<int16>(from[fromOffset]);
|
||||
if (pvdata->put(offset, 1, data, 0) == 0)
|
||||
return ntransfered;
|
||||
--len;
|
||||
@@ -2707,7 +2707,7 @@ int convertFromDoubleArray(PVScalarArray *pv, int offset, int len,double from[],
|
||||
PVIntArray *pvdata = static_cast<PVIntArray*>(pv);
|
||||
int32 data[1];
|
||||
while (len > 0) {
|
||||
data[0] = from[fromOffset];
|
||||
data[0] = static_cast<int32>(from[fromOffset]);
|
||||
if (pvdata->put(offset, 1, data, 0) == 0)
|
||||
return ntransfered;
|
||||
--len;
|
||||
@@ -2721,7 +2721,7 @@ int convertFromDoubleArray(PVScalarArray *pv, int offset, int len,double from[],
|
||||
PVLongArray *pvdata = static_cast<PVLongArray*>(pv);
|
||||
int64 data[1];
|
||||
while (len > 0) {
|
||||
data[0] = from[fromOffset];
|
||||
data[0] = static_cast<int64>(from[fromOffset]);
|
||||
if (pvdata->put(offset, 1, data, 0) == 0)
|
||||
return ntransfered;
|
||||
--len;
|
||||
|
||||
@@ -22,6 +22,7 @@ namespace epics { namespace pvData {
|
||||
class MonitorElement {
|
||||
public:
|
||||
POINTER_DEFINITIONS(MonitorElement);
|
||||
virtual ~MonitorElement(){}
|
||||
/**
|
||||
* Get the PVStructure.
|
||||
* @return The PVStructure.
|
||||
@@ -47,6 +48,7 @@ namespace epics { namespace pvData {
|
||||
class Monitor : public Destroyable, private NoDefaultMethods {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Monitor);
|
||||
virtual ~Monitor(){}
|
||||
/**
|
||||
* Start monitoring.
|
||||
* @return completion status.
|
||||
@@ -78,6 +80,7 @@ namespace epics { namespace pvData {
|
||||
class MonitorRequester : public virtual Requester {
|
||||
public:
|
||||
POINTER_DEFINITIONS(MonitorRequester);
|
||||
virtual ~MonitorRequester(){}
|
||||
/**
|
||||
* The client and server have both completed the createMonitor request.
|
||||
* @param status Completion status.
|
||||
|
||||
@@ -156,8 +156,8 @@ TimeStamp & TimeStamp::operator-=(int64 seconds)
|
||||
|
||||
TimeStamp & TimeStamp::operator+=(double seconds)
|
||||
{
|
||||
int64 secs = seconds;
|
||||
int64 nano = (seconds - secs)*1e9;
|
||||
int64 secs = static_cast<int64>(seconds);
|
||||
int64 nano = static_cast<int64>((seconds - secs)*1e9);
|
||||
nanoSeconds += nano;
|
||||
if(nanoSeconds>nanoSecPerSec) {
|
||||
nanoSeconds -= nanoSecPerSec;
|
||||
|
||||
@@ -53,6 +53,7 @@ private:
|
||||
|
||||
class PostHandler {
|
||||
public:
|
||||
virtual ~PostHandler(){}
|
||||
virtual void postPut() = 0;
|
||||
};
|
||||
|
||||
|
||||
@@ -62,6 +62,7 @@ namespace ScalarTypeFunc {
|
||||
class Field : public std::tr1::enable_shared_from_this<Field> {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Field);
|
||||
virtual ~Field();
|
||||
String getFieldName() const{return m_fieldName;}
|
||||
Type getType() const{return m_type;}
|
||||
virtual void toString(StringBuilder buf) const{toString(buf,0);}
|
||||
@@ -69,7 +70,6 @@ public:
|
||||
void renameField(String newName);
|
||||
protected:
|
||||
Field(String fieldName,Type type);
|
||||
virtual ~Field();
|
||||
private:
|
||||
String m_fieldName;
|
||||
Type m_type;
|
||||
@@ -88,6 +88,7 @@ private:
|
||||
class Scalar : public Field{
|
||||
public:
|
||||
POINTER_DEFINITIONS(Scalar);
|
||||
virtual ~Scalar();
|
||||
typedef Scalar& reference;
|
||||
typedef const Scalar& const_reference;
|
||||
|
||||
@@ -96,7 +97,6 @@ public:
|
||||
virtual void toString(StringBuilder buf,int indentLevel) const;
|
||||
protected:
|
||||
Scalar(String fieldName,ScalarType scalarType);
|
||||
virtual ~Scalar();
|
||||
private:
|
||||
ScalarType scalarType;
|
||||
friend class FieldCreate;
|
||||
@@ -105,6 +105,7 @@ private:
|
||||
class ScalarArray : public Field{
|
||||
public:
|
||||
POINTER_DEFINITIONS(ScalarArray);
|
||||
ScalarArray(String fieldName,ScalarType scalarType);
|
||||
typedef ScalarArray& reference;
|
||||
typedef const ScalarArray& const_reference;
|
||||
|
||||
@@ -112,7 +113,6 @@ public:
|
||||
virtual void toString(StringBuilder buf) const{toString(buf,0);}
|
||||
virtual void toString(StringBuilder buf,int indentLevel) const;
|
||||
protected:
|
||||
ScalarArray(String fieldName,ScalarType scalarType);
|
||||
virtual ~ScalarArray();
|
||||
private:
|
||||
ScalarType elementType;
|
||||
@@ -133,13 +133,14 @@ protected:
|
||||
StructureArray(String fieldName,StructureConstPtr structure);
|
||||
virtual ~StructureArray();
|
||||
private:
|
||||
StructureConstPtr pstructure;
|
||||
StructureConstPtr pstructure;
|
||||
friend class FieldCreate;
|
||||
};
|
||||
|
||||
class Structure : public Field {
|
||||
public:
|
||||
POINTER_DEFINITIONS(Structure);
|
||||
virtual ~Structure();
|
||||
typedef Structure& reference;
|
||||
typedef const Structure& const_reference;
|
||||
|
||||
@@ -154,7 +155,6 @@ public:
|
||||
virtual void toString(StringBuilder buf,int indentLevel) const;
|
||||
protected:
|
||||
Structure(String fieldName, int numberFields,FieldConstPtrArray fields);
|
||||
virtual ~Structure();
|
||||
private:
|
||||
int numberFields;
|
||||
FieldConstPtrArray fields;
|
||||
|
||||
@@ -5,7 +5,7 @@ There is a logic_error
|
||||
On line 68 of ../testBaseException.cpp
|
||||
../bin/linux-x86/testBaseException[0x80497b9]
|
||||
../bin/linux-x86/testBaseException[0x8049a54]
|
||||
/lib/libc.so.6(__libc_start_main+0xe6)[0x126e36]
|
||||
/lib/libc.so.6(__libc_start_main+0xe6)[0x3aae36]
|
||||
../bin/linux-x86/testBaseException[0x80490e1]
|
||||
To translate run 'addr2line -e execname 0xXXXXXXX ...'
|
||||
Note: Must be compiled with debug symbols
|
||||
@@ -17,7 +17,7 @@ On line 75 of ../testBaseException.cpp
|
||||
../bin/linux-x86/testBaseException() [0x8049cec]
|
||||
../bin/linux-x86/testBaseException() [0x8049923]
|
||||
../bin/linux-x86/testBaseException() [0x8049a54]
|
||||
/lib/libc.so.6(__libc_start_main+0xe6) [0x126e36]
|
||||
/lib/libc.so.6(__libc_start_main+0xe6) [0x3aae36]
|
||||
../bin/linux-x86/testBaseException() [0x80490e1]
|
||||
|
||||
testBaseException...
|
||||
@@ -26,7 +26,7 @@ all is OK
|
||||
On line 48 of ../testBaseException.cpp
|
||||
../bin/linux-x86/testBaseException() [0x8049581]
|
||||
../bin/linux-x86/testBaseException() [0x8049a5c]
|
||||
/lib/libc.so.6(__libc_start_main+0xe6) [0x126e36]
|
||||
/lib/libc.so.6(__libc_start_main+0xe6) [0x3aae36]
|
||||
../bin/linux-x86/testBaseException() [0x80490e1]
|
||||
|
||||
|
||||
@@ -38,7 +38,7 @@ On line 57 of ../testBaseException.cpp
|
||||
../bin/linux-x86/testBaseException() [0x80491ec]
|
||||
../bin/linux-x86/testBaseException() [0x80496f9]
|
||||
../bin/linux-x86/testBaseException() [0x8049a5c]
|
||||
/lib/libc.so.6(__libc_start_main+0xe6) [0x126e36]
|
||||
/lib/libc.so.6(__libc_start_main+0xe6) [0x3aae36]
|
||||
../bin/linux-x86/testBaseException() [0x80490e1]
|
||||
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
--- testBaseExceptionGold 2011-04-27 13:11:55.000000000 -0400
|
||||
+++ testBaseException 2011-06-07 07:20:29.000000000 -0400
|
||||
+++ testBaseException 2011-08-30 09:31:21.000000000 -0400
|
||||
@@ -1,37 +1,46 @@
|
||||
+
|
||||
+
|
||||
@@ -8,7 +8,7 @@
|
||||
+On line 68 of ../testBaseException.cpp
|
||||
+../bin/linux-x86/testBaseException[0x80497b9]
|
||||
+../bin/linux-x86/testBaseException[0x8049a54]
|
||||
+/lib/libc.so.6(__libc_start_main+0xe6)[0x126e36]
|
||||
+/lib/libc.so.6(__libc_start_main+0xe6)[0x3aae36]
|
||||
+../bin/linux-x86/testBaseException[0x80490e1]
|
||||
+To translate run 'addr2line -e execname 0xXXXXXXX ...'
|
||||
+ Note: Must be compiled with debug symbols
|
||||
@@ -20,7 +20,7 @@
|
||||
+../bin/linux-x86/testBaseException() [0x8049cec]
|
||||
+../bin/linux-x86/testBaseException() [0x8049923]
|
||||
+../bin/linux-x86/testBaseException() [0x8049a54]
|
||||
+/lib/libc.so.6(__libc_start_main+0xe6) [0x126e36]
|
||||
+/lib/libc.so.6(__libc_start_main+0xe6) [0x3aae36]
|
||||
+../bin/linux-x86/testBaseException() [0x80490e1]
|
||||
+
|
||||
testBaseException...
|
||||
@@ -34,7 +34,7 @@
|
||||
+On line 48 of ../testBaseException.cpp
|
||||
+../bin/linux-x86/testBaseException() [0x8049581]
|
||||
+../bin/linux-x86/testBaseException() [0x8049a5c]
|
||||
+/lib/libc.so.6(__libc_start_main+0xe6) [0x126e36]
|
||||
+/lib/libc.so.6(__libc_start_main+0xe6) [0x3aae36]
|
||||
+../bin/linux-x86/testBaseException() [0x80490e1]
|
||||
+
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
+../bin/linux-x86/testBaseException() [0x80491ec]
|
||||
+../bin/linux-x86/testBaseException() [0x80496f9]
|
||||
+../bin/linux-x86/testBaseException() [0x8049a5c]
|
||||
+/lib/libc.so.6(__libc_start_main+0xe6) [0x126e36]
|
||||
+/lib/libc.so.6(__libc_start_main+0xe6) [0x3aae36]
|
||||
+../bin/linux-x86/testBaseException() [0x80490e1]
|
||||
+
|
||||
|
||||
|
||||
Reference in New Issue
Block a user