*/
wxVariant(double value, const wxString& name = wxEmptyString);
+ /**
+ Constructs a variant from a wxLongLong.
+ */
+ wxVariant(wxLongLong value, const wxString& name = wxEmptyString);
+
+ /**
+ Constructs a variant from a wxULongLong.
+ */
+ wxVariant(wxULongLong value, const wxString& name = wxEmptyString);
+
/**
Constructs a variant from a list of variants
*/
/**
Constructs a variant from a wxDateTime.
*/
- wxVariant(wxDateTime& val, const wxString& name = wxEmptyString);
+ wxVariant(const wxDateTime& val, const wxString& name = wxEmptyString);
/**
Constructs a variant from a wxArrayString.
*/
- wxVariant(wxArrayString& val, const wxString& name = wxEmptyString);
+ wxVariant(const wxArrayString& val, const wxString& name = wxEmptyString);
/**
Destructor.
bool Convert(double* value) const;
bool Convert(wxString* value) const;
bool Convert(wxChar* value) const;
+ bool Convert(wxLongLong* value) const;
+ bool Convert(wxULongLong* value) const;
bool Convert(wxDateTime* value) const;
//@}
/**
Returns the character value.
*/
- wxChar GetChar() const;
+ wxUniChar GetChar() const;
/**
Returns a pointer to the internal variant data. To take ownership of
*/
long GetLong() const;
+ /**
+ Returns the signed 64-bit integer value.
+ */
+ wxLongLong GetLongLong() const;
+
/**
Returns a constant reference to the variant name.
*/
- const wxString GetName() const;
+ const wxString& GetName() const;
/**
Gets the string value.
- "double"
- "list"
- "long"
+ - "longlong"
- "string"
+ - "ulonglong"
- "arrstring"
- "void*"
*/
wxString GetType() const;
+ /**
+ Returns the unsigned 64-bit integer value.
+ */
+ wxULongLong GetULongLong() const;
+
/**
Gets the void pointer value.
+
+ Notice that this method can be used for null objects (i.e. those for
+ which IsNull() returns @true) and will return @NULL for them.
*/
void* GetVoidPtr() const;
bool operator !=(const wxString& value) const;
bool operator !=(const wxChar* value) const;
bool operator !=(wxChar value) const;
- bool operator !=(const long value) const;
- bool operator !=(const bool value) const;
- bool operator !=(const double value) const;
+ bool operator !=(long value) const;
+ bool operator !=(bool value) const;
+ bool operator !=(double value) const;
+ bool operator !=(wxLongLong value) const;
+ bool operator !=(wxULongLong value) const;
bool operator !=(void* value) const;
bool operator !=(wxObject* value) const;
bool operator !=(const wxVariantList& value) const;
void operator =(const wxString& value);
void operator =(const wxChar* value);
void operator =(wxChar value);
- void operator =(const long value);
- void operator =(const bool value);
- void operator =(const double value);
+ void operator =(long value);
+ void operator =(bool value);
+ void operator =(double value);
+ bool operator =(wxLongLong value) const;
+ bool operator =(wxULongLong value) const;
void operator =(void* value);
void operator =(wxObject* value);
void operator =(const wxVariantList& value);
bool operator ==(const wxString& value) const;
bool operator ==(const wxChar* value) const;
bool operator ==(wxChar value) const;
- bool operator ==(const long value) const;
- bool operator ==(const bool value) const;
- bool operator ==(const double value) const;
+ bool operator ==(long value) const;
+ bool operator ==(bool value) const;
+ bool operator ==(double value) const;
+ bool operator ==(wxLongLong value) const;
+ bool operator ==(wxULongLong value) const;
bool operator ==(void* value) const;
bool operator ==(wxObject* value) const;
bool operator ==(const wxVariantList& value) const;
//@{
/**
- Operator for implicit conversion to a long, using GetLong().
+ Operators for implicit conversion, using appropriate getter member
+ function.
*/
double operator double() const;
long operator long() const;
+ wxLongLong operator wxLongLong() const;
+ wxULongLong operator wxULongLong() const;
//@}
/**
@see wxVariant, wxGetVariantCast()
*/
-class wxVariantData
+class wxVariantData : public wxObjectRefData
{
public:
/**
/**
Reads the data from @a stream.
*/
- bool Read(ostream& stream);
+ virtual bool Read(istream& stream);
+
/**
Reads the data from @a string.
*/
// Global functions/macros
// ============================================================================
-/** @ingroup group_funcmacro_rtti */
+/** @addtogroup group_funcmacro_rtti */
//@{
/**