using CloudBuilder.Core.Authorization;
namespace CloudBuilder.Security
{
    [TypeScript]
    public class SecurityGroupPermissionDependentEntityKey
    {
        public string GroupName  { get; set; }
        public string PermissionName  { get; set; }
        public string DependentDetailName  { get; set; }

        public override bool Equals(object obj)
        {
            if (this == obj) return true;

            SecurityGroupPermissionDependentEntityKey pkey = obj as SecurityGroupPermissionDependentEntityKey;
            if (pkey == null) return false;

            if (GroupName != pkey.GroupName) return false;
            if (PermissionName != pkey.PermissionName) return false;
            if (DependentDetailName != pkey.DependentDetailName) return false;

            return true;
        }


            public override string ToString()
            {
                string declareSql="";
                declareSql=declareSql+$"declare @__tkey_GroupName_0 varchar(50) select @__tkey_GroupName_0 ='{GroupName}'; " ;                declareSql=declareSql+$"declare @__tkey_PermissionName_1 varchar(50) select @__tkey_PermissionName_1 ='{PermissionName}'; " ;                declareSql=declareSql+$"declare @__tkey_DependentDetailName_2 varchar(50) select @__tkey_DependentDetailName_2 ='{DependentDetailName}'; " ;
                return declareSql;
            }
        }
    }
    /* builder.Entity<SecurityGroupPermissionDependentEntity>().HasKey(c => new {        c.GroupName,        c.PermissionName,        c.DependentDetailName});    */
