public static bool listedIdentifier(string identifier) { if (MaterialProperties.materials.Count < 1) { MaterialProperties.buildMaterialList(); } return(MaterialProperties.materials.ContainsKey(identifier)); }
public static MaterialProperties FromIdentifier(string identifier) { if (MaterialProperties.materials.Count < 1) { MaterialProperties.buildMaterialList(); } Scientrace.MaterialProperties retmat = MaterialProperties.getMaterial(identifier); if (retmat == null) { throw new ArgumentException("MaterialProperties Identifier \"" + identifier + "\" is unknown."); } return(retmat); }