@@ -179,6 +179,11 @@ String URL::toString (const bool includeGetParameters) const | |||||
return url; | return url; | ||||
} | } | ||||
bool URL::isEmpty() const noexcept | |||||
{ | |||||
return url.isEmpty(); | |||||
} | |||||
bool URL::isWellFormed() const | bool URL::isWellFormed() const | ||||
{ | { | ||||
//xxx TODO | //xxx TODO | ||||
@@ -76,6 +76,9 @@ public: | |||||
*/ | */ | ||||
String toString (bool includeGetParameters) const; | String toString (bool includeGetParameters) const; | ||||
/** Returns true if the URL is an empty string. */ | |||||
bool isEmpty() const noexcept; | |||||
/** True if it seems to be valid. */ | /** True if it seems to be valid. */ | ||||
bool isWellFormed() const; | bool isWellFormed() const; | ||||
@@ -54,6 +54,11 @@ bool RSAKey::operator!= (const RSAKey& other) const noexcept | |||||
return ! operator== (other); | return ! operator== (other); | ||||
} | } | ||||
bool RSAKey::isValid() const noexcept | |||||
{ | |||||
return operator!= (RSAKey()); | |||||
} | |||||
String RSAKey::toString() const | String RSAKey::toString() const | ||||
{ | { | ||||
return part1.toString (16) + "," + part2.toString (16); | return part1.toString (16) + "," + part2.toString (16); | ||||
@@ -113,11 +113,15 @@ public: | |||||
//============================================================================== | //============================================================================== | ||||
/** Turns the key into a string representation. | /** Turns the key into a string representation. | ||||
This can be reloaded using the constructor that takes a string. | This can be reloaded using the constructor that takes a string. | ||||
*/ | */ | ||||
String toString() const; | String toString() const; | ||||
/** Returns true if the object is a valid key, or false if it was created by | |||||
the default constructor. | |||||
*/ | |||||
bool isValid() const noexcept; | |||||
//============================================================================== | //============================================================================== | ||||
/** Encodes or decodes a value. | /** Encodes or decodes a value. | ||||