Changeset 1569 for trunk/src


Ignore:
Timestamp:
06/29/09 12:00:27 (16 years ago)
Author:
Malte Marquarding
Message:

Fix enum problem with WeightType enum value already defined somewhere by adding W_ prefix. ALso removed enums which are no longer in use

Location:
trunk/src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/RowAccumulator.cpp

    r1414 r1569  
    6767  Float totalweight = weight;
    6868  MaskedArray<Float> data(v,m);
    69   if ( weightType_ == asap::VAR ) {
     69  if ( weightType_ == asap::W_VAR ) {
    7070    if (m.nelements() == userMask_.nelements()) {
    7171      Float fac = 1.0/variance(data(userMask_));
     
    9090  Float w = 1.0;
    9191  tsysSum_ += v[0];
    92   if ( weightType_ == asap::TSYS  || weightType_ == asap::TINTSYS ) {
     92  if ( weightType_ == asap::W_TSYS  || weightType_ == asap::W_TINTSYS ) {
    9393    w /= (v[0]*v[0]);
    9494  }
     
    105105  Float w = 1.0;
    106106  intervalSum_ += inter;
    107   if ( weightType_ == asap::TINT || weightType_ == asap::TINTSYS ) {
     107  if ( weightType_ == asap::W_TINT || weightType_ == asap::W_TINTSYS ) {
    108108    w /= Float(inter);
    109109  }
  • trunk/src/RowAccumulator.h

    r1398 r1569  
    3333   * Constructor taking a weight type as defined in @ref STDefs
    3434   */
    35   explicit RowAccumulator(WeightType wt = asap::NONE);
     35  explicit RowAccumulator(WeightType wt = asap::W_NONE);
    3636
    3737 ~RowAccumulator();
  • trunk/src/STDefs.h

    r1391 r1569  
    3434
    3535namespace asap {
    36   enum AxisNo { BeamAxis=0,
    37                 IFAxis,
    38                 PolAxis,
    39                 ChanAxis,
    40                 nAxes};
    4136
    4237  enum Instrument {UNKNOWNINST=0,
     
    5348  enum FeedPolType {UNKNOWNFEED, LINEAR, CIRCULAR, N_POL};
    5449
    55   enum WeightType {NONE=0, VAR, TSYS, TINT, TINTSYS, N_WEIGHTTYPES};
    56 
    57   enum TableType {MEMORY=0, PERSISTENT};
    58 
     50  enum WeightType {W_NONE=0, W_VAR, W_TSYS, W_TINT, W_TINTSYS, W_N_WEIGHTTYPES};
    5951
    6052
  • trunk/src/STMath.cpp

    r1505 r1569  
    4747#include "RowAccumulator.h"
    4848#include "STAttr.h"
     49#include "STSelector.h"
     50
    4951#include "STMath.h"
    50 #include "STSelector.h"
    51 
    5252using namespace casa;
    5353
     
    330330}
    331331
    332 CountedPtr<Scantable> STMath::binaryOperate(const CountedPtr<Scantable>& left, 
    333                                             const CountedPtr<Scantable>& right, 
     332CountedPtr<Scantable> STMath::binaryOperate(const CountedPtr<Scantable>& left,
     333                                            const CountedPtr<Scantable>& right,
    334334                                            const std::string& mode)
    335335{
     
    11761176  // initialize the lookup table if necessary
    11771177  if ( lookup.empty() ) {
    1178     lookup["NONE"]   = asap::NONE;
    1179     lookup["TINT"] = asap::TINT;
    1180     lookup["TINTSYS"]  = asap::TINTSYS;
    1181     lookup["TSYS"]  = asap::TSYS;
    1182     lookup["VAR"]  = asap::VAR;
     1178    lookup["NONE"]   = asap::W_NONE;
     1179    lookup["TINT"] = asap::W_TINT;
     1180    lookup["TINTSYS"]  = asap::W_TINTSYS;
     1181    lookup["TSYS"]  = asap::W_TSYS;
     1182    lookup["VAR"]  = asap::W_VAR;
    11831183  }
    11841184
     
    16201620  cols[3] = String("CYCLENO");
    16211621  TableIterator iter(tout, cols);
    1622   CountedPtr<STPol> stpol = STPol::getPolClass(out->factories_, 
     1622  CountedPtr<STPol> stpol = STPol::getPolClass(out->factories_,
    16231623                                               out->getPolType() );
    16241624  while (!iter.pastEnd()) {
Note: See TracChangeset for help on using the changeset viewer.