50 for (
int i = 0; i < extent; ++i)
54 std::cout <<
"\t" << dir << std::endl;
64 for (
int i = 0; i < extent; ++i)
68 std::cout <<
"\t" << dir << std::endl;
78 for (
int i = 0; i < extent; ++i)
82 std::cout <<
"\t" << dir << std::endl;
96 for (
int i = 0; i < extent; ++i)
100 std::cout <<
"\t" << name << std::endl;
108 for (
int i = 0; i < extent; ++i)
112 std::cout <<
"\t" << name << std::endl;
120 for (
int i = 0; i < extent; ++i)
124 std::cout <<
"\t" << name << std::endl;
137 std::cerr <<
"Unable to create collections object." << std::endl;
142 char const * project;
146 std::cout <<
"Project : " << project << std::endl;
147 std::cout <<
"semVer : " << semVer << std::endl;
148 std::cout << std::endl;
157 <<
" env name : " << name << std::endl;
158 std::cout << std::endl;
166 <<
" env name : " << name << std::endl;
167 std::cout << std::endl;
175 <<
" env name : " << name << std::endl;
176 std::cout << std::endl;
184 std::cout <<
"config file env name : " << name << std::endl
185 <<
"config file env value: " << value << std::endl;
186 std::cout << std::endl;
191 char const * fileName;
193 std::cout <<
"config file name : " << fileName << std::endl;
194 std::cout << std::endl;
203 std::cout << std::endl;
212 std::cout << std::endl;
223 for (
int i = 0; i < extent; ++i)
227 std::cout <<
"\t" << name << std::endl;
234 for (
int i = 0; i < extent; ++i)
238 std::cout <<
"\t" << name << std::endl;
245 for (
int i = 0; i < extent; ++i)
249 std::cout <<
"\t" << name << std::endl;
254 char const * fileName;
259 "Sim_LAMMPS_LJcut_AkersonElliott_Alchemy_PbAu",
264 <<
"Simulator Model Sim_LAMMPS_LJcut_AkersonElliott_Alchemy_PbAu" 265 <<
" has library name '" << fileName <<
"' and is part of the '" 269 std::cout <<
"Error from GetItemLibraryFileNameAndCollection." 278 "Sim_LAMMPS_LJcut_AkersonElliott_Alchemy_PbAu",
281 std::cout <<
"Error from CacheListOfItemMetadataFiles." << std::endl;
284 char const * fileName;
285 unsigned int fileLength;
286 unsigned char const * fileRawData;
287 int availableAsString;
288 char const * fileString;
289 for (
int i = 0; i < extent; ++i)
298 std::cout <<
"Metadata File " << i <<
", " << fileName
299 <<
", is of length " << fileLength << std::endl
300 << fileString << std::endl;
KIM_Collection const KIM_COLLECTION_environmentVariable
The standard environmentVariable Collection.
void dirsForCollection(KIM_Collection const collection, KIM_Collections *const col)
int KIM_Collections_CacheListOfDirectoryNames(KIM_Collections *const collections, KIM_Collection const collection, KIM_CollectionItemType const itemType, int *const extent)
Cache a list of directory names where a specific KIM API collection stores library files for a specif...
int KIM_Collections_GetItemMetadataFile(KIM_Collections *const collections, int const index, char const **const fileName, unsigned int *const fileLength, unsigned char const **const fileRawData, int *const availableAsString, char const **const fileString)
Get the name and content of one of an item's metadata files.
int KIM_Collections_GetEnvironmentVariableName(KIM_Collections *const collections, KIM_CollectionItemType const itemType, char const **const name)
Get the names of environment variables that store configuration settings for the KIM::COLLECTION::env...
KIM_CollectionItemType const KIM_COLLECTION_ITEM_TYPE_simulatorModel
The standard simulatorModel CollectionItemType.
KIM_Collection const KIM_COLLECTION_system
The standard system Collection.
KIM_Collection const KIM_COLLECTION_currentWorkingDirectory
The standard currentWorkingDirectory Collection.
char const * KIM_Collection_ToString(KIM_Collection const collection)
Converts the object to a string.
int KIM_Collections_GetItemNameByType(KIM_Collections *const collections, int const index, char const **const itemName)
Get the name of an item from the cached list.
An Extensible Enumeration for the Collection's supported by the KIM API.
int KIM_Collections_CacheListOfItemMetadataFiles(KIM_Collections *const collections, KIM_CollectionItemType const itemType, char const *const itemName, int *const extent)
Cache a list of an item's metadata files.
int KIM_Collections_GetItemLibraryFileNameAndCollection(KIM_Collections *const collections, KIM_CollectionItemType const itemType, char const *const itemName, char const **const fileName, KIM_Collection *const collection)
Get the item's library file name and its KIM::Collection.
void KIM_Collections_GetConfigurationFileName(KIM_Collections *const collections, char const **const fileName)
Get the absolute file and path name of the KIM API user configuration file.
KIM_CollectionItemType const KIM_COLLECTION_ITEM_TYPE_portableModel
The standard portableModel CollectionItemType.
char const * KIM_CollectionItemType_ToString(KIM_CollectionItemType const collectionItemType)
Converts the object to a string.
KIM_Collection const KIM_COLLECTION_user
The standard user Collection.
int KIM_Collections_GetDirectoryName(KIM_Collections *const collections, int const index, char const **const directoryName)
Get the name of a directory from the cached list.
int KIM_Collections_CacheListOfItemNamesByType(KIM_Collections *const collections, KIM_CollectionItemType const itemType, int *const extent)
Cache a list of all item names of a specific type in the KIM API collections.
void KIM_Collections_GetProjectNameAndSemVer(KIM_Collections *const collections, char const **const projectName, char const **const semVer)
Get the KIM API project name and full Semantic Version string.
int KIM_Collections_CacheListOfItemNamesByCollectionAndType(KIM_Collections *const collections, KIM_Collection const collection, KIM_CollectionItemType const itemType, int *const extent)
Cache a list of all item names of a specific type in a specific collection.
void KIM_Collections_Destroy(KIM_Collections **const collections)
Destroy a previously Collections::Create'd object.
KIM_CollectionItemType const KIM_COLLECTION_ITEM_TYPE_modelDriver
The standard modelDriver CollectionItemType.
void KIM_Collections_GetConfigurationFileEnvironmentVariable(KIM_Collections *const collections, char const **const name, char const **const value)
Get the name and value of the environment variable that stores the name of the KIM API user configura...
void namesForCollection(KIM_Collection kc, KIM_Collections *const col)
struct KIM_Collections KIM_Collections
Provides the interface to the KIM API Collections and is meant to be used by simulators.
int KIM_Collections_Create(KIM_Collections **const collections)
Create a new KIM API Collections object.
int KIM_Collections_GetItemNameByCollectionAndType(KIM_Collections *const collections, int const index, char const **const itemName)
Get the name of an item from the cached list.