verigraph-1.1.1: Software specification and verification tool based on graph rewriting.

Safe HaskellSafe
LanguageHaskell2010

TypedGraph.DPO.GraphRule

Contents

Synopsis

Types

getLHS :: Production m -> m Source #

Returns the morphism K -> L of the given production

getRHS :: Production m -> m Source #

Returns the morphism K -> R of the given production

getNACs :: Production m -> [m] Source #

Returns the set of nacs L -> Ni of the given production

Basic Functions

invertProductionWithoutNacs :: Production m -> Production m Source #

Discards the NACs of a production and inverts it.

deletedNodes :: GraphRule a b -> [NodeId] Source #

Return the nodes deleted by a rule

deletedEdges :: GraphRule a b -> [EdgeId] Source #

Return the edges deleted by a rule

createdNodes :: GraphRule a b -> [NodeId] Source #

Return the nodes created by a rule

createdEdges :: GraphRule a b -> [EdgeId] Source #

Return the edges created by a rule

emptyGraphRule :: Graph (Maybe a) (Maybe b) -> Production (TypedGraphMorphism a b) Source #

Returns an empty GraphRule

nullGraphRule :: GraphRule a b -> Bool Source #

Checks if it is a null rule

buildGraphRule :: Graph (Maybe a) (Maybe b) -> ListOfNodesAndEdges -> ListOfNodesAndEdges -> ListOfNodesAndEdges -> [ListOfNodesAndEdges] -> Production (TypedGraphMorphism a b) Source #

It builds a GraphRule with lists of deleted, created, preserved and forbidden elements

checkDeletion :: Eq t => TypedGraphMorphism a b -> TypedGraphMorphism a b -> (TypedGraphMorphism a b -> t -> Maybe t) -> (TypedGraphMorphism a b -> [t]) -> t -> Bool Source #

TODO: Find a better name for this function, that was repeated both here and in the GraphRule archive | Given the left-hand-side morphism of a rule l : K -> L, a match m : L -> G for this rule, an element e (that can be either a Node or an Edge) and two functions apply (for applying that element in a TypedGraphMorphism) and list (to get all the corresponding elements in the domain of m), it returns true if e is deleted by this rule for the given match

Orphan instances