Skip to content
Snippets Groups Projects
Commit 94aaa7f0 authored by Giovanni Bussi's avatar Giovanni Bussi
Browse files

Passing by reference and not by value

(asked by Gareth)
parent fc3584f3
No related branches found
No related tags found
No related merge requests found
...@@ -90,7 +90,7 @@ unsigned PointWiseMapping::getPropertyIndex( const std::string& name ) const { ...@@ -90,7 +90,7 @@ unsigned PointWiseMapping::getPropertyIndex( const std::string& name ) const {
return 0; return 0;
} }
void PointWiseMapping::print( const std::string& method, double time, OFile& afile, const std::string& fmt ){ void PointWiseMapping::print( const std::string& method, const double & time, OFile& afile, const std::string& fmt ){
std::string descr2, descr="DESCRIPTION: results from %s analysis performed at time " + fmt +"\n"; std::string descr2, descr="DESCRIPTION: results from %s analysis performed at time " + fmt +"\n";
afile.printf(descr.c_str(), method.c_str(), time ); afile.printf(descr.c_str(), method.c_str(), time );
if(fmt.find("-")!=std::string::npos){ if(fmt.find("-")!=std::string::npos){
......
...@@ -75,7 +75,7 @@ public: ...@@ -75,7 +75,7 @@ public:
/// Get a pointer to the matrix of pairwise distances /// Get a pointer to the matrix of pairwise distances
Matrix<double>& modifyDmat(); Matrix<double>& modifyDmat();
/// Print out the low dimensional mapping /// Print out the low dimensional mapping
void print( const std::string& method, double time, OFile& afile, const std::string& fmt ); void print( const std::string& method, const double & time, OFile& afile, const std::string& fmt );
/// Get the low dimensional embedding coordinate /// Get the low dimensional embedding coordinate
double getProjectionCoordinate( const unsigned& iframe, const unsigned& jcoord ) const ; double getProjectionCoordinate( const unsigned& iframe, const unsigned& jcoord ) const ;
/// Set the value of the projection coordinate /// Set the value of the projection coordinate
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment