vfs: check userland buffers before reading them.
[haiku.git] / headers / private / debugger / value / value_formatters / FloatValueFormatter.h
blob2e2612616731d03842ba72d0dcad2501f3805a69
1 /*
2 * Copyright 2015, Rene Gollent, rene@gollent.com.
3 * Distributed under the terms of the MIT License.
4 */
5 #ifndef FLOAT_VALUE_FORMATTER_H
6 #define FLOAT_VALUE_FORMATTER_H
9 #include "ValueFormatter.h"
12 class Settings;
13 class Value;
16 class FloatValueFormatter : public ValueFormatter {
17 public:
18 FloatValueFormatter();
19 virtual ~FloatValueFormatter();
21 virtual Settings* GetSettings() const
22 { return NULL; }
24 virtual status_t FormatValue(Value* value, BString& _output);
26 virtual bool SupportsValidation() const;
28 virtual bool ValidateFormattedValue(
29 const BString& input,
30 type_code type) const;
32 virtual status_t GetValueFromFormattedInput(
33 const BString& input, type_code type,
34 Value*& _output) const;
35 private:
37 status_t _PerformValidation(const BString& input,
38 type_code type,
39 ::Value*& _output,
40 bool wantsValue) const;
44 #endif // FLOAT_VALUE_FORMATTER_H