2009-05-01 23:23:59 +04:00
|
|
|
#ifndef _B_FLOAT_FORMAT_IMPL_H_
|
|
|
|
#define _B_FLOAT_FORMAT_IMPL_H_
|
|
|
|
|
|
|
|
#include <NumberFormatImpl.h>
|
|
|
|
|
|
|
|
struct format_field_position;
|
|
|
|
class BFloatFormatParameters;
|
|
|
|
class BString;
|
|
|
|
|
2009-05-02 01:56:16 +04:00
|
|
|
class BFloatFormatImpl : public BNumberFormatImpl {
|
2009-05-01 23:23:59 +04:00
|
|
|
public:
|
|
|
|
BFloatFormatImpl();
|
|
|
|
virtual ~BFloatFormatImpl();
|
|
|
|
|
|
|
|
// formatting
|
|
|
|
|
|
|
|
virtual status_t Format(const BFloatFormatParameters *parameters,
|
|
|
|
double number, BString *buffer) const = 0;
|
|
|
|
virtual status_t Format(const BFloatFormatParameters *parameters,
|
|
|
|
double number, BString *buffer,
|
|
|
|
format_field_position *positions,
|
|
|
|
int32 positionCount = 1,
|
|
|
|
int32 *fieldCount = NULL,
|
|
|
|
bool allFieldPositions = false) const = 0;
|
|
|
|
|
|
|
|
// TODO: ...
|
|
|
|
|
|
|
|
|
|
|
|
virtual BNumberFormatParameters *DefaultNumberFormatParameters();
|
|
|
|
virtual const BNumberFormatParameters *DefaultNumberFormatParameters()
|
|
|
|
const;
|
|
|
|
|
|
|
|
virtual BFloatFormatParameters *DefaultFloatFormatParameters() = 0;
|
|
|
|
virtual const BFloatFormatParameters *DefaultFloatFormatParameters()
|
|
|
|
const = 0;
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
#endif // _B_FLOAT_FORMAT_IMPL_H_
|