public virtual object Clone() { return(new OAuthClient { ClientId = ClientId, ClientNames = ClientNames == null ? new List <OAuthTranslation>() : ClientNames.Select(c => (OAuthTranslation)c.Clone()).ToList(), ClientUris = ClientUris == null ? new List <OAuthTranslation>() : ClientUris.Select(c => (OAuthTranslation)c.Clone()).ToList(), LogoUris = LogoUris == null ? new List <OAuthTranslation>() : LogoUris.Select(c => (OAuthTranslation)c.Clone()).ToList(), PolicyUris = PolicyUris == null ? new List <OAuthTranslation>() : PolicyUris.Select(c => (OAuthTranslation)c.Clone()).ToList(), TosUris = TosUris == null ? new List <OAuthTranslation>() : TosUris.Select(c => (OAuthTranslation)c.Clone()).ToList(), CreateDateTime = CreateDateTime, JwksUri = JwksUri, RefreshTokenExpirationTimeInSeconds = RefreshTokenExpirationTimeInSeconds, UpdateDateTime = UpdateDateTime, TokenEndPointAuthMethod = TokenEndPointAuthMethod, TokenExpirationTimeInSeconds = TokenExpirationTimeInSeconds, Secrets = Secrets == null ? new List <ClientSecret>() : Secrets.Select(s => (ClientSecret)s.Clone()).ToList(), AllowedScopes = AllowedScopes == null ? new List <OAuthScope>() : AllowedScopes.Select(s => (OAuthScope)s.Clone()).ToList(), JsonWebKeys = JsonWebKeys == null ? new List <JsonWebKey>() : JsonWebKeys.Select(j => (JsonWebKey)j.Clone()).ToList(), GrantTypes = GrantTypes.ToList(), RedirectionUrls = RedirectionUrls.ToList(), PreferredTokenProfile = PreferredTokenProfile, TokenEncryptedResponseAlg = TokenEncryptedResponseAlg, TokenEncryptedResponseEnc = TokenEncryptedResponseEnc, TokenSignedResponseAlg = TokenSignedResponseAlg, ResponseTypes = ResponseTypes.ToList(), Contacts = Contacts.ToList(), SoftwareId = SoftwareId, SoftwareVersion = SoftwareVersion, PostLogoutRedirectUris = PostLogoutRedirectUris.ToList() }); }
public override object Clone() { return(new OpenIdClient { ClientId = ClientId, ClientNames = ClientNames == null ? new List <OAuthTranslation>() : ClientNames.Select(c => (OAuthTranslation)c.Clone()).ToList(), ClientUris = ClientUris == null ? new List <OAuthTranslation>() : ClientUris.Select(c => (OAuthTranslation)c.Clone()).ToList(), LogoUris = LogoUris == null ? new List <OAuthTranslation>() : LogoUris.Select(c => (OAuthTranslation)c.Clone()).ToList(), PolicyUris = PolicyUris == null ? new List <OAuthTranslation>() : PolicyUris.Select(c => (OAuthTranslation)c.Clone()).ToList(), TosUris = TosUris == null ? new List <OAuthTranslation>() : TosUris.Select(c => (OAuthTranslation)c.Clone()).ToList(), CreateDateTime = CreateDateTime, JwksUri = JwksUri, RefreshTokenExpirationTimeInSeconds = RefreshTokenExpirationTimeInSeconds, UpdateDateTime = UpdateDateTime, TokenEndPointAuthMethod = TokenEndPointAuthMethod, TokenExpirationTimeInSeconds = TokenExpirationTimeInSeconds, Secrets = Secrets == null ? new List <ClientSecret>() : Secrets.Select(s => (ClientSecret)s.Clone()).ToList(), AllowedScopes = AllowedScopes == null ? new List <OpenIdScope>() : AllowedScopes.Select(s => (OpenIdScope)s.Clone()).ToList(), JsonWebKeys = JsonWebKeys == null ? new List <JsonWebKey>() : JsonWebKeys.Select(j => (JsonWebKey)j.Clone()).ToList(), GrantTypes = GrantTypes.ToList(), RedirectionUrls = RedirectionUrls.ToList(), PreferredTokenProfile = PreferredTokenProfile, TokenEncryptedResponseAlg = TokenEncryptedResponseAlg, TokenEncryptedResponseEnc = TokenEncryptedResponseEnc, TokenSignedResponseAlg = TokenSignedResponseAlg, ResponseTypes = ResponseTypes.ToList(), Contacts = Contacts.ToList(), SoftwareId = SoftwareId, SoftwareVersion = SoftwareVersion, ApplicationType = ApplicationType, DefaultAcrValues = DefaultAcrValues.ToList(), DefaultMaxAge = DefaultMaxAge, IdTokenEncryptedResponseAlg = IdTokenEncryptedResponseAlg, IdTokenEncryptedResponseEnc = IdTokenEncryptedResponseEnc, IdTokenSignedResponseAlg = IdTokenSignedResponseAlg, PairWiseIdentifierSalt = PairWiseIdentifierSalt, RequestObjectEncryptionAlg = RequestObjectEncryptionAlg, RequestObjectEncryptionEnc = RequestObjectEncryptionEnc, RequestObjectSigningAlg = RequestObjectSigningAlg, RequireAuthTime = RequireAuthTime, SectorIdentifierUri = SectorIdentifierUri, SubjectType = SubjectType, UserInfoEncryptedResponseAlg = UserInfoEncryptedResponseAlg, UserInfoEncryptedResponseEnc = UserInfoEncryptedResponseEnc, UserInfoSignedResponseAlg = UserInfoSignedResponseAlg, RegistrationAccessToken = RegistrationAccessToken, PostLogoutRedirectUris = PostLogoutRedirectUris, InitiateLoginUri = InitiateLoginUri }); }