Code:
/ WCF / WCF / 3.5.30729.1 / untmp / Orcas / SP / ndp / cdf / src / WCF / ServiceModel / System / ServiceModel / Security / KeyNameIdentifierClause.cs / 1 / KeyNameIdentifierClause.cs
//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------------------------- namespace System.ServiceModel.Security { using System.Globalization; using System.ServiceModel; using System.IdentityModel.Tokens; public class KeyNameIdentifierClause : SecurityKeyIdentifierClause { string keyName; public KeyNameIdentifierClause(string keyName) : base(null) { if (keyName == null) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperArgumentNull("keyName"); } this.keyName = keyName; } public string KeyName { get { return this.keyName; } } public override bool Matches(SecurityKeyIdentifierClause keyIdentifierClause) { KeyNameIdentifierClause that = keyIdentifierClause as KeyNameIdentifierClause; // PreSharp Bug: Parameter 'that' to this public method must be validated: A null-dereference can occur here. #pragma warning suppress 56506 return ReferenceEquals(this, that) || (that != null && that.Matches(this.keyName)); } public bool Matches(string keyName) { return this.keyName == keyName; } public override string ToString() { return string.Format(CultureInfo.InvariantCulture, "KeyNameIdentifierClause(KeyName = '{0}')", this.KeyName); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- SingleResultAttribute.cs
- ArcSegment.cs
- PeerChannelListener.cs
- ButtonRenderer.cs
- SqlTopReducer.cs
- SafeNativeMethods.cs
- ShutDownListener.cs
- BitmapImage.cs
- XmlSchemaObject.cs
- GeometryCollection.cs
- LineBreak.cs
- Timer.cs
- ChainOfResponsibility.cs
- PtsHost.cs
- Part.cs
- Constraint.cs
- InternalBase.cs
- ToolStripPanelRow.cs
- SoapReflectionImporter.cs
- CharKeyFrameCollection.cs
- MenuBindingsEditor.cs
- StylusPointProperties.cs
- XmlHierarchyData.cs
- Geometry.cs
- ContentTextAutomationPeer.cs
- _DomainName.cs
- HelpProvider.cs
- BrowserCapabilitiesCompiler.cs
- ConfigXmlWhitespace.cs
- PKCS1MaskGenerationMethod.cs
- ExtenderHelpers.cs
- ResXBuildProvider.cs
- ControlCachePolicy.cs
- ComboBoxAutomationPeer.cs
- IncomingWebResponseContext.cs
- AxDesigner.cs
- EdmTypeAttribute.cs
- BitmapMetadataBlob.cs
- AuthenticatedStream.cs
- Validator.cs
- Converter.cs
- InputScopeAttribute.cs
- XmlIgnoreAttribute.cs
- DynamicMethod.cs
- SkewTransform.cs
- WsatTransactionHeader.cs
- KeyConstraint.cs
- APCustomTypeDescriptor.cs
- BaseAddressElementCollection.cs
- SeekStoryboard.cs
- SiteMapNodeItemEventArgs.cs
- ScriptReference.cs
- InvalidDataException.cs
- DataContractJsonSerializerOperationBehavior.cs
- Soap12ProtocolReflector.cs
- ZipPackage.cs
- GlyphRun.cs
- QuaternionAnimation.cs
- RectIndependentAnimationStorage.cs
- DynamicDocumentPaginator.cs
- SpecialNameAttribute.cs
- _HeaderInfoTable.cs
- AssemblySettingAttributes.cs
- ScriptingJsonSerializationSection.cs
- HtmlToClrEventProxy.cs
- FixedBufferAttribute.cs
- Cursor.cs
- PartitionResolver.cs
- RowCache.cs
- ActivationArguments.cs
- LicenseProviderAttribute.cs
- NamespaceCollection.cs
- UtilityExtension.cs
- PropertyPushdownHelper.cs
- Matrix.cs
- RegexCompiler.cs
- ToolTipService.cs
- RankException.cs
- FilterableAttribute.cs
- MenuItemCollection.cs
- XPathNavigator.cs
- Transform3DCollection.cs
- SettingsAttributes.cs
- PointIndependentAnimationStorage.cs
- CollectionViewGroup.cs
- EdmFunctions.cs
- CaseInsensitiveOrdinalStringComparer.cs
- MembershipValidatePasswordEventArgs.cs
- UserControl.cs
- KeyTime.cs
- XsltCompileContext.cs
- XmlNodeChangedEventArgs.cs
- InfoCardKeyedHashAlgorithm.cs
- ImageCodecInfoPrivate.cs
- SessionStateUtil.cs
- NamedPermissionSet.cs
- ListControl.cs
- CqlParserHelpers.cs
- StorageTypeMapping.cs
- MiniMapControl.xaml.cs