예제 #1
0
        public static LoadBase Create(LoadOptions info)
        {
            LoadBase load;

            switch (info.LoadType)
            {
            case LoadOptions.ELoadType.GCode:
                load = new LoadGCode();
                break;

            case LoadOptions.ELoadType.Hpgl:
                load = new LoadHpgl();
                break;

            case LoadOptions.ELoadType.Image:
                load = new LoadImage();
                break;

            case LoadOptions.ELoadType.ImageHole:
                load = new LoadImageHole();
                break;

            default: return(null);
            }

            load.LoadOptions = info;

            return(load);
        }
예제 #2
0
파일: LoadBase.cs 프로젝트: aiten/CNCLib
		static public LoadBase Create(LoadOptions info)
		{
			LoadBase load = null;
			switch (info.LoadType)
			{
				case LoadOptions.ELoadType.GCode: load = new LoadGCode(); break;
				case LoadOptions.ELoadType.HPGL: load = new LoadHPGL(); break;
				case LoadOptions.ELoadType.Image: load = new LoadImage(); break;
				case LoadOptions.ELoadType.ImageHole: load = new LoadImageHole(); break;
				default: return null;
			}
			load.LoadOptions = info;

			return load;
		}