Kea 2.7.5
|
Defines an interface for reading user data into a registry. More...
#include <user_data_source.h>
Public Member Functions | |
UserDataSource () | |
Constructor. | |
virtual | ~UserDataSource () |
Virtual Destructor. | |
virtual void | close ()=0 |
Closes that data source. | |
virtual bool | isOpen () const =0 |
Returns true if the data source is open. | |
virtual void | open ()=0 |
Opens the data source. | |
virtual UserPtr | readNextUser ()=0 |
Fetches the next user from the data source. | |
Defines an interface for reading user data into a registry.
This is an abstract class which defines the interface for reading Users from an IO source such as a file.
Definition at line 26 of file user_data_source.h.
|
inline |
Constructor.
Definition at line 29 of file user_data_source.h.
|
inlinevirtual |
Virtual Destructor.
Definition at line 32 of file user_data_source.h.
|
pure virtual |
Closes that data source.
Closes the data source.
This method must not throw exceptions.
Implemented in user_chk::UserFile.
|
pure virtual |
Returns true if the data source is open.
This method should return true once the data source has been successfully opened and until it has been closed.
It is assumed to be exception safe.
Implemented in user_chk::UserFile.
|
pure virtual |
Opens the data source.
Prepares the data source for reading. Upon successful completion the data source is ready to read from the beginning of its content.
UserDataSourceError | if the source fails to open. |
Implemented in user_chk::UserFile.
|
pure virtual |
Fetches the next user from the data source.
Reads the next User from the data source and returns it. If no more data is available it should return an empty (null) user.
UserDataSourceError | if an error occurs. |
Implemented in user_chk::UserFile.