/************************************************************ * * Collection set * ************************************************************/ #ifndef COLLECTSET_H #define COLLECTSET_H #include "collectserver.h" #include "cnfgable.h" #include "mgsearch.h" #include "mgppsearch.h" #include "lucenesearch.h" class collectset : public configurable { protected: collectservermapclass cservers; mgsearchclass *mgsearch; mgppsearchclass *mgppsearch; lucenesearchclass *lucenesearch; int noofservers; text_t httpdomain; text_t httpprefix; public: collectset(text_t &gsdlhome); // this constructor is used by the local library collectset() {} ~collectset(); // initialise the collections bool init(ostream &logout); // configure all the servers as supplied void configure (const text_t &key, const text_tarray &cfgline); // Add/remove collections void add_all_collections (const text_t &gsdlhome); void remove_all_collections (); void remove_collection (const text_t &collection); void remove_collection (const text_t &collection, ostream& logout); void add_collection (const text_t &collection, const text_t &gsdlhome); void add_collection_group(const text_t& collection, const text_t& gsdlhome); void add_all_collection_groups (const text_t& gsdlhome); // return the total number of servers in the set int size(); void getCollectionList(text_tarray &collist); // return the component map collectservermapclass servers(); // return an individual collection server collectserver *getCollectServer(const text_t &collection) { return cservers.getcollectserver(collection); } }; #endif