/// <summary>
        /// カラム追加
        /// </summary>
        /// <param name="title">タイトル</param>
        /// <param name="text">テキスト</param>
        /// <param name="thumbnailImageUrl">サムネ画像URL</param>
        /// <param name="imageBackgroundColor">画像背景色</param>
        /// <param name="templateActionFactoryService">アクション作成クラス</param>
        /// <returns></returns>
        public TemplateImageCarouselColumnFactoryService AddColumn(
            string imageUri,
            TemplateActionFactoryService templateActionFactoryService
            )
        {
            Trace.TraceInformation("Start");

            if (!this.RegulateColumnArray())
            {
                Trace.TraceWarning("Regulate Column Array is False");
                Trace.TraceInformation("End");
                return(this);
            }

            ImageCarouselColumn column = new ImageCarouselColumn()
            {
                imageUrl = imageUri,
                action   = templateActionFactoryService.Actions[0]
            };

            this.Columns[this.Columns.Length - 1] = column;

            Trace.TraceInformation("End");

            return(this);
        }
        /// <summary>
        /// カラム追加
        /// </summary>
        /// <param name="title">タイトル</param>
        /// <param name="text">テキスト</param>
        /// <param name="thumbnailImageUrl">サムネ画像URL</param>
        /// <param name="imageBackgroundColor">画像背景色</param>
        /// <param name="templateActionFactoryService">アクション作成クラス</param>
        /// <returns></returns>
        public TemplateCarouselColumnFactoryService AddColumn(
            string title,
            string text,
            string thumbnailImageUrl,
            string imageBackgroundColor,
            TemplateActionFactoryService templateActionFactoryService
            )
        {
            Trace.TraceInformation("Start");

            if (!this.RegulateColumnArray())
            {
                Trace.TraceWarning("Regulate Column Array is False");
                Trace.TraceInformation("End");
                return(this);
            }

            CarouselColumn column = new CarouselColumn()
            {
                title                = title,
                text                 = text,
                thumbnailImageUrl    = thumbnailImageUrl,
                imageBackgroundColor = imageBackgroundColor,
                actions              = templateActionFactoryService.Actions
            };

            this.Columns[this.Columns.Length - 1] = column;

            Trace.TraceInformation("End");

            return(this);
        }
        /// <summary>
        /// 確認テンプレート追加
        /// </summary>
        /// <param name="text">テキスト</param>
        /// <param name="templateActionFactoryService">アクション作成用クラス</param>
        public MessageFactoryService AddConfirmTemplateMessage(
            string text,
            TemplateActionFactoryService templateActionFactoryService
            )
        {
            Trace.TraceInformation("Start");

            if (!this.RegulateMessageArray())
            {
                Trace.TraceWarning("Regulate Message Array is False");
                Trace.TraceInformation("End");
                return(this);
            }

            MessageBase templateMessage = new TemplateMessage()
            {
                altText  = text,
                template = new ConfirmTemplate()
                {
                    text    = text,
                    actions = templateActionFactoryService.Actions
                }
            };

            this.Messages[this.Messages.Length - 1] = templateMessage;

            Trace.TraceInformation("End");

            return(this);
        }
        /// <summary>
        /// アクション作成
        /// </summary>
        public static TemplateActionFactoryService CreateAction()
        {
            Trace.TraceInformation("Start");
            TemplateActionFactoryService templateActionFactoryService = new TemplateActionFactoryService();

            Trace.TraceInformation("End");
            return(templateActionFactoryService);
        }
        /// <summary>
        /// ボタンテンプレート追加
        /// </summary>
        /// <param name="altText">代替テキスト</param>
        /// <param name="thumbnailImageUrl">サムネ画像URL</param>
        /// <param name="imageBackgroundColor">画像背景色</param>
        /// <param name="title">タイトル</param>
        /// <param name="text">テキスト</param>
        /// <param name="templateActionFactoryService">アクション作成用クラス</param>
        /// <param name="isImageAspectSquare">アスペクト比を1:1にするかどうか</param>
        /// <param name="isImageSizeCover">余白を付けずに表示するかどうか</param>
        public MessageFactoryService AddButtonTemplateMessage(
            string altText,
            string thumbnailImageUrl,
            string imageBackgroundColor,
            string title,
            string text,
            TemplateActionFactoryService templateActionFactoryService,
            bool isImageAspectSquare = false,
            bool isImageSizeCover    = true
            )
        {
            Trace.TraceInformation("Start");

            if (!this.RegulateMessageArray())
            {
                Trace.TraceWarning("Regulate Message Array is False");
                Trace.TraceInformation("End");
                return(this);
            }

            MessageBase templateMessage = new TemplateMessage()
            {
                altText  = altText,
                template = new ButtonTemplate()
                {
                    thumbnailImageUrl    = thumbnailImageUrl,
                    imageAspectRatio     = isImageAspectSquare ? "square" : "rectangle",
                    imageSize            = isImageSizeCover ? "cover" : "contain",
                    imageBackgroundColor = imageBackgroundColor,
                    title   = title,
                    text    = text,
                    actions = templateActionFactoryService.Actions
                }
            };

            this.Messages[this.Messages.Length - 1] = templateMessage;

            Trace.TraceInformation("End");

            return(this);
        }