summaryrefslogtreecommitdiffstats
path: root/src/templates/generated.mako.hpp
Commit message (Collapse)AuthorAgeFilesLines
* sdevent: Remove in favor of sdeventplusWilliam A. Kennington III2018-12-061-1/+0
| | | | | | | | This change removes the one off sd-event wrapper from the project and uses the openbmc wide sdeventplus library. Change-Id: I8e042f875d06082e15606c7191a8073974f93990 Signed-off-by: William A. Kennington III <wak@google.com>
* Modify parser and add mako scripts for watch on object pathMarri Devender Rao2018-06-051-0/+56
| | | | | | | | | | | | | | Added support for watch and callback on 'interface added' signal for the specified object paths. Added mako scripts for events to auto create callback and watch objects for the specified object path groups. Clients specify object paths to watch and callbacks to invoke in the config.yaml file Change-Id: I3fa2ea1520649120b927c0cb83a16e5cace2f24e Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
* Extend storage array to contain additional dataMatt Spinler2018-02-231-1/+1
| | | | | | | | | | | | | | | | | | | This array was originally just an array of objects of type 'any'. This commit changes it to be an array of tuples of type <any, any> to add an extra field for use by anything that needs it. For example, the storage is currently used to store property values, and a future change to the CountCondition class will now also store the result of the comparisons done between the property values and another value specified in the rule YAML. Then, a callback will be able to see the result of whether each property passed the check. Tested: Build and run unit tests Change-Id: I58f32c9f4068b15a02b1ff7f28871161cafebddb Signed-off-by: Matt Spinler <spinler@us.ibm.com>
* Initial support for event callbacksRatan Gupta2018-02-201-0/+1
| | | | | | | | | Add parser support for template rendering of events. Also defines the EventBase and Event classes. EventBase is parent of Event. Change-Id: I6b07b415acf510a8437529095bd489c0af73ddf5 Signed-off-by: Ratan Gupta <ratagupt@in.ibm.com>
* Add resolve callout rule support to YAML parserMatt Spinler2017-11-141-0/+1
| | | | | | | The callout to resolve is specified in the YAML. Change-Id: If613fae1959c6a54279b2a50c7d858f3e7d831b9 Signed-off-by: Matt Spinler <spinler@us.ibm.com>
* Add support for elog callbackGunnar Mills2017-08-211-0/+2
| | | | | | | | | | | Added support for "callback: elog" in PDM. templates/elog.mako.cpp is used to generate the Elog call. templates/errors.mako.hpp is used to generate the errors.hpp used by generated.hpp to include any error.hpp files like "xyz/openbmc_project/Common/error.hpp" Change-Id: Id0ae3aca4282095f58a8939b70e398bec706d7f5 Signed-off-by: Gunnar Mills <gmills@us.ibm.com>
* Remove use of std::crefBrad Bishop2017-06-191-6/+6
| | | | | | | Prefer implicit conversion for readability. Change-Id: I64d04b926edea0531a5414a416c04b36ae3d5e2a Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add deferrable callbacksBrad Bishop2017-06-191-0/+2
| | | | | | | | | | | Deferrable callbacks delay callback invocation until a pre configured length of time has elapsed. One example scenario where deferrable callbacks help is to avoid oscillation when testing a condition and making callbacks frequently. Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: I180c99b57ec1c9bde4da76d947a026f809341c8a
* Add SDEvent delegateBrad Bishop2017-06-191-0/+1
| | | | | | | | Add an sd-event interface abstraction to facilitate mocking and unit test. Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: I5880617565fc6eab54335adc30033d4b132568f8
* Method supportBrad Bishop2017-06-191-0/+1
| | | | | | | | | Add support for a method callback. The method callback enables arbitrary DBus method calls. A sample use case could be starting a systemd unit via the sytemd DBus API. Change-Id: If25131d11497c82f862ae1f47da066c5fd8b2e2e Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Link watches to callbacksBrad Bishop2017-06-191-0/+5
| | | | | | | | Callbacks must ultimately be triggered when a property is updated by a watch. Add that support. Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: I20130a11c19ddcf2c4ae45800f2068b31950bcd6
* Add conditional callbacksBrad Bishop2017-06-191-0/+17
| | | | | | | Enable conditional application of callbacks. Change-Id: I9d765e5f585aac40994b65da3b51ea891beae9bf Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add callback groupsBrad Bishop2017-06-191-0/+17
| | | | | | | | Allow named collections of callbacks to be defined and used anywhere callbacks are used. Change-Id: I3224aa06b2250e9a055bc70d20c186caecd033af Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add support for callbacksBrad Bishop2017-06-191-6/+23
| | | | | | | | | Callbacks are the response in the PDM 'trigger->response' model. Add general support for implementing callbacks and implement a log to systemd journal using that framework. Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com> Change-Id: I8bead5368ee5472a02b47e8bba9e9df3a1f346bc
* Add property watchesBrad Bishop2017-06-191-0/+66
| | | | | | | | | Property watches cache DBus property values given an externally supplied index of property names and paths, in an externally supplied storage location. Change-Id: I155081da88c3ab0e4f6a13b012fc9719203b1888 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add property and property group supportBrad Bishop2017-06-041-0/+32
| | | | | | | | | Add support for defining groups of DBus properties. Groups are a list of property/interface/metadata tuples. Metadata can be used to give a property context when required. Change-Id: I5fc27f4d815b53332a2ddea2d270fde8e355dcbc Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* Add path and path group supportBrad Bishop2017-06-041-0/+31
| | | | | | | | | Add support for defining groups of object paths. Groups are a list of path/metadata tuples. Metadata can be used to give a path context when required. Change-Id: I355ebf76b40f2ffc8d783e94e888b930cde8ee9c Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* pdmgen: Add core parsing logicBrad Bishop2017-06-041-0/+5
| | | | | | | | | | | | | Add logic to parse each yaml file in three stages. 1 - Invoke factory methods for config file directives, generating more factory methods. 2 - Invoke factory methods from 1 for the full set of renderable items. 3 - Run 'setup' on all renderable items to resolve item cross references. Change-Id: I428a9ae1c41cf65e1efc05f3ec7177375822d772 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
* build: General build refactoringBrad Bishop2017-05-231-0/+14
Add vars.mk for variable sharing across makefiles. Stub and rename example YAML file and template. Content to be re-introduced as support is added. Move generated C++ to a header file. Add input YAML path option to configure. Change-Id: Ia06e392e8b120b1e1d8614046064fa432a6f9e18 Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
OpenPOWER on IntegriCloud