Exemplo n.º 1
0
 public static Map CreateMap(MapTypesList TypeID)
 {
     switch (TypeID)
     {
         case MapTypesList.Bricks:		return new BricksMap();
         case MapTypesList.Clouds:		return new CloudsMap();
         case MapTypesList.Fibers:		return new FibersMap();
         case MapTypesList.Gradient:		return new GradientMap();
         case MapTypesList.Grid:			return new GridMap();
         case MapTypesList.Image:		return new ImageMap();
         case MapTypesList.Khaki:		return new KhakiMap();
         case MapTypesList.Noise:		return new NoiseMap();
         case MapTypesList.Single_Color:	return new SingleColorMap();
         case MapTypesList.Text:			return new TextMap();
         default:
             throw new ArgumentException("Unknown TypeID");
     }
 }
Exemplo n.º 2
0
 private string EnumName(MapTypesList Item)
 {
     return Item.ToString().Replace("_", " ");
 }