EPICS Base  7.0.5.1
Typedefs | Functions
dbState.h File Reference

Generic IOC state facility. More...

#include "shareLib.h"
Include dependency graph for dbState.h:

Go to the source code of this file.

Typedefs

typedef struct dbState * dbStateId
 

Functions

epicsShareFunc dbStateId dbStateCreate (const char *name)
 Create db state. More...
 
epicsShareFunc dbStateId dbStateFind (const char *name)
 Find db state. More...
 
epicsShareFunc void dbStateSet (dbStateId id)
 Set db state to TRUE. More...
 
epicsShareFunc void dbStateClear (dbStateId id)
 Set db state to FALSE. More...
 
epicsShareFunc int dbStateGet (dbStateId id)
 Get db state. More...
 
epicsShareFunc void dbStateShow (dbStateId id, unsigned int level)
 Print info about db state. More...
 
epicsShareFunc void dbStateShowAll (unsigned int level)
 Print info about all db states. More...
 

Detailed Description

This library provides a simple global flag facility that can be used to synchronize e.g. plugins with IOC-wide states, that may be derived from events (either soft events or hard events coming from specialized timing and event hardware).

A subset of this API is provided as IOC Shell commands to allow command line debugging.

Definition in file dbState.h.

Function Documentation

◆ dbStateCreate()

epicsShareFunc dbStateId dbStateCreate ( const char *  name)

Creates a new db state with the specified 'name', returning the new id. If state with that name already exists, the existing state's id is returned.

Also provided as an IOC Shell command.

Parameters
nameDb state name.
Returns
Id of db state, NULL for failure.

◆ dbStateFind()

epicsShareFunc dbStateId dbStateFind ( const char *  name)
Parameters
nameDb state name.
Returns
Id of db state, NULL if not found.

◆ dbStateSet()

epicsShareFunc void dbStateSet ( dbStateId  id)

Also provided as an IOC Shell command.

Parameters
idDb state id.

◆ dbStateClear()

epicsShareFunc void dbStateClear ( dbStateId  id)

Also provided as an IOC Shell command.

Parameters
idDb state id.

◆ dbStateGet()

epicsShareFunc int dbStateGet ( dbStateId  id)
Parameters
idDb state id.
Returns
Current db state (0|1).

◆ dbStateShow()

epicsShareFunc void dbStateShow ( dbStateId  id,
unsigned int  level 
)

Also provided as an IOC Shell command.

Parameters
idDb state id.
levelInterest level.

◆ dbStateShowAll()

epicsShareFunc void dbStateShowAll ( unsigned int  level)

Also provided as an IOC Shell command.

Parameters
levelInterest level.