00001 /* 00002 * Copyright (c) 2004 on behalf of the EU EGEE Project: 00003 * The European Organization for Nuclear Research (CERN), 00004 * Istituto Nazionale di Fisica Nucleare (INFN), Italy 00005 * Datamat Spa, Italy 00006 * Centre National de la Recherche Scientifique (CNRS), France 00007 * CS Systeme d'Information (CSSI), France 00008 * Royal Institute of Technology, Center for Parallel Computers (KTH-PDC), Sweden 00009 * Universiteit van Amsterdam (UvA), Netherlands 00010 * University of Helsinki (UH.HIP), Finland 00011 * University of Bergen (UiB), Norway 00012 * Council for the Central Laboratory of the Research Councils (CCLRC), United Kingdom 00013 */ 00014 #ifndef QueryProperties_H 00015 #define QueryProperties_H 00016 00017 #include "rgma/TimeInterval.h" 00018 00019 namespace glite 00020 { 00021 namespace rgma 00022 { 00048 class QueryProperties 00049 { 00050 private: 00051 const static int C = 1; 00052 const static int L = 2; 00053 const static int H = 4; 00054 const static int S = 8; 00055 TimeInterval m_timeInterval; 00056 int m_query; 00057 bool m_hasTimeInterval; 00058 public: 00060 const static QueryProperties CONTINUOUS; 00061 00063 const static QueryProperties LATEST; 00064 00066 const static QueryProperties HISTORY; 00067 00069 const static QueryProperties STATIC; 00070 00071 virtual ~QueryProperties(); 00072 00073 QueryProperties( const QueryProperties& properties ); 00074 QueryProperties& operator=(const QueryProperties& properties ); 00075 00083 const static QueryProperties getContinuous(TimeInterval timeInterval); 00091 const static QueryProperties getHistory(TimeInterval timeInterval); 00092 00100 const static QueryProperties getLatest(TimeInterval timeInterval); 00101 00109 const static QueryProperties getStatic(TimeInterval timeInterval); 00110 00116 bool isContinuous(); 00117 00123 bool isHistory(); 00124 00130 bool isLatest(); 00131 00137 bool isStatic(); 00138 00145 TimeInterval getTimeInterval(); 00146 00154 bool equals(QueryProperties qt); 00155 00161 bool hasTimeInterval(); 00162 00163 protected: 00169 QueryProperties(int query); 00170 00178 QueryProperties(int query, TimeInterval timeInterval); 00184 int getQuery(); 00185 00186 }; 00187 } 00188 } 00189 #endif // QueryProperties_H