23 #ifndef SRC_CATALOG_CATALOGSTANDARDDATABASEMETADATA_H_
24 #define SRC_CATALOG_CATALOGSTANDARDDATABASEMETADATA_H_
47 string userCreatorIn,
string createdOnIn,
48 string lastModifiedIn);
53 void setValues(
string dbIdIn,
string dbNameIn,
string userCreatorIn,
54 string createdOnIn,
string lastModifiedIn);
60 void addNode(
string &nodeIn);
62 void addSet(
string &setIn);
64 void addSetToMap(
string &setName,
string &nodeIP);
66 void addNodeToMap(
string &nodeIP,
string &setName);
68 void addType(
string &typeIn);
70 void replaceListOfSets(vector<string> &newList);
72 void replaceListOfNodes(vector<string> &newList);
74 void replaceMapOfSets(map<
string, vector<string>> &newMap);
76 void replaceMapOfNodes(map<
string, vector<string>> &newMap);
83 void deleteSet(
string setName);
85 void removeNodeFromSet(
string node,
string set);
87 void deleteNodeFromMap(
string &nodeIP,
string &setName);
89 void deleteType(
string &typeIn);
91 vector<string> getListOfNodes();
93 vector<string> getListOfSets();
95 vector<string> getListOfTypes();
97 vector<CatalogStandardPermissionsMetadata> getListOfPermissions();
101 string getItemName();
105 string getUserCreator();
107 string getCreatedOn();
109 string getLastModified();
111 void setItemKey(
string &itemKeyIn);
113 void setItemId(
string &idIn);
115 void setItemName(
string &itemNameIn);
117 map<string, vector<string>> getSetsInDB();
119 map<string, vector<string>> getNodesInDB();
125 out <<
"\nCatalog Database Metadata" << endl;
126 out <<
"-------------------" << endl;
127 out <<
" DB Id: " << database.
getItemId().c_str() << endl;
128 out <<
" DB Key: " << database.
getItemKey().c_str() << endl;
129 out <<
" DB Name: " << database.
getItemName().c_str() << endl;
130 out <<
"\nThis Database is stored in the following nodes: " << endl;
134 out <<
"\nThis Database has the following sets: " << endl;
136 out <<
" Set: " << database.
getListOfSets()[i].c_str() << endl;
139 out <<
"-------------------\n" << endl;
175 void deleteSetFromSetList(
string &setName);
177 void deleteSetFromSetMap(
string &setName);
179 void deleteNodeFromSingleSet(
string &node,
string &setName);
181 void deleteSetFromSingleNode(
string &setName,
string &node);
183 void deleteSetFromNodeMap(
string &setName);