Pleora Technologies Inc. eBUS SDK v7.0.1.7536 API



Loading...
Searching...
No Matches
PvConfigurationReader.h
1// *****************************************************************************
2//
3// Copyright (c) 2008, Pleora Technologies Inc., All rights reserved.
4//
5// *****************************************************************************
6
7#ifndef __PVCONFIGURATIONREADER_H__
8#define __PVCONFIGURATIONREADER_H__
9
10#include <PvPersistenceLib.h>
11#include <PvDevice.h>
12#include <PvStream.h>
13#include <PvStringList.h>
14#include <PvPropertyList.h>
15
16
17namespace PvPersistenceLib
18{
19 class ConfigurationReader;
20}
21
29{
30public:
31
35 PV_PERSISTENCE_API PvConfigurationReader();
36
40 PV_PERSISTENCE_API ~PvConfigurationReader();
41
49 PV_PERSISTENCE_API PvResult Load( const PvString &aFilename );
50
58 PV_PERSISTENCE_API PvResult LoadFromString( const PvString &aString );
59
65 PV_PERSISTENCE_API uint32_t GetDeviceCount();
66
75 PV_PERSISTENCE_API PvResult GetDeviceName( uint32_t aIndex, PvString &aName );
76
85 PV_PERSISTENCE_API PvResult Restore( const PvString &aName, PvDevice *aDevice );
86
95 PV_PERSISTENCE_API PvResult Restore( uint32_t aIndex, PvDevice *aDevice );
96
102 PV_PERSISTENCE_API uint32_t GetStreamCount();
103
112 PV_PERSISTENCE_API PvResult GetStreamName( uint32_t aIndex, PvString &aName );
113
122 PV_PERSISTENCE_API PvResult Restore( const PvString &aName, PvStream *aStream );
123
132 PV_PERSISTENCE_API PvResult Restore( uint32_t aIndex, PvStream *Stream );
133
139 PV_PERSISTENCE_API uint32_t GetStringCount();
140
149 PV_PERSISTENCE_API PvResult GetStringName( uint32_t aIndex, PvString &aName );
150
159 PV_PERSISTENCE_API PvResult Restore( const PvString &aKey, PvString &aValue );
160
169 PV_PERSISTENCE_API PvResult Restore( uint32_t aIndex, PvString &aValue );
170
176 PV_PERSISTENCE_API uint32_t GetGenParameterArrayCount();
177
186 PV_PERSISTENCE_API PvResult GetGenParameterArrayName( uint32_t aIndex, PvString &aName );
187
196 PV_PERSISTENCE_API PvResult Restore( const PvString &aKey, PvGenParameterArray *aParameterArray );
197
206 PV_PERSISTENCE_API PvResult Restore( uint32_t aIndex, PvGenParameterArray *aParameterArray );
207
213 PV_PERSISTENCE_API uint32_t GetPropertyListCount();
214
223 PV_PERSISTENCE_API PvResult GetPropertyListName( uint32_t aIndex, PvString &aName );
224
233 PV_PERSISTENCE_API PvResult Restore( const PvString &aKey, PvPropertyList *aPropertyList );
234
243 PV_PERSISTENCE_API PvResult Restore( uint32_t aIndex, PvPropertyList *aPropertyList );
244
251 PV_PERSISTENCE_API void SetErrorList( PvStringList *aList, const PvString &aPrefix );
252
253private:
254
255 PvPersistenceLib::ConfigurationReader *mThis;
256
257 PvStringList *mErrorList;
258 PvString mErrorPrefix;
259
260 // Not implemented
262 const PvConfigurationReader &operator=( const PvConfigurationReader & );
263
264};
265
266#endif
Reads and restores configuration data from persistence files.
Definition PvConfigurationReader.h:29
uint32_t GetStreamCount()
Returns the number of streams stored in the configuration.
Definition PvConfigurationReader.cpp:265
uint32_t GetPropertyListCount()
Returns the number of property lists stored in the configuration.
Definition PvConfigurationReader.cpp:517
PvResult GetStreamName(uint32_t aIndex, PvString &aName)
Gets the name of a stream at the specified index.
Definition PvConfigurationReader.cpp:284
PvConfigurationReader()
Constructor.
Definition PvConfigurationReader.cpp:80
PvResult GetPropertyListName(uint32_t aIndex, PvString &aName)
Gets the name of a property list at the specified index.
Definition PvConfigurationReader.cpp:534
uint32_t GetGenParameterArrayCount()
Returns the number of GenICam parameter arrays stored in the configuration.
Definition PvConfigurationReader.cpp:431
PvResult GetDeviceName(uint32_t aIndex, PvString &aName)
Gets the name of a device at the specified index.
Definition PvConfigurationReader.cpp:184
void SetErrorList(PvStringList *aList, const PvString &aPrefix)
Sets the error list for collecting error messages during restore operations.
Definition PvConfigurationReader.cpp:626
PvResult GetStringName(uint32_t aIndex, PvString &aName)
Gets the name of a string entry at the specified index.
Definition PvConfigurationReader.cpp:365
uint32_t GetStringCount()
Returns the number of strings stored in the configuration.
Definition PvConfigurationReader.cpp:346
PvResult Load(const PvString &aFilename)
Loads configuration data from a file.
Definition PvConfigurationReader.cpp:114
~PvConfigurationReader()
Destructor.
Definition PvConfigurationReader.cpp:93
uint32_t GetDeviceCount()
Returns the number of devices stored in the configuration.
Definition PvConfigurationReader.cpp:159
PvResult GetGenParameterArrayName(uint32_t aIndex, PvString &aName)
Gets the name of a GenICam parameter array at the specified index.
Definition PvConfigurationReader.cpp:448
PvResult Restore(const PvString &aName, PvDevice *aDevice)
Restores configuration to a device by name.
Definition PvConfigurationReader.cpp:216
PvResult LoadFromString(const PvString &aString)
Loads configuration data from a string.
Definition PvConfigurationReader.cpp:139
Connect, configure and control a GigE Vision or USB3 Vision device.
Definition PvDevice.h:42
GenICam feature array.
Definition PvGenParameterArray.h:73
Class used to hold a group of PvProperty objects.
Definition PvPropertyList.h:21
Result information.
Definition PvResult.h:30
Receive data from a GigE Vision or USB3 Vision transmitter.
Definition PvStream.h:51
String class.
Definition PvString.h:26
Class used to hold a group of PvString objects.
Definition PvStringList.h:20

Copyright (c) 2002-2026 Pleora Technologies Inc.
www.pleora.com