2.2.3. Derivation.h Class Derivation

class Derivation

This class represents a derivation \(G\Rightarrow^p H\), with \(G\) and \(H\) being multisets of graphs. Synopsis

struct Derivation {
    using GraphList = std::vector<std::shared_ptr<Graph> >;
    friend std::ostream &operator<<(std::ostream &s, const Derivation &d);
    GraphList left;
    std::shared_ptr<Rule> rule;
    GraphList right;
}; Details

typedef std::vector<std::shared_ptr<Graph>> GraphList

Representation of a multiset of graphs.

GraphList left

Represents the multi-set of left graphs \(G\) in a derivation \(G\Rightarrow^p H\).

std::shared_ptr<Rule> rule

Represents the transformation rule \(p\) in a derivation \(G\Rightarrow^p H\).

GraphList right

Represents the multi-set of right graphs \(H\) in a derivation \(G\Rightarrow^p H\).