| 
    CXXR (C++ R) API
    
   | 
 
Record of bindings read by top-level command. More...
#include <CommandChronicle.hpp>


Public Types | |
| typedef std::vector< GCEdge < const Provenance > >  | ParentVector | 
| Vector type used to record bindings read.   | |
Public Member Functions | |
| CommandChronicle (const RObject *command_arg) | |
| Constructor.   | |
| const ParentVector & | bindingsRead () const | 
| Vector of bindings read.   | |
| void | close () | 
| Close the CommandChronicle to new entries.   | |
| const RObject * | command () const | 
| The top-level command.   | |
| void | readBinding (const Provenance *bdgprov) | 
| Report reading of a provenance-tracked binding.   | |
| void | writeBinding (const Provenance *bdgprov) | 
| Report writing of a provenance-tracked binding.   | |
| void | detachReferents () | 
| Null out all references from this node to other nodes.   | |
| void | visitReferents (const_visitor *v) const | 
| Conduct a visitor to the nodes referred to by this one.   | |
  Public Member Functions inherited from CXXR::GCNode | |
| void | expose () const | 
| Record that construction of a node is complete.   | |
| bool | isExposed () const | 
| Has this node been exposed to garbage collection?   | |
  Public Member Functions inherited from CXXR::HeterogeneousListBase::Link | |
| Link () | |
| Default constructor.   | |
| Link (HeterogeneousListBase *list) | |
| Appending constructor.   | |
| void | freeLink () | 
| Detach Link from any list.   | |
Friends | |
| class | boost::serialization::access | 
| class | Provenance | 
Additional Inherited Members | |
  Static Public Member Functions inherited from CXXR::GCNode | |
| static void * | operator new (size_t bytes) | 
| Allocate memory.   | |
| static void * | operator new (size_t, void *where) | 
| Placement new for GCNode.  | |
| static void | operator delete (void *p, size_t bytes) | 
| Deallocate memory.   | |
| static bool | check () | 
| Integrity check.   | |
| template<class T > | |
| static T * | expose (T *node) | 
| Record that construction of a node is complete.   | |
| static void | gc () | 
| Initiate a garbage collection.  | |
| static void | gclite () | 
| Lightweight garbage collection.   | |
| static void | maybeCheckExposed (const GCNode *node) | 
| Subject to configuration, check that a GCNode is exposed.   | |
| static size_t | numNodes () | 
| Number of GCNode objects in existence.   | |
  Protected Member Functions inherited from CXXR::GCNode | |
| virtual | ~GCNode () | 
  Protected Member Functions inherited from CXXR::HeterogeneousListBase::Link | |
| virtual | ~Link () | 
Record of bindings read by top-level command.
This class maintains a record of the provenances of any provenance-tracked bindings read in the course of evaluating a top-level command. The record includes only binding states which were in existence before evaluation of the top-level command started: i.e. the record ignores binding states which are created and subsequently read back in the course of evaluating the top-level command.
The record is in the form of a vector, ordered according to the time when a particular binding state is first read during the evaluation of the top-level command.
| typedef std::vector<GCEdge<const Provenance> > CXXR::CommandChronicle::ParentVector | 
Vector type used to record bindings read.
This is the type of vector used to record the provenances of the binding states read during the evaluation of a top-level command.
      
  | 
  inline | 
Constructor.
| command_arg | Pointer to the top-level command to which this Chronicle relates. This will usually, but not necessarily, be an Expression. | 
      
  | 
  inline | 
Vector of bindings read.
      
  | 
  inline | 
Close the CommandChronicle to new entries.
This function is to be called to signify that evaluation of the top-level command is complete, and that there will therefore be no further calls to readBinding() in respect of this object. This is a cue to release housekeeping data structures.
      
  | 
  inline | 
The top-level command.
      
  | 
  virtual | 
Null out all references from this node to other nodes.
The referents of this node are those objects (derived from GCNode) designated by a GCEdge within this object. This function changes all GCEdges within this object to encapsulate a null pointer. It is used during the sweep phase of a mark-sweep garbage collection to break up unreachable subgraphs, and in particular to remove reference loops from them. After the application of this method, the GCNode should be regarded as a 'zombie', kept in existence only so other nodes can detach their references to it cleanly (using decRefCount()).
Reimplemented from CXXR::GCNode.
| void CXXR::CommandChronicle::readBinding | ( | const Provenance * | bdgprov | ) | 
Report reading of a provenance-tracked binding.
This function should be called whenever the top-level command reads a Frame::Binding with non-null Provenance.
| bdgprov | Non-null pointer to the Provenance of a Frame::Binding read by the top-level command. | 
      
  | 
  virtual | 
Conduct a visitor to the nodes referred to by this one.
The referents of this node are those objects (derived from GCNode) designated by a GCEdge within this object.
| v | Pointer to the visitor object. | 
Reimplemented from CXXR::GCNode.
| void CXXR::CommandChronicle::writeBinding | ( | const Provenance * | bdgprov | ) | 
Report writing of a provenance-tracked binding.
This function should be called whenever the top-level command creates or changes the state of a Frame::Binding with non-null Provenance.
| bdgprov | Non-null pointer to the Provenance of a Frame::Binding created or modified by the top-level command. | 
 1.8.1