Changeset 12706 for issm/trunk/src/c/objects/KML/KML_Point.cpp
- Timestamp:
- 07/24/12 10:36:19 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk/src/c/objects/KML/KML_Point.cpp
r11237 r12706 4 4 5 5 /*Headers:*/ 6 /*{{{ 1*/6 /*{{{*/ 7 7 #ifdef HAVE_CONFIG_H 8 8 #include <config.h> … … 22 22 23 23 /*Constructors/destructor/copy*/ 24 /*FUNCTION KML_Point::KML_Point(){{{ 1*/24 /*FUNCTION KML_Point::KML_Point(){{{*/ 25 25 KML_Point::KML_Point(){ 26 26 … … 34 34 } 35 35 /*}}}*/ 36 /*FUNCTION KML_Point::~KML_Point(){{{ 1*/36 /*FUNCTION KML_Point::~KML_Point(){{{*/ 37 37 KML_Point::~KML_Point(){ 38 38 … … 43 43 44 44 /*Other*/ 45 /*FUNCTION KML_Point::Echo {{{ 1*/45 /*FUNCTION KML_Point::Echo {{{*/ 46 46 void KML_Point::Echo(){ 47 47 48 48 bool flag=true; 49 49 50 _printf_(flag,"KML_Point:\n");50 if(flag) _pprintLine_("KML_Point:"); 51 51 KML_Geometry::Echo(); 52 52 53 _printf_(flag," extrude: %s\n" ,(extrude ? "true" : "false"));54 _printf_(flag," altmode: \"%s\"\n" ,altmode);55 _printf_(flag," coords: (%g,%g,%g)\n" ,coords[0],coords[1],coords[2]);53 if(flag) _pprintLine_(" extrude: " << (extrude ? "true" : "false")); 54 if(flag) _pprintLine_(" altmode: \"" << altmode << "\""); 55 if(flag) _pprintLine_(" coords: (" << coords[0] << "," << coords[1] << "," << coords[2] << ")"); 56 56 57 57 return; 58 58 } 59 59 /*}}}*/ 60 /*FUNCTION KML_Point::DeepEcho {{{ 1*/60 /*FUNCTION KML_Point::DeepEcho {{{*/ 61 61 void KML_Point::DeepEcho(){ 62 62 … … 68 68 } 69 69 /*}}}*/ 70 /*FUNCTION KML_Point::DeepEcho {{{ 1*/70 /*FUNCTION KML_Point::DeepEcho {{{*/ 71 71 void KML_Point::DeepEcho(const char* indent){ 72 72 73 73 bool flag=true; 74 74 75 _printf_(flag,"%sKML_Point:\n",indent);75 if(flag) _pprintLine_(indent << "KML_Point:"); 76 76 KML_Geometry::DeepEcho(indent); 77 77 78 _printf_(flag,"%s extrude: %s\n" ,indent,(extrude ? "true" : "false"));79 _printf_(flag,"%s altmode: \"%s\"\n" ,indent,altmode);80 _printf_(flag,"%s coords: (%g,%g,%g)\n" ,indent,coords[0],coords[1],coords[2]);78 if(flag) _pprintLine_(indent << " extrude: " << (extrude ? "true" : "false")); 79 if(flag) _pprintLine_(indent << " altmode: \"" << altmode << "\""); 80 if(flag) _pprintLine_(indent << " coords: (" << coords[0] << "," << coords[1] << "," << coords[2] << ")"); 81 81 82 82 return; 83 83 } 84 84 /*}}}*/ 85 /*FUNCTION KML_Point::Write {{{ 1*/85 /*FUNCTION KML_Point::Write {{{*/ 86 86 void KML_Point::Write(FILE* filout,const char* indent){ 87 87 … … 103 103 } 104 104 /*}}}*/ 105 /*FUNCTION KML_Point::Read {{{ 1*/105 /*FUNCTION KML_Point::Read {{{*/ 106 106 void KML_Point::Read(FILE* fid,char* kstr){ 107 107 … … 126 126 } 127 127 else if (!strncmp(kstri,"</",2)) 128 _error_("KML_Point::Read -- Unexpected closing tag %s.\n",kstri);128 {_error2_("KML_Point::Read -- Unexpected closing tag " << kstri << ".\n");} 129 129 else if (strncmp(kstri,"<",1)) 130 _error_("KML_Point::Read -- Unexpected field \"%s\".\n",kstri);130 {_error2_("KML_Point::Read -- Unexpected field \"" << kstri << "\".\n");} 131 131 132 132 else if (!strcmp(kstri,"<extrude>")) 133 KMLFileTokenParse(&extrude , 134 kstri, 135 fid); 133 KMLFileTokenParse(&extrude , kstri, fid); 136 134 else if (!strcmp(kstri,"<altitudeMode>")) 137 KMLFileTokenParse( altmode ,NULL,KML_POINT_ALTMODE_LENGTH, 138 kstri, 139 fid); 135 KMLFileTokenParse( altmode ,NULL,KML_POINT_ALTMODE_LENGTH, kstri, fid); 140 136 else if (!strcmp(kstri,"<coordinates>")) 141 KMLFileTokenParse(&pcoords ,NULL,3, 142 kstri, 143 fid); 137 KMLFileTokenParse(&pcoords ,NULL,3, kstri, fid); 144 138 145 139 else if (!strncmp(kstri,"<",1)) … … 158 152 } 159 153 /*}}}*/ 160 /*FUNCTION KML_Point::WriteExp {{{ 1*/154 /*FUNCTION KML_Point::WriteExp {{{*/ 161 155 void KML_Point::WriteExp(FILE* fid,const char* nstr,int sgn,double cm,double sp){ 162 156
Note:
See TracChangeset
for help on using the changeset viewer.