Smithy Qt 0.1.0-pre
Smithy code generator for Qt
|
The ShapeId class provides a Qt representation of a Smithy Shape ID. More...
Public Member Functions | |
ShapeId () | |
Constructs an empty ShapeId object. | |
ShapeId (ShapeId &&other) | |
Constructs a ShapeId object by moving resources from other. | |
ShapeId (const ShapeId &other) | |
Constructs a ShapeId object by copying other. | |
ShapeId (const QString &shapeId) | |
Constructs a ShapeId object by parsing the Smithy Shape ID given by shapeId. | |
ShapeId & | operator= (const ShapeId &shapeId) |
Assigns the specified shapeId to this object. | |
ShapeId & | operator= (const ShapeId &&shapeId) |
Moves the specified shapeId to this object. | |
ShapeId & | operator= (const QString &shapeId) |
Assigns the specified shapeId to this object. | |
~ShapeId () | |
Destroys this ShapeId object. | |
QString | memberName () const |
Returns the Shape ID's member name, if it has one, otherwise a null string. | |
QString | nameSpace () const |
Returns the Shape ID's namespace, if it has one, otherwise a null string. | |
QString | shapeName () const |
Returns the Shape ID's shape name, if it has one, otherwise a null string. | |
void | setMemberName (const QString &name) |
Set the Shape ID's member name to name, which may be an empty or null string. | |
void | setNameSpace (const QString &name) |
Set the Shape ID's namespace to name, which may be an empty or null string. | |
void | setShapeName (const QString &name) |
Set the Shape ID's shape name to name. | |
QString | absoluteShapeId () const |
Returns this object as an absolute Smithy Shape ID if this object has a namespace, otherwise a null string. | |
QString | relativeShapeId () const |
Returns this object as a relative Smithy Shape ID, that one without a leading namespace. | |
QString | toString () const |
Returns this object as an absolute Smithy Shape ID if this object has a namespace, otherwise a relative Smithy Shape ID. | |
bool | hasNameSpace () const |
Returns true if this Shape ID has a non-empty namespace, otherwise false otherwise. | |
bool | hasMemberName () const |
Returns true if this Shape ID has a non-empty member name, otherwise false otherwise. | |
bool | isAbsoluteRootShapeId () const |
Returns true if this Shape ID is a root Shape ID, and has a namespace, false otherwise. | |
bool | isRootShapeId () const |
Returns true if this Shape ID is a root Shape ID, false otherwise. | |
bool | isRelativeShapeId () const |
Returns true if this Shape ID is a relative Shape ID, false otherwise. | |
bool | isValid () const |
Returns true if this object represents a valid, non-empty Smithy Shape ID. | |
bool | operator== (const ShapeId &other) const |
ShapeId::ShapeId | ( | const QString & | shapeId | ) |
Constructs a ShapeId object by parsing the Smithy Shape ID given by shapeId.
To be considered valid, shapeId must contain at least a valid shape name, but may also contain optional namespace and member name components. Use isValid() to verify shapeId's validity.
QString ShapeId::absoluteShapeId | ( | ) | const |
Returns this object as an absolute Smithy Shape ID if this object has a namespace, otherwise a null string.
false
) it still safe to invoke this method, but the result is undefined.bool ShapeId::hasMemberName | ( | ) | const |
Returns true
if this Shape ID has a non-empty member name, otherwise false
otherwise.
bool ShapeId::hasNameSpace | ( | ) | const |
Returns true
if this Shape ID has a non-empty namespace, otherwise false
otherwise.
bool ShapeId::isAbsoluteRootShapeId | ( | ) | const |
Returns true
if this Shape ID is a root Shape ID, and has a namespace, false
otherwise.
bool ShapeId::isRelativeShapeId | ( | ) | const |
Returns true
if this Shape ID is a relative Shape ID, false
otherwise.
bool ShapeId::isRootShapeId | ( | ) | const |
Returns true
if this Shape ID is a root Shape ID, false
otherwise.
bool ShapeId::isValid | ( | ) | const |
Returns true if this object represents a valid, non-empty Smithy Shape ID.
QString ShapeId::relativeShapeId | ( | ) | const |
Returns this object as a relative Smithy Shape ID, that one without a leading namespace.
false
) it still safe to invoke this method, but the result is undefined.void ShapeId::setShapeName | ( | const QString & | name | ) |
QString ShapeId::shapeName | ( | ) | const |
QString ShapeId::toString | ( | ) | const |
Returns this object as an absolute Smithy Shape ID if this object has a namespace, otherwise a relative Smithy Shape ID.
false
) it still safe to invoke this method, but the result is undefined.