<reponame>Kagashino/pulumi-tctest<filename>sdk/dotnet/As/Schedule.cs// *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

using System;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.Threading.Tasks;
using Pulumi.Serialization;

namespace Pulumi.Tctest.As
{
    [TctestResourceType("tctest:As/schedule:Schedule")]
    public partial class Schedule : Pulumi.CustomResource
    {
        /// <summary>
        /// The desired number of CVM instances that should be running in the group.
        /// </summary>
        [Output("desiredCapacity")]
        public Output<int> DesiredCapacity { get; private set; } = null!;

        /// <summary>
        /// The time for this action to end, in "YYYY-MM-DDThh:mm:ss+08:00" format (UTC+8).
        /// </summary>
        [Output("endTime")]
        public Output<string?> EndTime { get; private set; } = null!;

        /// <summary>
        /// The maximum size for the Auto Scaling group.
        /// </summary>
        [Output("maxSize")]
        public Output<int> MaxSize { get; private set; } = null!;

        /// <summary>
        /// The minimum size for the Auto Scaling group.
        /// </summary>
        [Output("minSize")]
        public Output<int> MinSize { get; private set; } = null!;

        /// <summary>
        /// The time when recurring future actions will start. Start time is specified by the user following the Unix cron syntax
        /// format. And this argument should be set with end_time together.
        /// </summary>
        [Output("recurrence")]
        public Output<string?> Recurrence { get; private set; } = null!;

        /// <summary>
        /// ID of a scaling group.
        /// </summary>
        [Output("scalingGroupId")]
        public Output<string> ScalingGroupId { get; private set; } = null!;

        /// <summary>
        /// The name of this scaling action.
        /// </summary>
        [Output("scheduleActionName")]
        public Output<string> ScheduleActionName { get; private set; } = null!;

        /// <summary>
        /// The time for this action to start, in "YYYY-MM-DDThh:mm:ss+08:00" format (UTC+8).
        /// </summary>
        [Output("startTime")]
        public Output<string> StartTime { get; private set; } = null!;


        /// <summary>
        /// Create a Schedule resource with the given unique name, arguments, and options.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resource</param>
        /// <param name="args">The arguments used to populate this resource's properties</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public Schedule(string name, ScheduleArgs args, CustomResourceOptions? options = null)
            : base("tctest:As/schedule:Schedule", name, args ?? new ScheduleArgs(), MakeResourceOptions(options, ""))
        {
        }

        private Schedule(string name, Input<string> id, ScheduleState? state = null, CustomResourceOptions? options = null)
            : base("tctest:As/schedule:Schedule", name, state, MakeResourceOptions(options, id))
        {
        }

        private static CustomResourceOptions MakeResourceOptions(CustomResourceOptions? options, Input<string>? id)
        {
            var defaultOptions = new CustomResourceOptions
            {
                Version = Utilities.Version,
            };
            var merged = CustomResourceOptions.Merge(defaultOptions, options);
            // Override the ID if one was specified for consistency with other language SDKs.
            merged.Id = id ?? merged.Id;
            return merged;
        }
        /// <summary>
        /// Get an existing Schedule resource's state with the given name, ID, and optional extra
        /// properties used to qualify the lookup.
        /// </summary>
        ///
        /// <param name="name">The unique name of the resulting resource.</param>
        /// <param name="id">The unique provider ID of the resource to lookup.</param>
        /// <param name="state">Any extra arguments used during the lookup.</param>
        /// <param name="options">A bag of options that control this resource's behavior</param>
        public static Schedule Get(string name, Input<string> id, ScheduleState? state = null, CustomResourceOptions? options = null)
        {
            return new Schedule(name, id, state, options);
        }
    }

    public sealed class ScheduleArgs : Pulumi.ResourceArgs
    {
        /// <summary>
        /// The desired number of CVM instances that should be running in the group.
        /// </summary>
        [Input("desiredCapacity", required: true)]
        public Input<int> DesiredCapacity { get; set; } = null!;

        /// <summary>
        /// The time for this action to end, in "YYYY-MM-DDThh:mm:ss+08:00" format (UTC+8).
        /// </summary>
        [Input("endTime")]
        public Input<string>? EndTime { get; set; }

        /// <summary>
        /// The maximum size for the Auto Scaling group.
        /// </summary>
        [Input("maxSize", required: true)]
        public Input<int> MaxSize { get; set; } = null!;

        /// <summary>
        /// The minimum size for the Auto Scaling group.
        /// </summary>
        [Input("minSize", required: true)]
        public Input<int> MinSize { get; set; } = null!;

        /// <summary>
        /// The time when recurring future actions will start. Start time is specified by the user following the Unix cron syntax
        /// format. And this argument should be set with end_time together.
        /// </summary>
        [Input("recurrence")]
        public Input<string>? Recurrence { get; set; }

        /// <summary>
        /// ID of a scaling group.
        /// </summary>
        [Input("scalingGroupId", required: true)]
        public Input<string> ScalingGroupId { get; set; } = null!;

        /// <summary>
        /// The name of this scaling action.
        /// </summary>
        [Input("scheduleActionName", required: true)]
        public Input<string> ScheduleActionName { get; set; } = null!;

        /// <summary>
        /// The time for this action to start, in "YYYY-MM-DDThh:mm:ss+08:00" format (UTC+8).
        /// </summary>
        [Input("startTime", required: true)]
        public Input<string> StartTime { get; set; } = null!;

        public ScheduleArgs()
        {
        }
    }

    public sealed class ScheduleState : Pulumi.ResourceArgs
    {
        /// <summary>
        /// The desired number of CVM instances that should be running in the group.
        /// </summary>
        [Input("desiredCapacity")]
        public Input<int>? DesiredCapacity { get; set; }

        /// <summary>
        /// The time for this action to end, in "YYYY-MM-DDThh:mm:ss+08:00" format (UTC+8).
        /// </summary>
        [Input("endTime")]
        public Input<string>? EndTime { get; set; }

        /// <summary>
        /// The maximum size for the Auto Scaling group.
        /// </summary>
        [Input("maxSize")]
        public Input<int>? MaxSize { get; set; }

        /// <summary>
        /// The minimum size for the Auto Scaling group.
        /// </summary>
        [Input("minSize")]
        public Input<int>? MinSize { get; set; }

        /// <summary>
        /// The time when recurring future actions will start. Start time is specified by the user following the Unix cron syntax
        /// format. And this argument should be set with end_time together.
        /// </summary>
        [Input("recurrence")]
        public Input<string>? Recurrence { get; set; }

        /// <summary>
        /// ID of a scaling group.
        /// </summary>
        [Input("scalingGroupId")]
        public Input<string>? ScalingGroupId { get; set; }

        /// <summary>
        /// The name of this scaling action.
        /// </summary>
        [Input("scheduleActionName")]
        public Input<string>? ScheduleActionName { get; set; }

        /// <summary>
        /// The time for this action to start, in "YYYY-MM-DDThh:mm:ss+08:00" format (UTC+8).
        /// </summary>
        [Input("startTime")]
        public Input<string>? StartTime { get; set; }

        public ScheduleState()
        {
        }
    }
}
