Refactor set sensor handling code

A summary of the changes:

- Do not generate per sensor type code to update d-bus objects
  corresponding to sensors. Function to update d-bus objects based on
  standard sensor event types, such as assertion, event data, are now
  generic functions - the need not be generated per sensor or per sensor
  type.
- There's a special case where the assertion is treated as a reading
  (i.e read the entire assertion field as-is). In this case, code needs
  to be generated per sensor because the type of the  mapped d-bus
  property can vary. In this case have a generic template function, and
  generate minimal code like so:
  inline ipmi_ret_t readingAssertion(const SetSensorReadingReq& cmdData,
                                     const Info& sensorInfo)
  {
      // Corresponding d-bus property is uint32_t
      return set::readingAssertion<uint32_t>(cmdData, sensorInfo);
  }
- Make sensor-example.yaml succinct.
- Make the code in writesensor.mako.cpp more pythonic.

Change-Id: I84415ca6e3f756bbb51a90e290539eb086a7f78b
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
6 files changed