Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / DEVDIV / depot / DevDiv / releases / whidbey / QFE / ndp / fx / src / xsp / System / Web / UI / WebControls / DataKeyCollection.cs / 1 / DataKeyCollection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls { using System; using System.Collections; using System.Security.Permissions; ////// [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class DataKeyCollection : ICollection { private ArrayList keys; ////// public DataKeyCollection(ArrayList keys) { this.keys = keys; } ///Initializes a new instance of the ///class. /// public int Count { get { return keys.Count; } } ///Gets the number of objects in the collection. This property is read-only. ////// public bool IsReadOnly { get { return false; } } ///Gets the value that specifies whether items in the ///can be /// modified. This property is read-only. /// public bool IsSynchronized { get { return false; } } ///Gets a value that indicates whether the ///is /// thread-safe. This property is read-only. /// public object SyncRoot { get { return this; } } ///Gets the object used to synchronize access to the collection. This property is read-only. ////// public object this[int index] { get { return keys[index]; } } ///Gets a ///at the specified index in the collection. This property is read-only. /// public void CopyTo(Array array, int index) { for (IEnumerator e = this.GetEnumerator(); e.MoveNext();) array.SetValue(e.Current, index++); } ///Copies the contents of the entire collection into an ///appending at /// the specified index of the . /// public IEnumerator GetEnumerator() { return keys.GetEnumerator(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------------------------ //Creates an enumerator for the ///used to iterate /// through the collection. // Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls { using System; using System.Collections; using System.Security.Permissions; ////// [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class DataKeyCollection : ICollection { private ArrayList keys; ////// public DataKeyCollection(ArrayList keys) { this.keys = keys; } ///Initializes a new instance of the ///class. /// public int Count { get { return keys.Count; } } ///Gets the number of objects in the collection. This property is read-only. ////// public bool IsReadOnly { get { return false; } } ///Gets the value that specifies whether items in the ///can be /// modified. This property is read-only. /// public bool IsSynchronized { get { return false; } } ///Gets a value that indicates whether the ///is /// thread-safe. This property is read-only. /// public object SyncRoot { get { return this; } } ///Gets the object used to synchronize access to the collection. This property is read-only. ////// public object this[int index] { get { return keys[index]; } } ///Gets a ///at the specified index in the collection. This property is read-only. /// public void CopyTo(Array array, int index) { for (IEnumerator e = this.GetEnumerator(); e.MoveNext();) array.SetValue(e.Current, index++); } ///Copies the contents of the entire collection into an ///appending at /// the specified index of the . /// public IEnumerator GetEnumerator() { return keys.GetEnumerator(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.Creates an enumerator for the ///used to iterate /// through the collection.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- SiteMapDataSourceView.cs
- XmlSchemaAny.cs
- WaitHandleCannotBeOpenedException.cs
- ZoneMembershipCondition.cs
- XmlSchemaExporter.cs
- ItemAutomationPeer.cs
- ConfigurationSectionGroupCollection.cs
- ReadOnlyDictionary.cs
- CipherData.cs
- TextAutomationPeer.cs
- StringKeyFrameCollection.cs
- DataGridTablesFactory.cs
- TrustLevel.cs
- CheckBoxStandardAdapter.cs
- TableLayout.cs
- peersecuritysettings.cs
- XmlSchemaRedefine.cs
- RenderTargetBitmap.cs
- SamlConditions.cs
- PropertyPath.cs
- DefaultTextStoreTextComposition.cs
- basecomparevalidator.cs
- XmlHierarchicalDataSourceView.cs
- XAMLParseException.cs
- SignatureToken.cs
- CubicEase.cs
- ReadOnlyKeyedCollection.cs
- ToolBarButton.cs
- EntityDataSourceStatementEditor.cs
- DotNetATv1WindowsLogEntryDeserializer.cs
- TextTrailingWordEllipsis.cs
- VisualBasic.cs
- InfoCardPolicy.cs
- CaseInsensitiveOrdinalStringComparer.cs
- PolyBezierSegmentFigureLogic.cs
- EndpointAddress.cs
- BuildManager.cs
- ConfigurationElementCollection.cs
- AutomationFocusChangedEventArgs.cs
- SessionParameter.cs
- GridItemProviderWrapper.cs
- CompressStream.cs
- XmlQueryCardinality.cs
- AdornerLayer.cs
- QuadraticBezierSegment.cs
- MaskedTextProvider.cs
- Missing.cs
- SQLSingleStorage.cs
- ListBase.cs
- SelectionItemProviderWrapper.cs
- OleDbCommand.cs
- Funcletizer.cs
- BooleanToSelectiveScrollingOrientationConverter.cs
- KeyInfo.cs
- BaseComponentEditor.cs
- StylusPointProperty.cs
- DesignerSelectionListAdapter.cs
- TagElement.cs
- XDeferredAxisSource.cs
- TrailingSpaceComparer.cs
- ViewStateException.cs
- Int32Animation.cs
- Viewport2DVisual3D.cs
- TextParagraphCache.cs
- AnnotationComponentChooser.cs
- AnonymousIdentificationSection.cs
- XmlFormatExtensionPrefixAttribute.cs
- VoiceInfo.cs
- RemotingConfiguration.cs
- ChangeInterceptorAttribute.cs
- NativeMethodsCLR.cs
- BitmapEffectGroup.cs
- ConnectionConsumerAttribute.cs
- Behavior.cs
- UrlPath.cs
- XLinq.cs
- DynamicObject.cs
- RefreshEventArgs.cs
- OracleDataAdapter.cs
- WindowsFormsHostAutomationPeer.cs
- ExtentCqlBlock.cs
- DataTableExtensions.cs
- Wizard.cs
- WindowsGraphics.cs
- SectionUpdates.cs
- Crc32.cs
- ComUdtElement.cs
- Stream.cs
- SignedInfo.cs
- SystemException.cs
- Annotation.cs
- LookupBindingPropertiesAttribute.cs
- LookupBindingPropertiesAttribute.cs
- CompressedStack.cs
- CharKeyFrameCollection.cs
- NativeCppClassAttribute.cs
- Utils.cs
- UITypeEditor.cs
- RequestStatusBarUpdateEventArgs.cs
- SmiRequestExecutor.cs