Skip to content

Commit

Permalink
Re #11825 Applying naming conventions
Browse files Browse the repository at this point in the history
  • Loading branch information
raquelalvarezbanos committed May 22, 2015
1 parent e320103 commit d4f3700
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,16 +77,16 @@ class DLLExport AppendGeometryToSNSNexus : public API::Algorithm {
bool m_makeNexusCopy;

/// Algorithm progress keeper
API::Progress *progress;
API::Progress *m_progress;

/// The workspace to load instrument and logs
API::MatrixWorkspace_sptr ws;

/// Was the instrument loaded?
bool instrument_loaded_correctly;
bool m_instrumentLoadedCorrectly;

/// Were the logs loaded?
bool logs_loaded_correctly;
bool m_logsLoadedCorrectly;
};

} // namespace DataHandling
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ DECLARE_ALGORITHM(AppendGeometryToSNSNexus)
/** Constructor
*/
AppendGeometryToSNSNexus::AppendGeometryToSNSNexus()
: m_makeNexusCopy(false), progress(), instrument_loaded_correctly(false),
logs_loaded_correctly(false) {}
: m_makeNexusCopy(false), m_progress(), m_instrumentLoadedCorrectly(false),
m_logsLoadedCorrectly(false) {}

//----------------------------------------------------------------------------------------------
/** Destructor
Expand Down Expand Up @@ -146,23 +146,23 @@ void AppendGeometryToSNSNexus::exec() {
if (m_instrument == "HYSPEC" || m_instrument == "HYSPECA" ||
m_instrument == "SNAP") {
g_log.debug() << "Run LoadNexusLogs Child Algorithm." << std::endl;
logs_loaded_correctly = runLoadNexusLogs(m_filename, ws, this);
m_logsLoadedCorrectly = runLoadNexusLogs(m_filename, ws, this);

if (!logs_loaded_correctly)
if (!m_logsLoadedCorrectly)
throw std::runtime_error("Failed to run LoadNexusLogs Child Algorithm.");
}

g_log.debug() << "Run LoadInstrument Child Algorithm." << std::endl;
instrument_loaded_correctly = runLoadInstrument(m_idf_filename, ws, this);
m_instrumentLoadedCorrectly = runLoadInstrument(m_idf_filename, ws, this);

if (!instrument_loaded_correctly)
if (!m_instrumentLoadedCorrectly)
throw std::runtime_error("Failed to run LoadInstrument Child Algorithm.");

// Get the number of detectors (just for progress reporting)
// Get the number of histograms/detectors
const size_t numDetectors = ws->getInstrument()->getDetectorIDs().size();

this->progress = new API::Progress(this, 0.0, 1.0, numDetectors);
this->m_progress = new API::Progress(this, 0.0, 1.0, numDetectors);

// Get the instrument
Geometry::Instrument_const_sptr instrument = ws->getInstrument();
Expand Down Expand Up @@ -252,7 +252,7 @@ void AppendGeometryToSNSNexus::exec() {

nxfile.closeGroup(); // close NXdetector

this->progress->report(dets.size());
this->m_progress->report(dets.size());
} else {
throw std::runtime_error(
"Could not find any detectors for the bank named " +
Expand Down

0 comments on commit d4f3700

Please sign in to comment.