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
- Mappings.cs
- KeyValuePairs.cs
- WebServiceFaultDesigner.cs
- XmlCountingReader.cs
- GroupByExpressionRewriter.cs
- DesignerTransaction.cs
- ToolStripDropDown.cs
- SessionStateItemCollection.cs
- Certificate.cs
- HtmlTernaryTree.cs
- TypeLoadException.cs
- DtdParser.cs
- DataControlCommands.cs
- AutomationIdentifier.cs
- InvokeHandlers.cs
- EdmRelationshipRoleAttribute.cs
- BinHexDecoder.cs
- TemplatePropertyEntry.cs
- DataTransferEventArgs.cs
- ProfileManager.cs
- StylusButtonCollection.cs
- ReadOnlyCollectionBase.cs
- XPathMultyIterator.cs
- AllMembershipCondition.cs
- MeasurementDCInfo.cs
- TextDecorationCollectionConverter.cs
- SrgsGrammar.cs
- WebPartDisplayMode.cs
- DynamicActivityProperty.cs
- DbProviderConfigurationHandler.cs
- PropertyEmitterBase.cs
- Timer.cs
- FixedTextSelectionProcessor.cs
- Cursors.cs
- DataGridPagerStyle.cs
- Debug.cs
- SqlSupersetValidator.cs
- ResourceCategoryAttribute.cs
- PixelShader.cs
- TranslateTransform3D.cs
- Byte.cs
- DataGridViewRowsRemovedEventArgs.cs
- Update.cs
- WebContext.cs
- ProcessingInstructionAction.cs
- FunctionMappingTranslator.cs
- ProvideValueServiceProvider.cs
- EventHandlersDesigner.cs
- dbenumerator.cs
- MetadataUtilsSmi.cs
- Style.cs
- PrintPageEvent.cs
- ConfigXmlComment.cs
- UserControlAutomationPeer.cs
- Identity.cs
- BCryptSafeHandles.cs
- SQLInt16Storage.cs
- Clock.cs
- SecurityTokenInclusionMode.cs
- DynamicQueryableWrapper.cs
- SeekableReadStream.cs
- ServiceOperationWrapper.cs
- mansign.cs
- LoginView.cs
- XmlDataSourceView.cs
- SoapAttributeAttribute.cs
- M3DUtil.cs
- OracleConnectionFactory.cs
- DBSqlParserColumnCollection.cs
- ExtentKey.cs
- PackWebResponse.cs
- ObjectDataSource.cs
- DependencyObject.cs
- HostingEnvironment.cs
- IsolatedStorageFile.cs
- ScrollEventArgs.cs
- ElapsedEventArgs.cs
- NumberSubstitution.cs
- securitycriticaldataformultiplegetandset.cs
- XamlToRtfParser.cs
- GeneralTransform2DTo3DTo2D.cs
- Propagator.cs
- ByteArrayHelperWithString.cs
- CodeTypeDeclaration.cs
- SpnEndpointIdentityExtension.cs
- AsyncResult.cs
- TableCell.cs
- DetailsViewUpdateEventArgs.cs
- UnsafeNativeMethods.cs
- GroupBoxAutomationPeer.cs
- ButtonBaseAutomationPeer.cs
- CmsUtils.cs
- UrlMapping.cs
- GridView.cs
- ConfigXmlSignificantWhitespace.cs
- DefaultTraceListener.cs
- HtmlTernaryTree.cs
- XPathNodeInfoAtom.cs
- PolyBezierSegmentFigureLogic.cs
- AsyncParams.cs