Own fork of MbedSmartRest
Dependents: MbedSmartRestMain MbedSmartRestMain
Fork of MbedSmartRest by
Diff: Value.h
- Revision:
- 11:e1bee9a77652
- Parent:
- 0:099f76422485
--- a/Value.h Thu Oct 23 14:41:58 2014 +0200 +++ b/Value.h Sat Nov 15 11:21:01 2014 +0100 @@ -54,54 +54,54 @@ */ class Value { -public: - virtual ~Value() { }; + public: + virtual ~Value() { }; - /** - * Returns the value type which can be VALUE_NULL, VALUE_INTEGER, - * VALUE_FLOAT or VALUE_CHARACTER. - * @return the value type - */ - virtual uint8_t valueType() const = 0; + /** + * Returns the value type which can be VALUE_NULL, VALUE_INTEGER, + * VALUE_FLOAT or VALUE_CHARACTER. + * @return the value type + */ + virtual uint8_t valueType() const = 0; - /** - * Returns the integer value if an integer type, otherwise zero. - * @return integer value - */ - virtual long integerValue() const = 0; + /** + * Returns the integer value if an integer type, otherwise zero. + * @return integer value + */ + virtual long integerValue() const = 0; - /** - * Returns the float value if a float type, otherwise zero. - * @return float value - */ - virtual double floatValue() const = 0; + /** + * Returns the float value if a float type, otherwise zero. + * @return float value + */ + virtual double floatValue() const = 0; - /** - * Returns the character value if a character type, otherwise zero. - * @return character value - */ - virtual const char * characterValue() const = 0; + /** + * Returns the character value if a character type, otherwise zero. + * @return character value + */ + virtual const char * characterValue() const = 0; - /** - * Writes the value to a sink. - * If necessary, quotes and escape characters may be added. - * @param sink the sink to write the value to - * @return the number of bytes written - */ - virtual size_t write(AbstractDataSink&) const = 0; + /** + * Writes the value to a sink. + * If necessary, quotes and escape characters may be added. + * @param sink the sink to write the value to + * @return the number of bytes written + */ + virtual size_t write(AbstractDataSink&) const = 0; - /** - * Returns the number of bytes required to write this value to a sink. - * @return number of bytes required to write this value - */ - virtual size_t length() const = 0; + /** + * Returns the number of bytes required to write this value to a sink. + * @return number of bytes required to write this value + */ + virtual size_t length() const = 0; - /** - * Copies this value to the heap. Referenced contents must also be - * copied. - * @return a new value instance allocated on the heap - */ - virtual Value* copy() const = 0; + /** + * Copies this value to the heap. Referenced contents must also be + * copied. + * @return a new value instance allocated on the heap + */ + virtual Value* copy() const = 0; }; #endif