|
| | DecklistCardNode (QString _name=QString(), int _number=1, InnerDecklistNode *_parent=nullptr, int position=-1, QString _cardSetShortName=QString(), QString _cardSetNumber=QString(), QString _cardProviderId=QString(), bool _formatLegality=true) |
| | Construct a new DecklistCardNode.
|
| | DecklistCardNode (DecklistCardNode *other, InnerDecklistNode *_parent) |
| | Copy constructor with new parent assignment.
|
| int | getNumber () const override |
| void | setNumber (int _number) override |
| QString | getName () const override |
| void | setName (const QString &_name) override |
| QString | getCardProviderId () const override |
| void | setCardProviderId (const QString &_providerId) override |
| QString | getCardSetShortName () const override |
| void | setCardSetShortName (const QString &_cardSetShortName) override |
| QString | getCardCollectorNumber () const override |
| void | setCardCollectorNumber (const QString &_cardSetNumber) override |
| bool | getFormatLegality () const override |
| void | setFormatLegality (const bool _formatLegal) override |
| bool | isDeckHeader () const override |
| CardRef | toCardRef () const |
| | Convert this node to a CardRef.
|
| | AbstractDecklistCardNode (InnerDecklistNode *_parent=nullptr, int position=-1) |
| | Construct a new AbstractDecklistCardNode.
|
| int | height () const override |
| | Get the height of this node in the tree.
|
| bool | compare (AbstractDecklistNode *other) const override |
| | Compare this card node against another for sorting.
|
| bool | compareNumber (AbstractDecklistNode *other) const |
| | Compare this card node to another by quantity.
|
| bool | compareName (AbstractDecklistNode *other) const |
| | Compare this card node to another by name.
|
| bool | readElement (QXmlStreamReader *xml) override |
| | Deserialize this node’s properties from XML.
|
| void | writeElement (QXmlStreamWriter *xml) override |
| | Serialize this node’s properties to XML.
|
| | AbstractDecklistNode (InnerDecklistNode *_parent=nullptr, int position=-1) |
| | Construct a new AbstractDecklistNode and insert it into its parent.
|
| virtual | ~AbstractDecklistNode ()=default |
| | Virtual destructor. Child classes must clean up their resources.
|
| virtual void | setSortMethod (DeckSortMethod method) |
| | Set the sort method for this node’s children.
|
| InnerDecklistNode * | getParent () const |
| int | depth () const |
| | Compute the depth of this node in the tree.
|
Concrete node type representing an actual card entry in the deck.
This class extends AbstractDecklistCardNode to hold all information needed to uniquely identify a card printing within the deck.
Role in the hierarchy:
- Child of an InnerDecklistNode (which groups cards by zone or criteria).
- Leaf node in the deck tree; it does not contain further children.
Data stored:
name: Card’s display name.
number: Quantity of this card in the deck.
cardSetShortName: Abbreviation of the set (e.g., "NEO" for Neon Dynasty).
cardSetNumber: Collector number within the set.
cardProviderId: External provider identifier (e.g., UUID or MTGJSON ID).
Usage:
- Constructed directly when building a deck list from user input or file.
- Used by DeckListModel to present cards in Qt views.
- Convertible to
CardRef for database lookups or cross-references.
Ownership:
- Owned by its parent InnerDecklistNode.
- Destroyed automatically when its parent is destroyed.