Smithy Qt 0.1.0-pre
Internal development documentation
|
The Shape class provides a Qt representation of a Smithy semantic shape. More...
Classes | |
struct | Member |
struct | ShapeReference |
Public Types | |
enum class | Error { NoError = 0 , UndefinedShapeType = 1 , MissingRequiredProperty = 2 , InvalidPropertyValue = 3 } |
enum class | Type { Undefined = 0x000 , Blob = 0x101 , Boolean = 0x102 , String = 0x103 , Enum = 0x104 , Byte = 0x105 , Short = 0x106 , Integer = 0x107 , IntEnum = 0x108 , Long = 0x109 , Float = 0x10A , Double = 0x10B , BigInteger = 0x10C , BigDecimal = 0x10D , Timestamp = 0x10E , Document = 0x10F , List = 0x201 , Set = 0x201 , Map = 0x202 , Structure = 0x203 , Union = 0x204 , Service = 0x301 , Operation = 0x302 , Resource = 0x303 , Apply = 0x401 } |
typedef QHash< ShapeId, QJsonValue > | TraitsMap |
typedef QHash< QString, ShapeReference > | StringShapeRefMap |
typedef QSet< ShapeReference > | ShapeReferences |
typedef QHash< QString, Member > | StringMemberMap |
Public Member Functions | |
Shape () | |
Constructs a new, empty Smithy shape. | |
Shape (const QJsonObject &ast, const ShapeId &id=ShapeId{}) | |
Shape (Shape &&other) | |
Shape (const Shape &other) | |
Shape & | operator= (const Shape &shape) |
Shape & | operator= (const Shape &&shape) |
~Shape () | |
Destroys this Shape object. | |
Error | error () const |
bool | isValid () const |
ShapeId | id () const |
Type | type () const |
TraitsMap | traits () const |
Member | member () const |
Member | key () const |
Member | value () const |
StringMemberMap | members () const |
QString | version () const |
ShapeReferences | operations () const |
ShapeReferences | resources () const |
ShapeReferences | errors () const |
ShapeIdStringMap | rename () const |
StringShapeRefMap | identifiers () const |
StringShapeRefMap | properties () const |
ShapeReference | create () const |
ShapeReference | put () const |
ShapeReference | read () const |
ShapeReference | update () const |
ShapeReference | Delete () const |
ShapeReference | list () const |
ShapeReferences | collectionOperations () const |
ShapeReference | input () const |
ShapeReference | output () const |
ShapeReferences | mixins () const |
QJsonObject | rawAst () const |
Protected Attributes | |
ShapePrivate * | d_ptr |
Private Member Functions | |
Q_DECLARE_TR_FUNCTIONS (Shape) | |
The Shape class provides a Qt representation of a Smithy semantic shape.
That is, essentially a tagged union or variant class, with some specialised conversions for native Qt types.
typedef QSet<ShapeReference> Shape::ShapeReferences |
typedef QHash<QString, ShapeReference> Shape::StringShapeRefMap |
|
strong |
|
strong |
Definition at line 37 of file shape.h.
Shape::Shape | ( | ) |
Constructs a new, empty Smithy shape.
Definition at line 28 of file shape.cpp.
References d_ptr, Shape(), and Undefined.
Referenced by Shape().
Definition at line 35 of file shape.cpp.
Shape::Shape | ( | Shape && | other | ) |
Shape::Shape | ( | const Shape & | other | ) |
Shape::~Shape | ( | ) |
Shape::ShapeReferences Shape::collectionOperations | ( | ) | const |
Shape::ShapeReference Shape::create | ( | ) | const |
Shape::ShapeReference Shape::Delete | ( | ) | const |
Shape::Error Shape::error | ( | ) | const |
Shape::ShapeReferences Shape::errors | ( | ) | const |
ShapeId Shape::id | ( | ) | const |
Shape::StringShapeRefMap Shape::identifiers | ( | ) | const |
Shape::ShapeReference Shape::input | ( | ) | const |
Shape::Member Shape::key | ( | ) | const |
Shape::ShapeReference Shape::list | ( | ) | const |
Shape::Member Shape::member | ( | ) | const |
Shape::StringMemberMap Shape::members | ( | ) | const |
Shape::ShapeReferences Shape::mixins | ( | ) | const |
Shape::ShapeReferences Shape::operations | ( | ) | const |
Shape::ShapeReference Shape::output | ( | ) | const |
Shape::StringShapeRefMap Shape::properties | ( | ) | const |
Shape::ShapeReference Shape::put | ( | ) | const |
QJsonObject Shape::rawAst | ( | ) | const |
Shape::ShapeReference Shape::read | ( | ) | const |
ShapeIdStringMap Shape::rename | ( | ) | const |
Shape::ShapeReferences Shape::resources | ( | ) | const |
Shape::TraitsMap Shape::traits | ( | ) | const |
Shape::Type Shape::type | ( | ) | const |
Shape::ShapeReference Shape::update | ( | ) | const |
Shape::Member Shape::value | ( | ) | const |
QString Shape::version | ( | ) | const |
|
protected |