Skip to content

Commit

Permalink
Re #9483. Removing using directives from headers.
Browse files Browse the repository at this point in the history
  • Loading branch information
peterfpeterson committed May 20, 2014
1 parent 2d01a32 commit ae7b563
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 19 deletions.
Expand Up @@ -10,8 +10,6 @@
#include "MantidKernel/IPropertyManager.h"
#include "MantidAPI/AnalysisDataService.h"

using Mantid::Kernel::IPropertyManager;

namespace Mantid
{
namespace API
Expand Down Expand Up @@ -69,7 +67,7 @@ namespace API
* other property values?
* @return true if fulfilled or if any problem was found (missing property, e.g.).
*/
virtual bool fulfillsCriterion(const IPropertyManager * algo) const
virtual bool fulfillsCriterion(const Kernel::IPropertyManager * algo) const
{
// Find the property
if (algo == NULL) return true;
Expand Down Expand Up @@ -108,14 +106,14 @@ namespace API

//--------------------------------------------------------------------------------------------
/// Return true/false based on whether the other property satisfies the criterion
virtual bool isEnabled(const IPropertyManager * algo) const
virtual bool isEnabled(const Kernel::IPropertyManager * algo) const
{
return fulfillsCriterion(algo);
}

//--------------------------------------------------------------------------------------------
/// Return true always
virtual bool isVisible(const IPropertyManager * ) const
virtual bool isVisible(const Kernel::IPropertyManager * ) const
{
return true;
}
Expand Down
2 changes: 1 addition & 1 deletion Code/Mantid/Framework/API/inc/MantidAPI/FunctionFactory.h
Expand Up @@ -68,7 +68,7 @@ namespace API
/// Query available functions based on the template type
template<typename FunctionType>
const std::vector<std::string>& getFunctionNames() const;

// Unhide the base class version (to satisfy the intel compiler)
using Kernel::DynamicFactory<IFunction>::subscribe;
void subscribe(const std::string& className, AbstractFactory* pAbstractFactory,
Kernel::DynamicFactory<IFunction>::SubscribeAction replace=ErrorIfExists);
Expand Down
Expand Up @@ -8,8 +8,6 @@
#include "MantidAPI/IFunction1D.h"
#include "MantidGeometry/Crystal/UnitCell.h"

using namespace std;

namespace Mantid
{
namespace API
Expand Down
22 changes: 11 additions & 11 deletions Code/Mantid/Framework/API/src/IPowderDiffPeakFunction.cpp
Expand Up @@ -146,7 +146,7 @@ namespace API
double IPowderDiffPeakFunction::getMaximumValue(const std::vector<double>& xValues, size_t& indexmax) const
{
// Calculate function with given data points
vector<double> out(xValues.size(), 0.);
std::vector<double> out(xValues.size(), 0.);
function(out, xValues);

// Find out the maximum value
Expand All @@ -173,9 +173,9 @@ namespace API
if (mHKLSet)
{
// Throw exception if tried to reset the miller index
stringstream errss;
std::stringstream errss;
errss << "Profile function " << name() << "cannot have (HKL) reset.";
throw runtime_error(errss.str());
throw std::runtime_error(errss.str());
}
else
{
Expand All @@ -191,7 +191,7 @@ namespace API
// Check value valid or not
if (mH*mH + mK*mK + mL*mL < 1.0E-8)
{
stringstream errmsg;
std::stringstream errmsg;
errmsg << "H = K = L = 0 is not allowed";
throw std::invalid_argument(errmsg.str());
}
Expand Down Expand Up @@ -231,7 +231,7 @@ namespace API
*/
bool IPowderDiffPeakFunction::hasProfileParameter(std::string paramname)
{
vector<string>::iterator niter;
std::vector<std::string>::iterator niter;
niter = lower_bound(m_sortedProfileParameterNames.begin(), m_sortedProfileParameterNames.end(),
paramname);
if (niter == m_sortedProfileParameterNames.end())
Expand All @@ -258,17 +258,17 @@ namespace API
if (fabs(az) < 1.0E-8)
{
// If z = 0, then the result is infinity... diverge!
complex<double> r(1.0E300, 0.0);
std::complex<double> r(1.0E300, 0.0);
exp_e1 = r;
}
else if (az <= 10.0 || (rz < 0.0 && az < 20.0))
{
// Some interesting region, equal to integrate to infinity, converged
// cout << "[DB] Type 1" << endl;

complex<double> r(1.0, 0.0);
std::complex<double> r(1.0, 0.0);
exp_e1 = r;
complex<double> cr = r;
std::complex<double> cr = r;

for (size_t k = 1; k <= 150; ++k)
{
Expand All @@ -289,18 +289,18 @@ namespace API
else
{
// Rest of the region
complex<double> ct0(0.0, 0.0);
std::complex<double> ct0(0.0, 0.0);
for (int k = 120; k > 0; --k)
{
complex<double> dk(double(k), 0.0);
std::complex<double> dk(double(k), 0.0);
ct0 = dk / (10.0 + dk / (z + ct0));
} // ENDFOR k

exp_e1 = 1.0 / (z + ct0);
exp_e1 = exp_e1 * exp(-z);
if (rz < 0.0 && fabs(imag(z)) < 1.0E-10 )
{
complex<double> u(0.0, 1.0);
std::complex<double> u(0.0, 1.0);
exp_e1 = exp_e1 - (PI * u);
}
}
Expand Down
Expand Up @@ -122,6 +122,7 @@ const double PEAKRANGE = 5.0;
const double TWO_OVER_PI = 2./PI;
const double NEG_DBL_MAX = -1.*DBL_MAX;

using namespace std;

namespace Mantid
{
Expand Down

0 comments on commit ae7b563

Please sign in to comment.