Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

69 lines
1.5 KiB

  1. /*
  2. *
  3. * NOTES:
  4. *
  5. * REVISIONS:
  6. * ker04DEC92 Initial OS/2 Revision
  7. * pcy14Dec92: Changed READ_ONLY to AREAD_ONLY
  8. * pcy26Jan93: Superclass EepromChoice w/ EepromSensor
  9. * rct15Jun93: Added error code for getAllowedValues()
  10. * ajr29Nov93: Removed methods from class def and resolved some undefined
  11. * functions in header
  12. * cgm12Apr96: Add destructor with unregister
  13. *
  14. */
  15. #ifndef __EEPROM_H
  16. #define __EEPROM_H
  17. #include "sensor.h"
  18. #include "errlogr.h"
  19. _CLASSDEF(EepromSensor)
  20. _CLASSDEF(EepromChoiceSensor)
  21. class EepromSensor : public Sensor {
  22. protected:
  23. INT setInitialValue();
  24. public:
  25. EepromSensor(PDevice aParent, PCommController aCommController,
  26. INT aSensorCode = NO_SENSOR_CODE, ACCESSTYPE anACCESSTYPE = AREAD_ONLY);
  27. // overidden interfaces;
  28. virtual ~EepromSensor();
  29. virtual INT Set(const PCHAR);
  30. virtual INT Update(PEvent anEvent);
  31. VOID SetEepromAccess(INT anAccessCode);
  32. };
  33. class EepromChoiceSensor : public EepromSensor {
  34. protected:
  35. PCHAR theAllowedValues;
  36. virtual VOID getCurrentAllowedValues(PCHAR aValue);
  37. virtual INT getAllowedValues();
  38. public:
  39. EepromChoiceSensor(PDevice aParent, PCommController aCommController,
  40. INT aSensorCode = NO_SENSOR_CODE, ACCESSTYPE anACCESSTYPE = AREAD_ONLY);
  41. virtual ~EepromChoiceSensor() ;
  42. // overidden interfaces;
  43. virtual INT Get(INT aCode, PCHAR aValue);
  44. virtual INT Validate(INT, const PCHAR);
  45. };
  46. #endif