Esempio n. 1
0
 /// <summary>
 /// Initializes a new instance of the MediaJobError class.
 /// </summary>
 /// <param name="code">Error code describing the error. Possible values
 /// include: 'ServiceError', 'ServiceTransientError',
 /// 'DownloadNotAccessible', 'DownloadTransientError',
 /// 'UploadNotAccessible', 'UploadTransientError',
 /// 'ConfigurationUnsupported', 'ContentMalformed',
 /// 'ContentUnsupported'</param>
 /// <param name="message">A human-readable language-dependent
 /// representation of the error.</param>
 /// <param name="category">Helps with categorization of errors.
 /// Possible values include: 'Service', 'Download', 'Upload',
 /// 'Configuration', 'Content'</param>
 /// <param name="retry">Indicates that it may be possible to retry the
 /// Job. If retry is unsuccessful, please contact Azure support via
 /// Azure Portal. Possible values include: 'DoNotRetry',
 /// 'MayRetry'</param>
 /// <param name="details">An array of details about specific errors
 /// that led to this reported error.</param>
 public MediaJobError(MediaJobErrorCode code = default(MediaJobErrorCode), string message = default(string), MediaJobErrorCategory category = default(MediaJobErrorCategory), MediaJobRetry retry = default(MediaJobRetry), IList <MediaJobErrorDetail> details = default(IList <MediaJobErrorDetail>))
 {
     Code     = code;
     Message  = message;
     Category = category;
     Retry    = retry;
     Details  = details;
     CustomInit();
 }
        internal static string ToSerializedValue(this MediaJobErrorCategory value)
        {
            switch (value)
            {
            case MediaJobErrorCategory.Service:
                return("Service");

            case MediaJobErrorCategory.Download:
                return("Download");

            case MediaJobErrorCategory.Upload:
                return("Upload");

            case MediaJobErrorCategory.Configuration:
                return("Configuration");

            case MediaJobErrorCategory.Content:
                return("Content");
            }
            return(null);
        }
 public static string ToSerialString(this MediaJobErrorCategory value) => value switch
 {