Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / UI / WebControls / DetailsViewRowCollection.cs / 1305376 / DetailsViewRowCollection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls { using System; using System.Collections; ////// public class DetailsViewRowCollection : ICollection { private ArrayList _rows; ///Represents the collection of ///objects. /// public DetailsViewRowCollection(ArrayList rows) { this._rows = rows; } ///Initializes a new instance of the ///class. /// public int Count { get { return _rows.Count; } } ///Gets the number of rows in the collection. This property is read-only. ////// public bool IsReadOnly { get { return false; } } ///Gets a value that specifies whether rows 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 DetailsViewRow this[int index] { get { return(DetailsViewRow)_rows[index]; } } ///Gets a ///at the specified index in the /// collection. /// public void CopyTo(DetailsViewRow[] array, int index) { ((ICollection)this).CopyTo(array, index); } ///Copies the contents of the entire collection into an ///appending /// at the specified index of the . void ICollection.CopyTo(Array array, int index) { for (IEnumerator e = this.GetEnumerator(); e.MoveNext();) array.SetValue(e.Current, index++); } /// /// public IEnumerator GetEnumerator() { return _rows.GetEnumerator(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //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; ////// public class DetailsViewRowCollection : ICollection { private ArrayList _rows; ///Represents the collection of ///objects. /// public DetailsViewRowCollection(ArrayList rows) { this._rows = rows; } ///Initializes a new instance of the ///class. /// public int Count { get { return _rows.Count; } } ///Gets the number of rows in the collection. This property is read-only. ////// public bool IsReadOnly { get { return false; } } ///Gets a value that specifies whether rows 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 DetailsViewRow this[int index] { get { return(DetailsViewRow)_rows[index]; } } ///Gets a ///at the specified index in the /// collection. /// public void CopyTo(DetailsViewRow[] array, int index) { ((ICollection)this).CopyTo(array, index); } ///Copies the contents of the entire collection into an ///appending /// at the specified index of the . void ICollection.CopyTo(Array array, int index) { for (IEnumerator e = this.GetEnumerator(); e.MoveNext();) array.SetValue(e.Current, index++); } /// /// public IEnumerator GetEnumerator() { return _rows.GetEnumerator(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.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
- NotifyParentPropertyAttribute.cs
- ProcessHostConfigUtils.cs
- BadImageFormatException.cs
- ApplicationInfo.cs
- LogicalTreeHelper.cs
- ToolStripProgressBar.cs
- DataGridRowHeader.cs
- CodeCommentStatement.cs
- MethodCallConverter.cs
- DocumentSequence.cs
- SafeNativeMethods.cs
- SliderAutomationPeer.cs
- OracleBinary.cs
- CheckBoxFlatAdapter.cs
- ChangeNode.cs
- Trigger.cs
- PolicyReader.cs
- PathFigure.cs
- MissingSatelliteAssemblyException.cs
- CompilerError.cs
- TypeElementCollection.cs
- InputMethodStateChangeEventArgs.cs
- RepeaterItem.cs
- LazyLoadBehavior.cs
- AttachedPropertyInfo.cs
- SoapTypeAttribute.cs
- XsltArgumentList.cs
- SiteMap.cs
- BorderGapMaskConverter.cs
- MsmqElementBase.cs
- Baml2006ReaderSettings.cs
- XmlWhitespace.cs
- ObservableCollectionDefaultValueFactory.cs
- SHA512Managed.cs
- WindowsSysHeader.cs
- XmlElementCollection.cs
- COM2IVsPerPropertyBrowsingHandler.cs
- SiteMapNodeItem.cs
- MultipleViewPattern.cs
- ClickablePoint.cs
- UntypedNullExpression.cs
- LayoutSettings.cs
- QueryOutputWriter.cs
- figurelengthconverter.cs
- X509WindowsSecurityToken.cs
- KeyPressEvent.cs
- PropertyFilterAttribute.cs
- MarkupWriter.cs
- NumberSubstitution.cs
- ProgressBarHighlightConverter.cs
- PointConverter.cs
- TableNameAttribute.cs
- TextTreeObjectNode.cs
- RepeatButtonAutomationPeer.cs
- GlyphingCache.cs
- XhtmlBasicValidatorAdapter.cs
- Table.cs
- HtmlProps.cs
- SystemMulticastIPAddressInformation.cs
- EmbeddedMailObject.cs
- CloudCollection.cs
- SafeEventLogWriteHandle.cs
- metadatamappinghashervisitor.cs
- OdbcUtils.cs
- TextBoxAutoCompleteSourceConverter.cs
- ImageAnimator.cs
- ValidatingPropertiesEventArgs.cs
- DataView.cs
- DataBinder.cs
- LabelLiteral.cs
- xmlsaver.cs
- MarginsConverter.cs
- safelink.cs
- BuildResult.cs
- WebAdminConfigurationHelper.cs
- Accessible.cs
- BamlRecordHelper.cs
- AdjustableArrowCap.cs
- DbModificationClause.cs
- ExitEventArgs.cs
- SqlStream.cs
- Convert.cs
- StringValidator.cs
- HttpProfileBase.cs
- PowerModeChangedEventArgs.cs
- WebCategoryAttribute.cs
- TreeNodeClickEventArgs.cs
- FrameSecurityDescriptor.cs
- ContentPosition.cs
- WebPartTransformer.cs
- _WinHttpWebProxyDataBuilder.cs
- HttpApplication.cs
- ObjectQuery.cs
- PackagingUtilities.cs
- PipeStream.cs
- TextInfo.cs
- AppearanceEditorPart.cs
- ApplicationServiceManager.cs
- TemplatePartAttribute.cs
- View.cs