Lumiera  0.pre.03
»edit your freedom«
TestWireTap< PAR > Class Template Reference

Description

template<class PAR>
class lib::diff::anonymous_namespace{test-mutation-target.hpp}::TestWireTap< PAR >

Definition at line 350 of file test-mutation-target.hpp.

Public Member Functions

 TestWireTap (Target &dummy, PAR &&chain)
 
virtual bool accept_until (GenNode const &spec)
 repeatedly accept, until after the designated location
 
virtual bool acceptSrc (GenNode const &n) override
 accept existing element, when matching the given spec
 
virtual bool assignElm (GenNode const &spec)
 locate element already accepted into the target sequence and assign the designated payload value to it. More...
 
virtual bool completeScope ()
 verify all our pending (old) source elements where mentioned. More...
 
virtual bool findSrc (GenNode const &ref) override
 locate designated element and accept it at current position
 
virtual bool hasSrc () override
 
virtual void init () override
 
virtual bool injectNew (GenNode const &n) override
 record in the test target that a new child element is being inserted at current position More...
 
virtual bool matchSrc (GenNode const &n) override
 ensure the next recorded source element matches on a formal level with given spec
 
virtual bool mutateChild (GenNode const &spec, TreeMutator::Handle targetBuff)
 locate the designated target element and build a suitable sub-mutator for this element into the provided target buffer
 
virtual void skipSrc (GenNode const &n) override
 skip next recorded src element without touching it
 

Private Types

using Iter = TestMutationTarget::iterator
 
using Target = TestMutationTarget
 

Private Attributes

Iter pos_
 
Targettarget_
 

Member Function Documentation

◆ injectNew()

virtual bool injectNew ( GenNode const &  n)
inlineoverridevirtual

record in the test target that a new child element is being inserted at current position

Remarks
TestWireTap adapter together with TestMutationTarget maintain a "shadow copy" of the data and apply the detected diff against this internal copy. This allows to verify what's going on

Definition at line 385 of file test-mutation-target.hpp.

◆ assignElm()

virtual bool assignElm ( GenNode const &  spec)
inlinevirtual

locate element already accepted into the target sequence and assign the designated payload value to it.

Definition at line 483 of file test-mutation-target.hpp.

References lib::diff::anonymous_namespace{test-mutation-target.hpp}::render().

+ Here is the call graph for this function:

◆ completeScope()

virtual bool completeScope ( )
inlinevirtual

verify all our pending (old) source elements where mentioned.

Note
allows chained "onion-layers" to clean-up and verify.

Definition at line 519 of file test-mutation-target.hpp.

+ Inheritance diagram for TestWireTap< PAR >:
+ Collaboration diagram for TestWireTap< PAR >:

The documentation for this class was generated from the following file: