Commit f3450b8e authored by Manuel Grizonnet's avatar Manuel Grizonnet
Browse files

WRG: virtual non void without retur in gistable.h

parent 6b74db06
......@@ -88,7 +88,7 @@ public:
itkSetObjectMacro(Connection, ConnectionType);
/** Clear the vector data not implemented yet*/
virtual bool Clear(){};
virtual bool Clear(){return true;};
/** Get attributes of the Table*/ //TODO implement
......@@ -108,7 +108,7 @@ public:
virtual std::string GetProjectionRef() const;
/** Get string connection usable by OGR library*/
virtual std::string GetOGRStrConnection() const {};
virtual std::string GetOGRStrConnection() const {return 0;};
/** Add an alpha numeric column to the table */
virtual const std::string AddVarCharColumn(unsigned int size) {};
......
......@@ -127,7 +127,8 @@ VectorDataToGISTableFilter< TVectorData, TGISTable >
/**Name of the table is settedd automaticcaly to "vector_data_to_gis"*/
// output->SetTableName ("vector_data_to_gis");
output->SetTableName (this->GetGISTableName());
//output->SetTableName (this->GetGISTableName());
output->SetTableName ("");
/**Create the PostgreSQL table*/
//output->CreateTable(m_DropExistingGISTable);
......@@ -152,7 +153,16 @@ VectorDataToGISTableFilter< TVectorData, TGISTable >
//Write VectorData to the GIS Table using OGR translation
gisWriter->SetFileName(outputOGRConnStr);
otbGenericMsgDebugMacro(<<"Write vector data to GIS table " << outputOGRConnStr);
gisWriter->Write(input);
//Write with overwrite =true option
std::string overStr("OVERWRITE=yes");
char *overOptions[]={ const_cast <char *> (overStr.c_str()) };
// std::cout << *overOptions << std::endl;
gisWriter->Write(input, overOptions);
output->SetTableName (inputRoot->Get()->GetNodeId());
std::cout << "tablename " << output->GetTableName() << std::endl;
}
else
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment