Back to index

See source file

PHCompositeNode.h

 
//----------------------------------------------------------------------------- 
//  $Header: /afs/rhic/phenix/cvsroot/offline/framework/phool/PHCompositeNode.h,v 1.8 1999/10/27 18:21:41 messer Exp $ 
// 
//  The PHOOL Program Library   
//  Copyright (C) PHENIX collaboration, 1999 
// 
//  Declaration of class PHCompositeNode 
// 
//  Purpose: a node which can hold other nodes 
// 
//----------------------------------------------------------------------------- 
#ifndef PHCOMPOSITENODE_H 
#define PHCOMPOSITENODE_H 
 
#include "phool.h" 
#include "PHNode.h" 
#include "PHPointerList.h" 
 
class PHIOManager; 
class PHNodeIterator; 
 
class PHCompositeNode : public PHNode {  
 
   friend class PHNodeIterator; 
    
public:  
   PHCompositeNode(const PHString &);  
   virtual ~PHCompositeNode();  
 
private: 
   PHCompositeNode(); 
    
public: 
 
   // 
   // The user is only allowed to add new nodes, not to delete existing ones. 
   // 
   PHBoolean addNode(PHNode*); 
 
   // 
   // This recursively calls the prune function of all the subnodes. 
   // If a subnode is found to be marked as transient (non persistent) 
   // the entire sub-tree is deleted. 
   // 
   virtual void prune(); 
 
   // 
   // I/O functions 
   // 
   void print(const PHString& = ""); 
   virtual PHBoolean write(PHIOManager *, const PHString& = ""); 
 
protected: 
   virtual void forgetMe(PHNode*); 
    
protected: 
   PHPointerList<PHNode> subNodes; 
};  
 
#endif /* PHCOMPOSITENODE_H */  
 
 
 
 
 

Back to index

See source file