Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / clr / src / BCL / System / Collections / Generic / KeyValuePair.cs / 1 / KeyValuePair.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================ ** ** Interface: KeyValuePair ** ** ** Purpose: Generic key-value pair for dictionary enumerators. ** ** ===========================================================*/ namespace System.Collections.Generic { using System; using System.Text; // A KeyValuePair holds a key and a value from a dictionary. // It is returned by IDictionaryEnumerator::GetEntry(). [Serializable()] public struct KeyValuePair{ private TKey key; private TValue value; public KeyValuePair(TKey key, TValue value) { this.key = key; this.value = value; } public TKey Key { get { return key; } } public TValue Value { get { return value; } } public override string ToString() { StringBuilder s = new StringBuilder(); s.Append('['); if( Key != null) { s.Append(Key.ToString()); } s.Append(", "); if( Value != null) { s.Append(Value.ToString()); } s.Append(']'); return s.ToString(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== /*============================================================ ** ** Interface: KeyValuePair ** ** ** Purpose: Generic key-value pair for dictionary enumerators. ** ** ===========================================================*/ namespace System.Collections.Generic { using System; using System.Text; // A KeyValuePair holds a key and a value from a dictionary. // It is returned by IDictionaryEnumerator::GetEntry(). [Serializable()] public struct KeyValuePair { private TKey key; private TValue value; public KeyValuePair(TKey key, TValue value) { this.key = key; this.value = value; } public TKey Key { get { return key; } } public TValue Value { get { return value; } } public override string ToString() { StringBuilder s = new StringBuilder(); s.Append('['); if( Key != null) { s.Append(Key.ToString()); } s.Append(", "); if( Value != null) { s.Append(Value.ToString()); } s.Append(']'); return s.ToString(); } } } // 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
- WriterOutput.cs
- Exception.cs
- Exceptions.cs
- BmpBitmapEncoder.cs
- CombinedGeometry.cs
- FormViewInsertEventArgs.cs
- basevalidator.cs
- ContainerControlDesigner.cs
- CollectionDataContract.cs
- ComponentFactoryHelpers.cs
- GreenMethods.cs
- NotifyIcon.cs
- NavigatorInput.cs
- XmlCollation.cs
- MetadataUtilsSmi.cs
- BitmapEffectState.cs
- GlyphRunDrawing.cs
- ApplicationException.cs
- SecuritySessionSecurityTokenProvider.cs
- XPathMultyIterator.cs
- DesignerTransaction.cs
- NeutralResourcesLanguageAttribute.cs
- DefaultEventAttribute.cs
- SystemResources.cs
- DataRow.cs
- _RequestCacheProtocol.cs
- _UncName.cs
- DirectoryObjectSecurity.cs
- ClientBuildManager.cs
- WorkflowApplicationCompletedException.cs
- SingleTagSectionHandler.cs
- Point3DAnimation.cs
- ExecutionEngineException.cs
- CellParaClient.cs
- DbConnectionPoolCounters.cs
- HijriCalendar.cs
- DiagnosticsElement.cs
- XmlQueryOutput.cs
- VariableQuery.cs
- MulticastDelegate.cs
- CompositeFontFamily.cs
- RadioButtonDesigner.cs
- PartialCachingAttribute.cs
- FixedFindEngine.cs
- WebPartEditorOkVerb.cs
- ServiceBusyException.cs
- metadatamappinghashervisitor.hashsourcebuilder.cs
- Matrix.cs
- ExpressionEditor.cs
- BitmapEffectDrawingContent.cs
- ModelService.cs
- XhtmlBasicValidatorAdapter.cs
- xml.cs
- HostProtectionPermission.cs
- TypeElement.cs
- Visitor.cs
- RunClient.cs
- DBSqlParserColumn.cs
- CompilerTypeWithParams.cs
- Content.cs
- StrongNameMembershipCondition.cs
- AdRotator.cs
- ListItem.cs
- ComplexPropertyEntry.cs
- CngKey.cs
- TemplateEditingFrame.cs
- LoggedException.cs
- DefaultTextStoreTextComposition.cs
- CustomLineCap.cs
- MouseButton.cs
- GlyphRun.cs
- BamlBinaryWriter.cs
- BuildProviderInstallComponent.cs
- CatalogZoneBase.cs
- ModelUIElement3D.cs
- TextFormatterImp.cs
- NameObjectCollectionBase.cs
- ClientConfigurationHost.cs
- GridViewAutomationPeer.cs
- TextSimpleMarkerProperties.cs
- DetailsViewDeleteEventArgs.cs
- Imaging.cs
- ProxyDataContractResolver.cs
- WebReferencesBuildProvider.cs
- TemplateControlParser.cs
- TemplateBamlTreeBuilder.cs
- ChangeBlockUndoRecord.cs
- ValidationPropertyAttribute.cs
- SafeArrayTypeMismatchException.cs
- DbConnectionStringBuilder.cs
- EntityTemplateFactory.cs
- SqlDataAdapter.cs
- Point3DKeyFrameCollection.cs
- OutOfProcStateClientManager.cs
- SerialReceived.cs
- TagPrefixAttribute.cs
- ReachDocumentSequenceSerializerAsync.cs
- XmlDesigner.cs
- TextDecorationLocationValidation.cs
- LogLogRecordEnumerator.cs