Programs::TARIS_TreesDistance Class Reference

Programa calcula la distancia entre dos árboles generados con TARIS-BuildTree. More...

List of all members.

Static Public Member Functions

static string usage ()
static int main (int argc, char **argv)


Detailed Description

Programa calcula la distancia entre dos árboles generados con TARIS-BuildTree.

Author:
Néstor Aguirre
Fecha de creación : 2007-03-18

Definition at line 43 of file TARIS-TreesDistance.cpp.


Member Function Documentation

static string Programs::TARIS_TreesDistance::usage (  )  [inline, static]

Definition at line 45 of file TARIS-TreesDistance.cpp.

Referenced by main().

00046                 {
00047                         system("clear") ;
00048                         return
00049                         "=================================\n"
00050                         "TARIS-TreesDistance (" __DATE__ ")\n"
00051                         "=================================\n"
00052                         "\n"
00053                         "Returns the distance between two trees that have been previously generated\n"
00054                         "with the TARIS-BuildTree program\n"
00055                         "\n"
00056                         "Syntax:\n"
00057                         "   $ TARIS-TreesDistance file1 file2\n"
00058                         "\n"
00059                         "Required parameters:\n"
00060                         "   file1\n"
00061                         "      This is the name of the first tree in gml format\n"
00062                         "   file2\n"
00063                         "      This is the name of the second tree in gml format\n"
00064                         "\n"
00065                         "For example:\n"
00066                         "\n"
00067                         "   $ TARIS-BuildTree -c file1.cube -o file1.gml\n"
00068                         "   $ TARIS-BuildTree -c file2.cube -o file2.gml\n"
00069                         "   $ TARIS-TreesDistance file1.gml file2.gml\n"
00070                         "\n"
00071                         "Authors:\n"
00072                         "   Nestor F. Aguirre, Ray M. Marin and Edgar E. Daza\n"
00073                         "   Universidad Nacional de Colombia\n"
00074                         ;
00075                 }

static int Programs::TARIS_TreesDistance::main ( int  argc,
char **  argv 
) [inline, static]

Definition at line 77 of file TARIS-TreesDistance.cpp.

References Tree::distance(), and usage().

Referenced by main().

00078                 {
00079                         
00080                         if( argc == 3 ){
00081                                 
00082                                 string gmlFileName1 = argv[1] ;
00083                                 string gmlFileName2 = argv[2] ;
00084                                 
00085                                 Tree tree1 ;
00086                                 tree1.load( gmlFileName1 ) ;
00087                                 
00088                                 Tree tree2 ;
00089                                 tree2.load( gmlFileName2 ) ;
00090                                 
00091                                 cout << "DISTANCE IS: " << Tree::distance( tree1, tree2 ) << endl ;
00092                                 
00093                         }else{
00094                                 cout << usage() << endl ;
00095                         }
00096                         
00097                         return EXIT_SUCCESS;
00098                 }


The documentation for this class was generated from the following file:
Generated on Mon May 26 20:29:48 2008 for TARIS by  doxygen 1.5.4