Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / 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
- SafeFileHandle.cs
- InternalBase.cs
- _NtlmClient.cs
- IgnoreFileBuildProvider.cs
- Variable.cs
- Models.cs
- JsonByteArrayDataContract.cs
- FileLevelControlBuilderAttribute.cs
- SizeAnimation.cs
- FamilyTypeface.cs
- RegularExpressionValidator.cs
- DoubleLink.cs
- InputScopeConverter.cs
- JoinGraph.cs
- JsonCollectionDataContract.cs
- IdleTimeoutMonitor.cs
- JsonStringDataContract.cs
- SkinBuilder.cs
- QueryStatement.cs
- BinaryObjectReader.cs
- columnmapfactory.cs
- Section.cs
- GeneratedContractType.cs
- ContainsSearchOperator.cs
- XamlSerializationHelper.cs
- control.ime.cs
- SendKeys.cs
- AnnotationElement.cs
- FigureParaClient.cs
- IsolatedStorageFilePermission.cs
- XmlKeywords.cs
- NamespaceEmitter.cs
- TimelineCollection.cs
- KeyProperty.cs
- MemberRelationshipService.cs
- DataSet.cs
- AnimationTimeline.cs
- LayoutTable.cs
- MouseEventArgs.cs
- InstanceDataCollection.cs
- LinkGrep.cs
- DPTypeDescriptorContext.cs
- CachedPathData.cs
- WmlControlAdapter.cs
- _StreamFramer.cs
- FunctionNode.cs
- LazyTextWriterCreator.cs
- VersionedStream.cs
- DataContractSerializerSection.cs
- HandlerFactoryWrapper.cs
- RegexStringValidatorAttribute.cs
- DataBindingExpressionBuilder.cs
- ProviderBase.cs
- Lease.cs
- EndpointNameMessageFilter.cs
- GenericParameterDataContract.cs
- MSAANativeProvider.cs
- NativeMethods.cs
- MasterPage.cs
- FloaterParagraph.cs
- EndOfStreamException.cs
- ProcessInfo.cs
- BasicCellRelation.cs
- GeometryCollection.cs
- ObservableCollection.cs
- HttpWriter.cs
- baseaxisquery.cs
- WizardStepBase.cs
- AttributeUsageAttribute.cs
- QilCloneVisitor.cs
- NameValueFileSectionHandler.cs
- SimpleExpression.cs
- DataGridViewRowEventArgs.cs
- DateTimeParse.cs
- XmlSchemaGroup.cs
- ModelPerspective.cs
- ByteStreamGeometryContext.cs
- WinCategoryAttribute.cs
- HtmlLinkAdapter.cs
- StringComparer.cs
- EnumBuilder.cs
- MenuItemStyle.cs
- HttpStreamFormatter.cs
- SqlDataSourceStatusEventArgs.cs
- IPipelineRuntime.cs
- ToolStripSettings.cs
- SoapIgnoreAttribute.cs
- DynamicEntity.cs
- LocalizeDesigner.cs
- Rfc2898DeriveBytes.cs
- LockRecursionException.cs
- ReachSerializerAsync.cs
- SamlAction.cs
- HostingEnvironmentWrapper.cs
- RowVisual.cs
- DeviceContext.cs
- HtmlForm.cs
- FigureHelper.cs
- AspCompat.cs
- AutomationEvent.cs