X-Git-Url: http://git.treefish.org/~alex/phys/latlib.git/blobdiff_plain/d3e332b13eccd2fa7e467770f6d973b4f34904cf..40171a80594f79b137900fae122a2e33a3a88f95:/paraq.h?ds=inline diff --git a/paraq.h b/paraq.h index 9aaf1d0..ef4376b 100644 --- a/paraq.h +++ b/paraq.h @@ -11,13 +11,25 @@ class paraq { public: paraq(int nprocs, int rank); void addRange(const string& paraid, double min, double max, double step); - map* nextParas(); + int nextParas(); + double& operator[] (string paraid); + void addRange(const string& paraid, double range[3]) { addRange(paraid, range[0], range[1], range[2]); } + void addRange(const string& paraid, char *range); + void setDefault(const string& paraid, double value) { defaultPara[paraid] = value; } + int getTotalJobs(); + string rangeString(); private: int nprocs, rank; - int lastjob; - map< string, vector< double* > > paraMap; + int thisjob; + map defaultPara; + map< string, vector > paraMap; + map< string, vector > rangeMap; vector< map > jobList; + void initJobList(); + bool inParas(vector& paraVec, double& tofind); + double masterdefault; + bool jobListInitialized; }; #endif