<commit_before>﻿namespace King.Azure.BackgroundWorker.Data.Model
{
    using Microsoft.WindowsAzure.Storage.Table;
    using System;

    /// <summary>
    /// Scheduled Task Entry
    /// </summary>
    public class ScheduledTaskEntry : TableEntity
    {
        #region Constructor
        /// <summary>
        /// Default Constructpor
        /// </summary>
        public ScheduledTaskEntry()
        {
        }
        
        public ScheduledTaskEntry(Type service)
            :this(service.ToString())
        {
        }

        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="serviceName">Service Name</param>
        public ScheduledTaskEntry(string serviceName)
        {
            if (string.IsNullOrWhiteSpace(serviceName))
            {
                throw new ArgumentException("serviceName");
            }

            this.ServiceName = serviceName;
            this.PartitionKey = ScheduledTaskEntry.GenerateLogsPartitionKey(serviceName);
        }
        #endregion

        #region Properties
        /// <summary>
        /// Gets and sets Identifier
        /// </summary>
        public Guid? Identifier
        {
            get
            {
                return string.IsNullOrEmpty(this.RowKey) ? (Guid?)null : Guid.Parse(this.RowKey);
            }
            set
            {
                this.RowKey = null == value ? null : value.ToString();
            }
        }

        /// <summary>
        /// Gets and sets Start Time
        /// </summary>
        public DateTime StartTime
        {
            get;
            set;
        }

        /// <summary>
        /// Gets and sets Completion Time
        /// </summary>
        public DateTime? CompletionTime
        {
            get;
            set;
        }

        /// <summary>
        /// Gets and sets the Service Name
        /// </summary>
        public string ServiceName
        {
            get;
            set;
        }

        /// <summary>
        /// Gets and sets Successful
        /// </summary>
        public bool Successful
        {
            get;
            set;
        }
        #endregion

        #region Methods
        /// <summary>
        /// Generate the partition key
        /// Format: {type}-{year}-{month}
        /// </summary>
        /// <param name="type">Backup data type</param>
        /// <returns>Partition key</returns>
        public static string GenerateLogsPartitionKey(string serviceName)
        {
            return string.Format("{0}-{1:yyyy}-{1:MM}", serviceName, DateTime.UtcNow);
        }
        #endregion
    }
}<commit_msg>less comments<commit_after>﻿namespace King.Azure.BackgroundWorker.Data.Model
{
    using Microsoft.WindowsAzure.Storage.Table;
    using System;

    /// <summary>
    /// Scheduled Task Entry
    /// </summary>
    public class ScheduledTaskEntry : TableEntity
    {
        #region Constructor
        /// <summary>
        /// Default Constructpor
        /// </summary>
        public ScheduledTaskEntry()
        {
        }
        
        public ScheduledTaskEntry(Type service)
            :this(service.ToString())
        {
        }

        /// <summary>
        /// Constructor
        /// </summary>
        /// <param name="serviceName">Service Name</param>
        public ScheduledTaskEntry(string serviceName)
        {
            if (string.IsNullOrWhiteSpace(serviceName))
            {
                throw new ArgumentException("serviceName");
            }

            this.ServiceName = serviceName;
            this.PartitionKey = ScheduledTaskEntry.GenerateLogsPartitionKey(serviceName);
        }
        #endregion

        #region Properties
        /// <summary>
        /// Identifier
        /// </summary>
        public Guid? Identifier
        {
            get
            {
                return string.IsNullOrEmpty(this.RowKey) ? (Guid?)null : Guid.Parse(this.RowKey);
            }
            set
            {
                this.RowKey = null == value ? null : value.ToString();
            }
        }

        /// <summary>
        /// Start Time
        /// </summary>
        public DateTime StartTime
        {
            get;
            set;
        }

        /// <summary>
        /// Completion Time
        /// </summary>
        public DateTime? CompletionTime
        {
            get;
            set;
        }

        /// <summary>
        /// the Service Name
        /// </summary>
        public string ServiceName
        {
            get;
            set;
        }

        /// <summary>
        /// Successful
        /// </summary>
        public bool Successful
        {
            get;
            set;
        }
        #endregion

        #region Methods
        /// <summary>
        /// Generate the partition key
        /// Format: {type}-{year}-{month}
        /// </summary>
        /// <param name="type">Backup data type</param>
        /// <returns>Partition key</returns>
        public static string GenerateLogsPartitionKey(string serviceName)
        {
            return string.Format("{0}-{1:yyyy}-{1:MM}", serviceName, DateTime.UtcNow);
        }
        #endregion
    }
}
{'fraction_non_alphanumeric': 0.11588641596316193, 'fraction_numerical': 0.0011511895625479663, 'mean_word_length': 1.226826142674071, 'pattern_counts': {'":': 0, '<': 51, '<?xml version=': 0, '>': 51, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3313411', 'n_tokens_mistral': 1311, 'n_tokens_neox': 1289, 'n_words': 272}