<commit_before>#region License

// Copyright (c) K2 Workflow (SourceCode Technology Holdings Inc.). All rights reserved.
// Licensed under the MIT License. See LICENSE file in the project root for full license information.

#endregion

using SourceCode.Clay.Collections.Generic;
using System;
using System.Collections.Generic;

namespace SourceCode.Clay.OpenApi
{
    /// <summary>
    /// Describes the operations available on a single path. A Path Item MAY be empty, due to ACL constraints.
    /// The path itself is still exposed to the documentation viewer but they will not know which operations
    /// and parameters are available.
    /// </summary>
    public class Path : IEquatable<Path>
    {
        #region Properties

        /// <summary>
        /// Gets the string summary intended to apply to all operations in this path.
        /// </summary>
        public string Summary { get; set; }

        /// <summary>
        /// Gets the string description intended to apply to all operations in this path.
        /// </summary>
        /// <remarks>
        /// CommonMark syntax MAY be used for rich text representation.
        /// </remarks>
        public string Description { get; set; }

        /// <summary>
        /// Gets the definition of a GET operation on this path.
        /// </summary>
        public Operation Get { get; set; }

        /// <summary>
        /// Gets the definition of a PUT operation on this path.
        /// </summary>
        public Operation Put { get; set; }

        /// <summary>
        /// Gets the definition of a POST operation on this path.
        /// </summary>
        public Operation Post { get; set; }

        /// <summary>
        /// Gets the definition of a DELETE operation on this path.
        /// </summary>
        public Operation Delete { get; set; }

        /// <summary>
        /// Gets the definition of a OPTIONS operation on this path.
        /// </summary>
        public Operation Options { get; set; }

        /// <summary>
        /// Gets the definition of a HEAD operation on this path.
        /// </summary>
        public Operation Head { get; set; }

        /// <summary>
        /// Gets the definition of a PATCH operation on this path.
        /// </summary>
        public Operation Patch { get; set; }

        /// <summary>
        /// Gets the definition of a TRACE operation on this path.
        /// </summary>
        public Operation Trace { get; set; }

        /// <summary>
        /// Gets the alternative server array to service all operations in this path.
        /// </summary>
        public IReadOnlyList<Server> Servers { get; }

        /// <summary>
        /// Gets the list of parameters that are applicable for all the operations described under this path.
        /// </summary>
        public IReadOnlyDictionary<ParameterKey, Referable<ParameterBody>> Parameters { get; }

        #endregion

        #region Constructors

        /// <summary>
        /// Creates a new instance of the <see cref="Path"/> class.
        /// </summary>
        /// <param name="summary">The string summary intended to apply to all operations in this path.</param>
        /// <param name="description">The string description intended to apply to all operations in this path.</param>
        /// <param name="get">The definition of a GET operation on this path.</param>
        /// <param name="put">The definition of a PUT operation on this path.</param>
        /// <param name="post">The definition of a POST operation on this path.</param>
        /// <param name="delete">The definition of a DELETE operation on this path.</param>
        /// <param name="options">The definition of a OPTIONS operation on this path.</param>
        /// <param name="head">The definition of a HEAD operation on this path.</param>
        /// <param name="patch">The definition of a PATCH operation on this path.</param>
        /// <param name="trace">The definition of a TRACE operation on this path.</param>
        /// <param name="servers">The alternative server list to service all operations in this path.</param>
        /// <param name="parameters">The list of parameters that are applicable for all the operations described under this path.</param><commit_msg>Open API Path is Immutable (#121)<commit_after>#region License

// Copyright (c) K2 Workflow (SourceCode Technology Holdings Inc.). All rights reserved.
// Licensed under the MIT License. See LICENSE file in the project root for full license information.

#endregion

using SourceCode.Clay.Collections.Generic;
using System;
using System.Collections.Generic;

namespace SourceCode.Clay.OpenApi
{
    /// <summary>
    /// Describes the operations available on a single path. A Path Item MAY be empty, due to ACL constraints.
    /// The path itself is still exposed to the documentation viewer but they will not know which operations
    /// and parameters are available.
    /// </summary>
    public class Path : IEquatable<Path>
    {
        #region Properties

        /// <summary>
        /// Gets the string summary intended to apply to all operations in this path.
        /// </summary>
        public string Summary { get; }

        /// <summary>
        /// Gets the string description intended to apply to all operations in this path.
        /// </summary>
        /// <remarks>
        /// CommonMark syntax MAY be used for rich text representation.
        /// </remarks>
        public string Description { get; }

        /// <summary>
        /// Gets the definition of a GET operation on this path.
        /// </summary>
        public Operation Get { get; }

        /// <summary>
        /// Gets the definition of a PUT operation on this path.
        /// </summary>
        public Operation Put { get; }

        /// <summary>
        /// Gets the definition of a POST operation on this path.
        /// </summary>
        public Operation Post { get; }

        /// <summary>
        /// Gets the definition of a DELETE operation on this path.
        /// </summary>
        public Operation Delete { get; }

        /// <summary>
        /// Gets the definition of a OPTIONS operation on this path.
        /// </summary>
        public Operation Options { get; }

        /// <summary>
        /// Gets the definition of a HEAD operation on this path.
        /// </summary>
        public Operation Head { get; }

        /// <summary>
        /// Gets the definition of a PATCH operation on this path.
        /// </summary>
        public Operation Patch { get; }

        /// <summary>
        /// Gets the definition of a TRACE operation on this path.
        /// </summary>
        public Operation Trace { get; }

        /// <summary>
        /// Gets the alternative server array to service all operations in this path.
        /// </summary>
        public IReadOnlyList<Server> Servers { get; }

        /// <summary>
        /// Gets the list of parameters that are applicable for all the operations described under this path.
        /// </summary>
        public IReadOnlyDictionary<ParameterKey, Referable<ParameterBody>> Parameters { get; }

        #endregion

        #region Constructors

        /// <summary>
        /// Creates a new instance of the <see cref="Path"/> class.
        /// </summary>
        /// <param name="summary">The string summary intended to apply to all operations in this path.</param>
        /// <param name="description">The string description intended to apply to all operations in this path.</param>
        /// <param name="get">The definition of a GET operation on this path.</param>
        /// <param name="put">The definition of a PUT operation on this path.</param>
        /// <param name="post">The definition of a POST operation on this path.</param>
        /// <param name="delete">The definition of a DELETE operation on this path.</param>
        /// <param name="options">The definition of a OPTIONS operation on this path.</param>
        /// <param name="head">The definition of a HEAD operation on this path.</param>
        /// <param name="patch">The definition of a PATCH operation on this path.</param>
        /// <param name="trace">The definition of a TRACE operation on this path.</param>
        /// <param name="servers">The alternative server list to service all operations in this path.</param>
        /// <param name="parameters">The list of parameters that are applicable for all the operations described under this path.</param>
{'fraction_non_alphanumeric': 0.11028893587033121, 'fraction_numerical': 0.0005872680291284943, 'mean_word_length': 2.0519713261648747, 'pattern_counts': {'":': 0, '<': 121, '<?xml version=': 0, '>': 121, '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': '652664', 'n_tokens_mistral': 2033, 'n_tokens_neox': 1990, 'n_words': 916}