public MeshSurfacesData(Table table) { surface_EMISSION = bictionnary[table["surface_EMISSION"].IntValue]; surfaces = new List <Surface>(); int i = 1; while (table["Surface_" + i].Count > 0) { surfaces.Add(new Surface(i, table["Surface_" + i])); i++; } }
public static dynamic GetTSObject(SurfaceTypeEnum dynEnum) { var tsType = TSActivator.CreateInstance("Tekla.Structures.Model.SurfaceTreatment.SurfaceTypeEnum").GetType(); switch (dynEnum) { case SurfaceTypeEnum.CONCRETE_FINISH: return(System.Enum.Parse(tsType, "CONCRETE_FINISH")); case SurfaceTypeEnum.SPECIAL_MIX: return(System.Enum.Parse(tsType, "SPECIAL_MIX")); case SurfaceTypeEnum.TILE_SURFACE: return(System.Enum.Parse(tsType, "TILE_SURFACE")); case SurfaceTypeEnum.STEEL_FINISH: return(System.Enum.Parse(tsType, "STEEL_FINISH")); default: throw new DynamicAPIException(dynEnum.ToString() + "- enum value is not implemented"); } }