EPICS Base  7.0.5.1
Classes | Functions
dbServer.h File Reference

The IOC's interface to the server layers that publish its PVs. More...

#include <stddef.h>
#include "ellLib.h"
#include "shareLib.h"
Include dependency graph for dbServer.h:

Go to the source code of this file.

Classes

struct  dbServer
 Server information structure. More...
 

Functions

epicsShareFunc int dbRegisterServer (dbServer *psrv)
 Register a server layer with the IOC. More...
 
epicsShareFunc int dbUnregisterServer (dbServer *psrv)
 Unregister a server layer. More...
 
epicsShareFunc void dbsr (unsigned level)
 Print dbServer Reports. More...
 
epicsShareFunc int dbServerClient (char *pBuf, size_t bufSize)
 Query servers for client's identity. More...
 
epicsShareFunc void dbInitServers (void)
 Initialize all registered servers. More...
 
epicsShareFunc void dbRunServers (void)
 Run all registered servers. More...
 
epicsShareFunc void dbPauseServers (void)
 Pause all registered servers. More...
 
epicsShareFunc void dbStopServers (void)
 Stop all registered servers. More...
 

Detailed Description

Author
Andrew Johnson anj@a.nosp@m.ps.a.nosp@m.nl.go.nosp@m.v

All server layers which publish IOC record data should initialize a dbServer structure and register it with the IOC. The methods that the dbServer interface provides allow the IOC to start, pause and stop the servers together, and to provide status and debugging information to the IOC user/developer through a common set of commands.

Todo:
No API is provided yet for calling stats() methods. Nothing in the IOC calls dbStopServers(), not sure where it should go.

Definition in file dbServer.h.

Function Documentation

◆ dbRegisterServer()

epicsShareFunc int dbRegisterServer ( dbServer psrv)

This should only be called once for each server layer.

Parameters
psrvServer information structure for the server

◆ dbUnregisterServer()

epicsShareFunc int dbUnregisterServer ( dbServer psrv)

This should only be called when the servers are inactive.

Parameters
psrvServer information structure for the server

◆ dbsr()

epicsShareFunc void dbsr ( unsigned  level)

Calls the report methods of all registered servers. This routine is provided as an IOC Shell command.

Parameters
levelInterest level, specifies how much detail to print.

◆ dbServerClient()

epicsShareFunc int dbServerClient ( char *  pBuf,
size_t  bufSize 
)

This routine is called by code that wants to identify who (or what) is responsible for the thread which is currently running. Setting the TPRO field of a record is one way to trigger this; the identity of the calling thread is printed along with the record name whenever the record is subsequently processed.

◆ dbInitServers()

epicsShareFunc void dbInitServers ( void  )

Calls all dbServer::init() methods.

◆ dbRunServers()

epicsShareFunc void dbRunServers ( void  )

Calls all dbServer::run() methods.

◆ dbPauseServers()

epicsShareFunc void dbPauseServers ( void  )

Calls all dbServer::pause() methods.

◆ dbStopServers()

epicsShareFunc void dbStopServers ( void  )

Calls all dbServer::stop() methods.