// -*- Mode: C++; tab-width: 2; -*-
// vi: set ts=2:
//
// $Id: PTE.iC,v 1.10 2003/08/26 08:04:16 oliver Exp $
//

BALL_INLINE 
void Element::clear()
{
  *this = UNKNOWN;
}

BALL_INLINE 
void Element::setName(const String& name)
{
  name_ = name;
}

BALL_INLINE 
const String& Element::getName() const
{
  return name_;
}

BALL_INLINE 
void Element::setSymbol(const String& symbol)
{
  symbol_ = symbol;
}

BALL_INLINE 
const String& Element::getSymbol() const
{
  return symbol_;
}

BALL_INLINE 
void Element::setGroup(Element::Group group)
{
  group_ = group;
}

BALL_INLINE 
Element::Group Element::getGroup() const
{
  return group_;
}

BALL_INLINE 
void Element::setPeriod(Element::Period period)
{
  period_ = period;
}

BALL_INLINE 
Element::Period Element::getPeriod() const
{
  return period_;
}

BALL_INLINE 
void Element::setAtomicNumber(Element::AtomicNumber atomic_number)
{
  atomic_number_ = atomic_number;
}

BALL_INLINE 
Element::AtomicNumber Element::getAtomicNumber() const
{
  return atomic_number_;
}

BALL_INLINE 
void Element::setAtomicWeight(float atomic_weight)
{
  atomic_weight_ = atomic_weight;
}

BALL_INLINE 
float Element::getAtomicWeight() const
{
  return atomic_weight_;
}

BALL_INLINE 
void Element::setAtomicRadius(float atomic_radius)
{
  atomic_radius_ = atomic_radius;
}

BALL_INLINE 
float Element::getAtomicRadius() const
{
  return atomic_radius_;
}

BALL_INLINE 
void Element::setCovalentRadius(float covalent_radius)
{
  covalent_radius_ = covalent_radius;
}

BALL_INLINE 
float Element::getCovalentRadius() const
{
  return covalent_radius_;
}

BALL_INLINE 
void Element::setVanDerWaalsRadius(float van_der_waals_radius)
{
  van_der_waals_radius_ = van_der_waals_radius;
}

BALL_INLINE 
float Element::getVanDerWaalsRadius() const
{
  return van_der_waals_radius_;
}

BALL_INLINE 
void Element::setElectronegativity(float electronegativity)
{
  electronegativity_ = electronegativity;
}

BALL_INLINE 
float Element::getElectronegativity() const
{
  return electronegativity_;
}

BALL_INLINE
bool Element::operator == (const Element& element) const
{
  return (atomic_number_ == element.atomic_number_);
}

BALL_INLINE 
bool Element::operator !=(const Element& element) const
{
  return (atomic_number_ != element.atomic_number_);
}

BALL_INLINE 
bool Element::operator < (const Element& element) const
{
  return (atomic_number_ < element.atomic_number_);
}

BALL_INLINE 
bool Element::operator <=(const Element& element) const
{
  return (atomic_number_ <= element.atomic_number_);
}

BALL_INLINE 
bool Element::operator >= (const Element& element) const
{
  return (atomic_number_ >= element.atomic_number_);
}

BALL_INLINE 
bool Element::operator >(const Element& element) const
{
  return (atomic_number_ > element.atomic_number_);
}

BALL_INLINE 
bool Element::isUnknown() const
{
  return operator==(Element::UNKNOWN);
}


BALL_INLINE 
void PTE_::clear()
{
}

BALL_INLINE 
Element& PTE_::operator [](const String& symbol)
{
  return getElement(symbol);
}

BALL_INLINE 
const Element& PTE_::operator [](const String& symbol) const
{
  return getElement(symbol);
}

BALL_INLINE 
Element& PTE_::operator [](Element::Name name)
{
  return element_[name];
}

BALL_INLINE 
const Element& PTE_::operator [](Element::Name name) const
{
  return element_[name];
}

BALL_INLINE 
Element& PTE_::operator [](Element::Symbol symbol)
{
  return element_[symbol];
}

BALL_INLINE 
const Element& PTE_::operator [](Element::Symbol symbol) const
{
  return element_[symbol];
}

BALL_INLINE 
Element& PTE_::operator [] (Position position)
{
  return ((position >= 1 && position <= Element::NUMBER_OF_ELEMENTS)
	  ? *atomic_number_to_element_[position - 1]
	  : Element::UNKNOWN);
}

BALL_INLINE 
const Element& PTE_::operator [] (Position position) const
{
  return ((PTE_ *)this)->operator[](position);
}

BALL_INLINE 
bool PTE_::operator == (const PTE_& /*pte*/) const
{
  return true;
}

BALL_INLINE 
PTE_& PTE_::operator = (const PTE_& /*pte*/)
{
	return *this;
}
