00001 /*** 00002 * Copyright (c) 2005, SkeTo Project 00003 * All rights reserved. 00004 */ 00012 #ifndef __DIST_ROSE_TREE_H__ 00013 #define __DIST_ROSE_TREE_H__ 00014 00015 #include "dist_tree.h" 00016 #include <fstream> 00017 00018 class rose_tree_skeletons; 00019 class rose_tree_skeletons_impl; 00020 00028 template< typename A > 00029 class dist_rose_tree 00030 { 00031 friend class rose_tree_skeletons; 00032 friend class rose_tree_skeletons_impl; 00033 00034 private: 00036 dist_tree< A >* btree; 00037 00044 private: 00045 dist_rose_tree( ); 00046 00053 private: 00054 dist_rose_tree( dist_tree< A >* btree_ ); 00055 00059 public: 00060 ~dist_rose_tree( ); 00061 00065 public: 00066 static dist_rose_tree< A >* 00067 read_from_file( const char* filename ); 00068 00072 public: 00073 bool write_to_file( const char *filename ) const; 00074 00081 public: 00082 void print( ) const; 00083 00084 public: 00085 void setroot( const A& val ); 00086 }; 00087 00088 #include "dist_rose_tree.tpp" 00089 00090 #endif // __DIST_TREE_H__