Ejemplo n.º 1
0
 private string GetObjectName(StructureValueCollection values, StringIDSource stringIDs)
 {
     if (values.HasString("name"))
     {
         return(values.GetString("name"));
     }
     if (values.HasInteger("name stringid"))
     {
         var sid = new StringID(values.GetInteger("name stringid"));
         return(stringIDs.GetString(sid));
     }
     throw new InvalidOperationException("Unable to determine the name of objects in the \"" + _layoutName + "\" layout");
 }