}
// -------------------------------------------------------------------------
-std::string cpPluginsIO::MeshWriter::
+void cpPluginsIO::MeshWriter::
_GenerateData( )
{
auto mesh = this->GetInputData( "Input" )->GetVTK< vtkPolyData >( );
if( mesh == NULL )
- return( "MeshWriter: No suitable input." );
+ this->_Error( "No suitable input." );
// Get file extension
auto fname = this->m_Parameters.GetSaveFileName( "FileName" );
stlw->SetFileName( fname.c_str( ) );
stlw->Update( );
if( stlw->GetErrorCode( ) != 0 )
- return( "MeshWriter: someting wrong happened." );
- else
- return( "" );
+ this->_Error( "Someting wrong happened." );
}
else if( ext == "vtk" )
{
pdw->SetFileName( fname.c_str( ) );
pdw->Update( );
if( pdw->GetErrorCode( ) != 0 )
- return( "MeshWriter: someting wrong happened." );
- else
- return( "" );
+ this->_Error( "Someting wrong happened." );
}
else
- return( "MeshWriter: Input file format not recognized." );
+ this->_Error( "Input file format not recognized." );
}
// eof - $RCSfile$