public static void Config(XmlElement xmlElement, ref SecondaryBTreeDatabaseConfig secBtreeDBConfig, bool compulsory) { uint minKeysPerPage = new uint(); SecondaryDatabaseConfig secDBConfig = secBtreeDBConfig; SecondaryDatabaseConfigTest.Config(xmlElement, ref secDBConfig, compulsory); // Configure specific fields/properties of Btree db Configuration.ConfigCreatePolicy(xmlElement, "Creation", ref secBtreeDBConfig.Creation, compulsory); Configuration.ConfigDuplicatesPolicy(xmlElement, "Duplicates", ref secBtreeDBConfig.Duplicates, compulsory); if (Configuration.ConfigUint(xmlElement, "MinKeysPerPage", ref minKeysPerPage, compulsory)) { secBtreeDBConfig.MinKeysPerPage = minKeysPerPage; } Configuration.ConfigBool(xmlElement, "NoReverseSplitting", ref secBtreeDBConfig.NoReverseSplitting, compulsory); Configuration.ConfigBool(xmlElement, "UseRecordNumbers", ref secBtreeDBConfig.UseRecordNumbers, compulsory); }
public static void Config(XmlElement xmlElement, ref HashDatabaseConfig hashDBConfig, bool compulsory) { uint fillFactor = new uint(); uint numElements = new uint(); DatabaseConfig dbConfig = hashDBConfig; Config(xmlElement, ref dbConfig, compulsory); // Configure specific fields/properties of Hash db Configuration.ConfigCreatePolicy(xmlElement, "Creation", ref hashDBConfig.Creation, compulsory); Configuration.ConfigDuplicatesPolicy(xmlElement, "Duplicates", ref hashDBConfig.Duplicates, compulsory); if (Configuration.ConfigUint(xmlElement, "FillFactor", ref fillFactor, compulsory)) { hashDBConfig.FillFactor = fillFactor; } if (Configuration.ConfigUint(xmlElement, "NumElements", ref numElements, compulsory)) { hashDBConfig.TableSize = numElements; } }