initial commit
This commit is contained in:
commit
4b60ece582
327 changed files with 28286 additions and 0 deletions
49
lib/wType/boolean.h
Normal file
49
lib/wType/boolean.h
Normal file
|
@ -0,0 +1,49 @@
|
|||
#ifndef BOOLEAN_H
|
||||
#define BOOLEAN_H
|
||||
|
||||
#include "object.h"
|
||||
|
||||
namespace W
|
||||
{
|
||||
class Boolean:
|
||||
public Object
|
||||
{
|
||||
public:
|
||||
Boolean();
|
||||
explicit Boolean(bool value);
|
||||
Boolean(const Boolean& original);
|
||||
|
||||
~Boolean();
|
||||
|
||||
Boolean& operator=(const Boolean& original);
|
||||
Boolean& operator=(bool original);
|
||||
|
||||
StdStr toString() const override;
|
||||
Object* copy() const override;
|
||||
size_type length() const override;
|
||||
size_type size() const override;
|
||||
|
||||
objectType getType() const override;
|
||||
bool operator==(const W::Object & other) const override;
|
||||
|
||||
bool operator<(const Boolean& other) const;
|
||||
bool operator>(const Boolean& other) const;
|
||||
bool operator<=(const Boolean& other) const;
|
||||
bool operator>=(const Boolean& other) const;
|
||||
bool operator==(const Boolean& other) const;
|
||||
bool operator!=(const Boolean& other) const;
|
||||
|
||||
static const objectType type = boolean;
|
||||
|
||||
void serialize(ByteArray& out) const override;
|
||||
void deserialize(ByteArray& in) override;
|
||||
|
||||
operator bool() const;
|
||||
|
||||
private:
|
||||
bool data;
|
||||
|
||||
};
|
||||
}
|
||||
|
||||
#endif // BOOLEAN_H
|
Loading…
Add table
Add a link
Reference in a new issue