- /** Get a list of all extension items names.
- * @param list A deque of strings to receive the list
- * @return This function writes a list of all extension items stored in this object by name into the given deque and returns void.
- */
- void GetExtList(std::deque<std::string> &list);
-};
-
-/** BoolSet is a utility class designed to hold eight bools in a bitmask.
- * Use BoolSet::Set and BoolSet::Get to set and get bools in the bitmask,
- * and Unset and Invert for special operations upon them.
- */
-class CoreExport BoolSet : public classbase
-{
- /** Actual bit values */
- char bits;
-
- public:
-
- /** The default constructor initializes the BoolSet to all values unset.
- */
- BoolSet();
-
- /** This constructor copies the default bitmask from a char
- */
- BoolSet(char bitmask);
-
- /** The Set method sets one bool in the set.
- *
- * @param number The number of the item to set. This must be between 0 and 7.
- */
- void Set(int number);
-
- /** The Get method returns the value of one bool in the set
- *
- * @param number The number of the item to retrieve. This must be between 0 and 7.
- *
- * @return True if the item is set, false if it is unset.
- */
- bool Get(int number);
-
- /** The Unset method unsets one value in the set
- *
- * @param number The number of the item to set. This must be between 0 and 7.
- */
- void Unset(int number);
-
- /** The Unset method inverts (flips) one value in the set
- *
- * @param number The number of the item to invert. This must be between 0 and 7.
- */
- void Invert(int number);
-
- /** Compare two BoolSets
- */
- bool operator==(BoolSet other);
-
- /** OR two BoolSets together
- */
- BoolSet operator|(BoolSet other);
-
- /** AND two BoolSets together
- */
- BoolSet operator&(BoolSet other);
-
- /** Assign one BoolSet to another
- */
- bool operator=(BoolSet other);
+ inline operator bool() const { return (value != NULL); }
+ inline operator T*() const { return value; }
+ inline T* operator->() const { return value; }
+ inline T& operator*() const { return *value; }
+ inline bool operator<(const reference<T>& other) const { return value < other.value; }
+ inline bool operator>(const reference<T>& other) const { return value > other.value; }
+ static inline void* operator new(size_t, void* m) { return m; }
+ private:
+#ifndef _WIN32
+ static void* operator new(size_t);
+ static void operator delete(void*);
+#endif