//----------------------
// <auto-generated>
//     Generated using the NSwag toolchain v14.1.0.0 (NJsonSchema v11.0.2.0 (Newtonsoft.Json v13.0.0.0)) (http://NSwag.org)
// </auto-generated>
//----------------------


using StreamChat.Core.InternalDTO.Requests;
using StreamChat.Core.InternalDTO.Events;
using StreamChat.Core.InternalDTO.Models;

namespace StreamChat.Core.InternalDTO.Responses
{
    using System = global::System;

    [System.CodeDom.Compiler.GeneratedCode("NJsonSchema", "14.1.0.0 (NJsonSchema v11.0.2.0 (Newtonsoft.Json v13.0.0.0))")]

    internal readonly struct ChannelMemberResponseRoleInternalDTO : System.IEquatable<ChannelMemberResponseRoleInternalDTO>, StreamChat.Core.LowLevelClient.IEnumeratedStruct<ChannelMemberResponseRoleInternalDTO>
    {
        public string Value { get; }

        public static readonly ChannelMemberResponseRoleInternalDTO Member = new ChannelMemberResponseRoleInternalDTO("member");
        public static readonly ChannelMemberResponseRoleInternalDTO Moderator = new ChannelMemberResponseRoleInternalDTO("moderator");
        public static readonly ChannelMemberResponseRoleInternalDTO Admin = new ChannelMemberResponseRoleInternalDTO("admin");
        public static readonly ChannelMemberResponseRoleInternalDTO Owner = new ChannelMemberResponseRoleInternalDTO("owner");

        public ChannelMemberResponseRoleInternalDTO(string value)
        {
            Value = value;
        }

        public ChannelMemberResponseRoleInternalDTO Parse(string value) => new ChannelMemberResponseRoleInternalDTO(value);

        public override string ToString() => Value;

        public bool Equals(ChannelMemberResponseRoleInternalDTO other) => Value == other.Value;

        public override bool Equals(object obj) => obj is ChannelMemberResponseRoleInternalDTO other && Equals(other);

        public override int GetHashCode() => Value.GetHashCode();

        public static bool operator ==(ChannelMemberResponseRoleInternalDTO left, ChannelMemberResponseRoleInternalDTO right) => left.Equals(right);

        public static bool operator !=(ChannelMemberResponseRoleInternalDTO left, ChannelMemberResponseRoleInternalDTO right) => !left.Equals(right);

        public static implicit operator ChannelMemberResponseRoleInternalDTO(string value) => new ChannelMemberResponseRoleInternalDTO(value);

        public static implicit operator string(ChannelMemberResponseRoleInternalDTO type) => type.Value;
    }
}
