Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / xsp / System / Web / UI / OrderedDictionaryStateHelper.cs / 1 / OrderedDictionaryStateHelper.cs
//// Copyright (c) Microsoft Corporation. All rights reserved. // //------------------------------------------------------------------------------ namespace System.Web.UI { using System; using System.Collections; using System.Collections.Specialized; using System.Runtime.Serialization; using System.Web.Util; internal static class OrderedDictionaryStateHelper { public static void LoadViewState(IOrderedDictionary dictionary, ArrayList state) { if (dictionary == null) { throw new ArgumentNullException("dictionary"); } if (state == null) { throw new ArgumentNullException("state"); } if (state != null) { for (int i = 0; i < state.Count; i++) { Pair pairEntry = (Pair)state[i]; dictionary.Add(pairEntry.First, pairEntry.Second); } } } public static ArrayList SaveViewState(IOrderedDictionary dictionary) { if (dictionary == null) { throw new ArgumentNullException("dictionary"); } ArrayList list = new ArrayList(dictionary.Count); foreach (DictionaryEntry entry in dictionary) { list.Add(new Pair(entry.Key, entry.Value)); } return list; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //// Copyright (c) Microsoft Corporation. All rights reserved. // //------------------------------------------------------------------------------ namespace System.Web.UI { using System; using System.Collections; using System.Collections.Specialized; using System.Runtime.Serialization; using System.Web.Util; internal static class OrderedDictionaryStateHelper { public static void LoadViewState(IOrderedDictionary dictionary, ArrayList state) { if (dictionary == null) { throw new ArgumentNullException("dictionary"); } if (state == null) { throw new ArgumentNullException("state"); } if (state != null) { for (int i = 0; i < state.Count; i++) { Pair pairEntry = (Pair)state[i]; dictionary.Add(pairEntry.First, pairEntry.Second); } } } public static ArrayList SaveViewState(IOrderedDictionary dictionary) { if (dictionary == null) { throw new ArgumentNullException("dictionary"); } ArrayList list = new ArrayList(dictionary.Count); foreach (DictionaryEntry entry in dictionary) { list.Add(new Pair(entry.Key, entry.Value)); } return list; } } } // 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
- ITextView.cs
- TypeSource.cs
- PrintPreviewControl.cs
- COM2ExtendedTypeConverter.cs
- HtmlGenericControl.cs
- GenericRootAutomationPeer.cs
- SerializableAttribute.cs
- COM2ExtendedTypeConverter.cs
- QilUnary.cs
- ResourceWriter.cs
- EntityDataSourceChangedEventArgs.cs
- ProgressBarBrushConverter.cs
- ForwardPositionQuery.cs
- BehaviorEditorPart.cs
- DataSourceView.cs
- BasicKeyConstraint.cs
- ScrollViewerAutomationPeer.cs
- FileDialogPermission.cs
- BrushProxy.cs
- Application.cs
- InvokeBase.cs
- MimeParameterWriter.cs
- SystemWebSectionGroup.cs
- Label.cs
- TableStyle.cs
- CustomAttributeBuilder.cs
- StylusTouchDevice.cs
- PageClientProxyGenerator.cs
- CharUnicodeInfo.cs
- SqlConnectionFactory.cs
- ServiceReference.cs
- SymLanguageType.cs
- Int16Animation.cs
- CatalogZoneDesigner.cs
- MouseGestureValueSerializer.cs
- ZipIOZip64EndOfCentralDirectoryBlock.cs
- SiteMapDataSourceView.cs
- XmlArrayItemAttribute.cs
- TextTreeTextNode.cs
- CallId.cs
- WhitespaceRule.cs
- Assembly.cs
- IdnElement.cs
- ComponentGlyph.cs
- JapaneseCalendar.cs
- NetMsmqBindingCollectionElement.cs
- DataConnectionHelper.cs
- TypedTableBase.cs
- _Rfc2616CacheValidators.cs
- HtmlInputCheckBox.cs
- InfocardInteractiveChannelInitializer.cs
- Table.cs
- ReceiveSecurityHeaderEntry.cs
- CngAlgorithmGroup.cs
- DataGridViewComboBoxCell.cs
- XmlNamespaceMappingCollection.cs
- SecureUICommand.cs
- DataGridColumnDropSeparator.cs
- SystemPens.cs
- Debugger.cs
- PathSegment.cs
- Stylus.cs
- DataViewManager.cs
- WorkflowServiceHost.cs
- AddInContractAttribute.cs
- ConfigXmlWhitespace.cs
- IISUnsafeMethods.cs
- MarshalDirectiveException.cs
- ClientUtils.cs
- DocumentPageViewAutomationPeer.cs
- OperationCanceledException.cs
- EdmScalarPropertyAttribute.cs
- HwndAppCommandInputProvider.cs
- JournalEntryListConverter.cs
- StringReader.cs
- MSAANativeProvider.cs
- UTF32Encoding.cs
- XMLUtil.cs
- TemplateInstanceAttribute.cs
- UTF8Encoding.cs
- Base64Decoder.cs
- CodeMemberProperty.cs
- GestureRecognitionResult.cs
- SignerInfo.cs
- WebPartExportVerb.cs
- UIElementParagraph.cs
- LineSegment.cs
- RelationalExpressions.cs
- Config.cs
- ConfigurationManagerHelper.cs
- StateItem.cs
- ThicknessConverter.cs
- KeyTime.cs
- StateRuntime.cs
- String.cs
- GridViewCancelEditEventArgs.cs
- SchemaCollectionCompiler.cs
- NamespaceDisplay.xaml.cs
- InputMethod.cs
- MatcherBuilder.cs