wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData > Class Reference

Inheritance diagram for wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >:

Inheritance graph

List of all members.

Public Member Functions

int AddLeafNode (int parentID, LeafNodeData nodeData)
int AddNode (int parentID, TreeNodeData nodeData)
void Clear (TreeNodeData rootNodeData)
bool ContainsFile (string filename)
bool ContainsLeafNode (int nodeID)
bool ContainsTreeNode (int nodeID)
ICollection< int > GetLeafNodeChildren (int nodeID)
LeafNodeData GetLeafNodeData (int nodeID)
int GetParent (int nodeID)
System.Xml.Schema.XmlSchema GetSchema ()
ICollection< int > GetTreeNodeChildren (int nodeID)
TreeNodeData GetTreeNodeData (int nodeID)
ICollection< int > NodesReferringToFile (string filename)
void NormalizeOriginalFileNames (string nameOfAValidDirOrFile)
void ReadXml (System.Xml.XmlReader reader)
int RemoveChildren (int nodeid)
int RemoveNode (int nodeid)
override string ToString ()
 TreeOfContentFiles (TreeNodeData rootData)
void WriteXml (System.Xml.XmlWriter writer)

Properties

int Count [get]
int CountLeafNodes [get]
ICollection
< LeafNodeData > 
LeafNodeDataCollection [get]
ICollection< int > LeafNodes [get]
ICollection< string > ReferredFiles [get]
ICollection
< TreeNodeData > 
TreeNodeDataCollection [get]
ICollection< int > TreeNodes [get]

Classes

class  LeafNode
class  TreeNode


Detailed Description

A class template representing a tree where nodes will be associated with data. the leafs of this tree are associated with implementations of wx.Build.ISingleFileProduct.

Constructor & Destructor Documentation

wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.TreeOfContentFiles ( TreeNodeData  rootData  ) 


Member Function Documentation

int wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.AddLeafNode ( int  parentID,
LeafNodeData  nodeData 
)

Adds a new leaf node to the node designated by the provided parent ID.

Parameters:
parentID ID of the parent. Use 0 to add a node directly to the root.
nodeData Data that will be associated with the node. This shall not be null.
Returns:
The ID of the new node.
See also:
AddNode

int wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.AddNode ( int  parentID,
TreeNodeData  nodeData 
)

Adds a node to the tree.

Parameters:
parentID ID of the parent. Use 0 to add a node directly to the root.
nodeData Data that will be associated with the node. This may be null here.
Returns:
The ID of the new node.
See also:
AddLeafNode

void wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.Clear ( TreeNodeData  rootNodeData  ) 

Clears up this instance. All nodes will be removed. This will create a new root node bearing the provided data.

Parameters:
rootNodeData The data of the new root node. This may be null.

bool wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.ContainsFile ( string  filename  ) 

True iff this contains data referring to a local file of the provided name. Operates on a dictionary that will be filled if adding leaf node data implementing wx.Build.ISingleFleProduct.

Parameters:
filename The filename that will be tested.
Returns:
True iff the argument is already associated with at least one leaf node.

bool wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.ContainsLeafNode ( int  nodeID  ) 

True iff the argument designates a leaf node.

Parameters:
nodeID The node ID that will be tested.

bool wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.ContainsTreeNode ( int  nodeID  ) 

True iff the argument designates a non-leaf node.

Parameters:
nodeID The node ID that will be tested.

ICollection<int> wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.GetLeafNodeChildren ( int  nodeID  ) 

If the argument designates a tree node with leafs as children, this will return a collection of the IDs of these children. Otherwise, the result is empty.

Parameters:
nodeID The ID of a non-leave tree node.
Returns:

LeafNodeData wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.GetLeafNodeData ( int  nodeID  ) 

Gets the data associated with the designated leaf node.

Parameters:
nodeID ID of a tree node.
Returns:
The data or default(TreeNodeData) if the data does not exist or the node is unknown.

int wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.GetParent ( int  nodeID  ) 

The ID of the parent of the designated node or -1 if this does not exist.

Parameters:
nodeID ID of the node.
Returns:
The ID of the parent or -1 if the argument does not exist or is root.

System.Xml.Schema.XmlSchema wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.GetSchema (  ) 

Returns null as suggested by the framework documentation.

Returns:
null

ICollection<int> wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.GetTreeNodeChildren ( int  nodeID  ) 

If the argument designates a tree node with non-leafs as children, this will return a collection of the IDs of these children. Otherwise, the result is empty.

Parameters:
nodeID The ID of a non-leave tree node.
Returns:

TreeNodeData wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.GetTreeNodeData ( int  nodeID  ) 

Gets the data associated with the designated node.

Parameters:
nodeID ID of a tree node. Use 0 to access data of the root node.
Returns:
The data or default(TreeNodeData) if the data does not exist or the node is unknown.

ICollection<int> wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.NodesReferringToFile ( string  filename  ) 

Returns an optionally empty collection of node indices designating those nodes referring to a file of the provided file name.

Parameters:
filename name of the file
Returns:
A collection of leaf nodes referring to this file. Do not edit this collection.

void wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.NormalizeOriginalFileNames ( string  nameOfAValidDirOrFile  ) 

void wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.ReadXml ( System.Xml.XmlReader  reader  ) 

Read the data of this instance from a Xml stream.

Parameters:
reader The data source
Exceptions:
FormatException Raised on unexpected structure of teh Xml code.
See also:
WriteXml

int wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.RemoveChildren ( int  nodeid  ) 

Removes the children of the designated node, tree nodes as well as leaf nodes.

Parameters:
nodeid The root to remove.
Returns:
The number of removed nodes including the nodes of the removed subtree.

int wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.RemoveNode ( int  nodeid  ) 

Removes the designated node and the subtree beneath this node (if this is not a leaf).

Parameters:
nodeid The root to remove. This may also be a leaf node.
Returns:
The number of removed nodes including the nodes of the removed subtree.

override string wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.ToString (  ) 

void wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.WriteXml ( System.Xml.XmlWriter  writer  ) 

Write the content to the provided XML destination.

Parameters:
writer The destination of the output
See also:
ReadXml


Property Documentation

int wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.Count [get]

The number of all nodes.

int wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.CountLeafNodes [get]

The number of contained leaf nodes.

ICollection<LeafNodeData> wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.LeafNodeDataCollection [get]

A collection of the data instances attached to leaf nodes.

ICollection<int> wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.LeafNodes [get]

Returns a collection containing all keys of leaf nodes.

ICollection<string> wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.ReferredFiles [get]

A sorted collection of all local filenames associated with leaf nodes. Operates on a dictionary that will be filled if adding leaf node data implementing wx.Build.ISingleFleProduct.

ICollection<TreeNodeData> wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.TreeNodeDataCollection [get]

A collection of the data instances attached to non-leaf nodes.

ICollection<int> wx.PackageBuilder.TreeOfContentFiles< TreeNodeData, LeafNodeData >.TreeNodes [get]

This is a collection of all IDs of non-leaf nodes.


The wx.NET Build System.   (c) 2009-2010 Harald Meyer auf'm Hofe