wanshenmean
2025-04-16 29f20b28392d212c04c0c40a512894f8622cfa53
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
using MoYu;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using WIDESEAWCS_Tasks.ConveyorLineJob.StationHandler;
 
namespace WIDESEAWCS_Tasks.ConveyorLineJob
{
    public class StationHandlerFactory
    {
        public static IStationHandler GetHandler(int stationType, CommonConveyorLineJob commonConveyorLineJob)
        {
            switch (stationType)
            {
                case 11:
                    return new EmptyTrayStationHandler(commonConveyorLineJob);
                case 5:
                    return new ExceptionPortStationHandler(commonConveyorLineJob);
                default:
                    throw new ArgumentException($"Unsupported station type: {stationType}");
            }
        }
    }
 
}