Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / WCF / IdentityModel / System / IdentityModel / Tokens / SecurityKeyType.cs / 1305376 / SecurityKeyType.cs
//------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- namespace System.IdentityModel.Tokens { using System.ComponentModel; using System.Diagnostics; public enum SecurityKeyType { SymmetricKey, AsymmetricKey, BearerKey } static class SecurityKeyTypeHelper { internal static bool IsDefined(SecurityKeyType value) { return (value == SecurityKeyType.SymmetricKey || value == SecurityKeyType.AsymmetricKey || value == SecurityKeyType.BearerKey); } internal static void Validate(SecurityKeyType value) { if (!IsDefined(value)) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidEnumArgumentException("value", (int)value, typeof(SecurityKeyType))); } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------- namespace System.IdentityModel.Tokens { using System.ComponentModel; using System.Diagnostics; public enum SecurityKeyType { SymmetricKey, AsymmetricKey, BearerKey } static class SecurityKeyTypeHelper { internal static bool IsDefined(SecurityKeyType value) { return (value == SecurityKeyType.SymmetricKey || value == SecurityKeyType.AsymmetricKey || value == SecurityKeyType.BearerKey); } internal static void Validate(SecurityKeyType value) { if (!IsDefined(value)) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidEnumArgumentException("value", (int)value, typeof(SecurityKeyType))); } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- AnnotationHighlightLayer.cs
- ResolvedKeyFrameEntry.cs
- SystemWebCachingSectionGroup.cs
- IdleTimeoutMonitor.cs
- AssemblyNameProxy.cs
- CompressionTracing.cs
- InputLangChangeEvent.cs
- TreeViewImageGenerator.cs
- RoleService.cs
- ValidationResult.cs
- FakeModelItemImpl.cs
- UIElementAutomationPeer.cs
- Version.cs
- InputBindingCollection.cs
- TypeConverterHelper.cs
- ExplicitDiscriminatorMap.cs
- BindingList.cs
- CodeEventReferenceExpression.cs
- Validator.cs
- TextTreePropertyUndoUnit.cs
- XmlArrayAttribute.cs
- LineBreakRecord.cs
- ApplicationSecurityManager.cs
- CultureMapper.cs
- InkCanvasSelection.cs
- FamilyMap.cs
- ThicknessAnimationBase.cs
- Point.cs
- DbCommandDefinition.cs
- TextSerializer.cs
- DownloadProgressEventArgs.cs
- Operators.cs
- GridViewUpdateEventArgs.cs
- FocusChangedEventArgs.cs
- JavaScriptObjectDeserializer.cs
- ConsoleKeyInfo.cs
- ConstructorArgumentAttribute.cs
- SqlClientWrapperSmiStream.cs
- List.cs
- ObjectHelper.cs
- WebBrowserContainer.cs
- Decoder.cs
- xdrvalidator.cs
- ArraySubsetEnumerator.cs
- ExpressionServices.cs
- DefaultProxySection.cs
- Table.cs
- PreProcessInputEventArgs.cs
- ProviderCollection.cs
- Compilation.cs
- BuilderInfo.cs
- BufferBuilder.cs
- DockAndAnchorLayout.cs
- RegexNode.cs
- TypedTableGenerator.cs
- RowUpdatedEventArgs.cs
- OdbcCommand.cs
- SqlInternalConnectionSmi.cs
- KernelTypeValidation.cs
- GlobalizationAssembly.cs
- RemotingSurrogateSelector.cs
- BevelBitmapEffect.cs
- NamespaceInfo.cs
- DataBindingValueUIHandler.cs
- MemberAssignment.cs
- MetadataProperty.cs
- ParameterExpression.cs
- ConstraintConverter.cs
- PagesSection.cs
- MailAddressCollection.cs
- PointKeyFrameCollection.cs
- AnimationLayer.cs
- SecurityResources.cs
- MailMessageEventArgs.cs
- DateTimeStorage.cs
- CleanUpVirtualizedItemEventArgs.cs
- CreateUserWizardAutoFormat.cs
- DataGridColumnReorderingEventArgs.cs
- TrustLevel.cs
- EncoderReplacementFallback.cs
- SafeMILHandle.cs
- FaultImportOptions.cs
- StrongName.cs
- FillErrorEventArgs.cs
- CreateDataSourceDialog.cs
- IndentedWriter.cs
- GlobalItem.cs
- HostProtectionException.cs
- Char.cs
- translator.cs
- WebServiceReceiveDesigner.cs
- FrameworkPropertyMetadata.cs
- Predicate.cs
- AnnotationResourceChangedEventArgs.cs
- SoapAttributeOverrides.cs
- UTF7Encoding.cs
- ParsedAttributeCollection.cs
- x509store.cs
- CacheAxisQuery.cs
- ImageConverter.cs