classdef (Hidden, Sealed) AWSBatch < parallel.settings.schedulerComponent.Generic
% AWSBatch - Scheduler Component for AWSBatch

%   Copyright 2023-2024 The MathWorks, Inc.

    methods (Hidden, Static) % Implementation of NamedNode Hidden, Static methods
        function obj = hBuildFromSettings(name, settingsNode, parentSettingsNode, varargin)
            obj = parallel.settings.schedulerComponent.AWSBatch(name, settingsNode, parentSettingsNode, varargin{:});
        end
    end

    methods (Access = private) % Constructor
        function obj = AWSBatch(name, node, parentNode, varargin)
            import parallel.internal.types.SchedulerType
            obj@parallel.settings.schedulerComponent.Generic(name, ...
                SchedulerType.AWSBatch, node, parentNode, varargin{:});

            % By default, use the shipping AWS Batch plugins
            if ~obj.isSet('PluginScriptsLocation')
                obj.PluginScriptsLocation = 'parallel.cluster.awsbatch';
            end

            % The default plugins only support Linux
            obj.OperatingSystem = 'unix';
        end
    end
end
