1
0

StringField.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950
  1. /*
  2. ---------------------------------------------------------------------------
  3. Nullsoft Database Engine
  4. --------------------
  5. codename: Near Death Experience
  6. ---------------------------------------------------------------------------
  7. */
  8. /*
  9. ---------------------------------------------------------------------------
  10. StringField Class Prototypes
  11. ---------------------------------------------------------------------------
  12. */
  13. #ifndef __STRINGFIELD_H
  14. #define __STRINGFIELD_H
  15. #include "../NDEString.h"
  16. class StringField : public Field
  17. {
  18. public:
  19. StringField();
  20. ~StringField();
  21. StringField(const wchar_t *Str, int strkind=STRING_IS_WCHAR);
  22. wchar_t *GetStringW(void);
  23. void SetStringW(const wchar_t *Str);
  24. void SetNDEString(wchar_t *Str);
  25. protected:
  26. virtual void ReadTypedData(const uint8_t *, size_t len);
  27. virtual void WriteTypedData(uint8_t *, size_t len);
  28. virtual size_t GetDataSize(void);
  29. virtual int Compare(Field *Entry);
  30. virtual int Starts(Field *Entry);
  31. virtual int Contains(Field *Entry);
  32. virtual bool ApplyFilter(Field *Data, int op);
  33. virtual Field *Clone(Table *pTable);
  34. void InitField(void);
  35. wchar_t *StringW;
  36. const wchar_t *optimized_the;
  37. };
  38. #endif