Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038 #include "SundanceDefs.hpp"
00039 #include "SundanceCellPredicateBase.hpp"
00040 #include "SundanceParametrizedCurve.hpp"
00041
00042 #ifndef SUNDANCECELLCURVEPREDICATE_H_
00043 #define SUNDANCECELLCURVEPREDICATE_H_
00044
00045 namespace Sundance
00046 {
00047
00048 class CellCurvePredicate : public CellPredicateBase {
00049 public:
00050
00051
00052 CellCurvePredicate(const ParametrizedCurve& curve ,CurveCellFilterMode filterMode)
00053 : CellPredicateBase(), curve_(curve) , filterMode_(filterMode)
00054 {;}
00055
00056 virtual ~CellCurvePredicate() {;}
00057
00058
00059 virtual void testBatch(const Array<int>& cellLID,
00060 Array<int>& results) const ;
00061
00062
00063 virtual XMLObject toXML() const ;
00064
00065
00066 virtual bool lessThan(const CellPredicateBase* other) const ;
00067
00068
00069 virtual std::string description() const {
00070 switch (filterMode_){
00071 case (Outside_Curve):
00072 return "CellCurvePredicate: Outside_Curve";
00073 case (Inside_Curve):
00074 return "CellCurvePredicate: Inside_Curve";
00075 case (On_Curve):
00076 return "CellCurvePredicate: On_Curve";
00077 }
00078 return "CellCurvePredicate: ";
00079 }
00080
00081
00082 GET_RCP(CellPredicateBase);
00083
00084 private:
00085
00086 ParametrizedCurve curve_;
00087
00088
00089 CurveCellFilterMode filterMode_;
00090 };
00091 }
00092 #endif