ServiceAuthenticationBehavior(ServiceAuthenticationBehavior other) { this.serviceAuthenticationManager = other.ServiceAuthenticationManager; this.authenticationSchemes = other.authenticationSchemes; this.isReadOnly = other.isReadOnly; this.isAuthenticationManagerSet = other.isAuthenticationManagerSet; this.isAuthenticationSchemesSet = other.isAuthenticationSchemesSet; }
protected internal override object CreateBehavior() { ServiceAuthenticationBehavior behavior = new ServiceAuthenticationBehavior(); string serviceAuthenticationManagerType = this.ServiceAuthenticationManagerType; if (!string.IsNullOrEmpty(serviceAuthenticationManagerType)) { Type c = Type.GetType(serviceAuthenticationManagerType, true); if (!typeof(ServiceAuthenticationManager).IsAssignableFrom(c)) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ConfigurationErrorsException(System.ServiceModel.SR.GetString("ConfigInvalidServiceAuthenticationManagerType", new object[] { serviceAuthenticationManagerType, typeof(ServiceAuthenticationManager) }))); } behavior.ServiceAuthenticationManager = (ServiceAuthenticationManager) Activator.CreateInstance(c); } return behavior; }
protected internal override object CreateBehavior() { ServiceAuthenticationBehavior behavior = new ServiceAuthenticationBehavior(); string serviceAuthenticationManagerType = this.ServiceAuthenticationManagerType; if (!String.IsNullOrEmpty(serviceAuthenticationManagerType)) { Type type = Type.GetType(serviceAuthenticationManagerType, true); if (!typeof(ServiceAuthenticationManager).IsAssignableFrom(type)) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new ConfigurationErrorsException( SR.GetString(SR.ConfigInvalidServiceAuthenticationManagerType, serviceAuthenticationManagerType, typeof(ServiceAuthenticationManager)))); } behavior.ServiceAuthenticationManager = (ServiceAuthenticationManager)Activator.CreateInstance(type); } if (this.AuthenticationSchemes != AuthenticationSchemes.None) { behavior.AuthenticationSchemes = this.AuthenticationSchemes; } return behavior; }
private ServiceAuthenticationBehavior(ServiceAuthenticationBehavior other) { this.serviceAuthenticationManager = other.ServiceAuthenticationManager; this.isReadOnly = other.isReadOnly; }