Service¶
-
class
Cauldron.DFW.Service.Service¶ Bases:
Cauldron.local.dispatcher.ServiceA dispatcher is a KTL service server-side.
A class encapsulating a basic representation of a complete KTL service. The
nameargument is case sensitive, and will be used to locate (and load) the service’s KTLXML representation. Theconfigargument specifies the stdiosvc configuration file that will be used when loading the stdiosvc front-end. Thesetupfunction will be called to properly instantiate all keywords associated with thisServiceinstance; it accepts aServiceinstance as its sole argument, and should instantiateKeyword.Basicobjects directly. If any keywords are not instantiated, they will be given placeholder “cacheing”Keyword.Basicinstances of the appropriate type (string, integer, etc.). SeesetupOrphans()for an example. Ifdispatcheris specified, only keywords corresponding to that dispatcher number will be instantiated.Parameters: name : str
the Service name.
config : str
the stdiosvc configuration filename, or the Cauldron configuration filename.
setup : callable
a function which will be called to set up the keywords for this service.
dispatcher : str, optional
The name of the dispatcher to use for this service. If not provided, all keywords will be used.