Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / WinForms / Managed / System / WinForms / GridItemCollection.cs / 1 / GridItemCollection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Windows.Forms { using System.Diagnostics; using System; using System.IO; using System.Collections; using System.Globalization; using System.Windows.Forms; using System.Drawing; using System.Drawing.Design; using System.Windows.Forms.Design; using System.Windows.Forms.ComponentModel.Com2Interop; using System.ComponentModel; using System.ComponentModel.Design; using System.Windows.Forms.PropertyGridInternal; using System.Reflection; using System.Runtime.InteropServices; using Microsoft.Win32; ////// /// A read-only collection of GridItem objects /// public class GridItemCollection : ICollection { ////// /// public static GridItemCollection Empty = new GridItemCollection(new GridItem[0]); internal GridItem[] entries; internal GridItemCollection(GridItem[] entries) { if (entries == null) { this.entries = new GridItem[0]; } else { this.entries = entries; } } ///[To be supplied.] ////// /// Retrieves the number of member attributes. /// public int Count { get { return entries.Length; } } ////// object ICollection.SyncRoot { get { return this; } } /// /// bool ICollection.IsSynchronized { get { return false; } } /// /// /// Retrieves the member attribute with the specified index. /// public GridItem this[int index] { get { return entries[index]; } } ////// /// public GridItem this[string label]{ get { foreach(GridItem g in entries) { if (g.Label == label) { return g; } } return null; } } ///[To be supplied.] ////// void ICollection.CopyTo(Array dest, int index) { if (entries.Length > 0) { System.Array.Copy(entries, 0, dest, index, entries.Length); } } /// /// /// Creates and retrieves a new enumerator for this collection. /// public IEnumerator GetEnumerator() { return entries.GetEnumerator(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Windows.Forms { using System.Diagnostics; using System; using System.IO; using System.Collections; using System.Globalization; using System.Windows.Forms; using System.Drawing; using System.Drawing.Design; using System.Windows.Forms.Design; using System.Windows.Forms.ComponentModel.Com2Interop; using System.ComponentModel; using System.ComponentModel.Design; using System.Windows.Forms.PropertyGridInternal; using System.Reflection; using System.Runtime.InteropServices; using Microsoft.Win32; ////// /// A read-only collection of GridItem objects /// public class GridItemCollection : ICollection { ////// /// public static GridItemCollection Empty = new GridItemCollection(new GridItem[0]); internal GridItem[] entries; internal GridItemCollection(GridItem[] entries) { if (entries == null) { this.entries = new GridItem[0]; } else { this.entries = entries; } } ///[To be supplied.] ////// /// Retrieves the number of member attributes. /// public int Count { get { return entries.Length; } } ////// object ICollection.SyncRoot { get { return this; } } /// /// bool ICollection.IsSynchronized { get { return false; } } /// /// /// Retrieves the member attribute with the specified index. /// public GridItem this[int index] { get { return entries[index]; } } ////// /// public GridItem this[string label]{ get { foreach(GridItem g in entries) { if (g.Label == label) { return g; } } return null; } } ///[To be supplied.] ////// void ICollection.CopyTo(Array dest, int index) { if (entries.Length > 0) { System.Array.Copy(entries, 0, dest, index, entries.Length); } } /// /// /// Creates and retrieves a new enumerator for this collection. /// public IEnumerator GetEnumerator() { return entries.GetEnumerator(); } } } // 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
- GreenMethods.cs
- PolyLineSegment.cs
- JavaScriptSerializer.cs
- DataGridViewCellMouseEventArgs.cs
- AuthenticationServiceManager.cs
- OutputCacheModule.cs
- CodeIndexerExpression.cs
- DataContractJsonSerializerOperationFormatter.cs
- BookmarkResumptionRecord.cs
- ListViewItem.cs
- DependentTransaction.cs
- EncodingNLS.cs
- VBIdentifierNameEditor.cs
- WebPartsSection.cs
- OneWayBindingElementImporter.cs
- XmlSerializerAssemblyAttribute.cs
- Label.cs
- HttpCacheParams.cs
- FixedSOMElement.cs
- ApplicationFileParser.cs
- RequestContext.cs
- AdornerLayer.cs
- BindingExpressionBase.cs
- AsymmetricKeyExchangeDeformatter.cs
- prefixendpointaddressmessagefilter.cs
- FontResourceCache.cs
- _DomainName.cs
- AutoGeneratedField.cs
- StructuredCompositeActivityDesigner.cs
- ObjectParameter.cs
- EntityWithChangeTrackerStrategy.cs
- XmlTextWriter.cs
- Size.cs
- Panel.cs
- Sorting.cs
- SqlProvider.cs
- ReadWriteSpinLock.cs
- EntityCollection.cs
- LambdaCompiler.Lambda.cs
- TextMarkerSource.cs
- StaticContext.cs
- DeferredTextReference.cs
- FastPropertyAccessor.cs
- Internal.cs
- Trace.cs
- StorageRoot.cs
- ColumnCollection.cs
- HttpResponse.cs
- UserControl.cs
- LicenseManager.cs
- ZipFileInfoCollection.cs
- UTF8Encoding.cs
- ModelTreeManager.cs
- returneventsaver.cs
- GeneralTransform3DGroup.cs
- Executor.cs
- HttpResponse.cs
- TimeEnumHelper.cs
- TakeQueryOptionExpression.cs
- BufferModesCollection.cs
- StrongNameKeyPair.cs
- Control.cs
- RunInstallerAttribute.cs
- SystemIcmpV4Statistics.cs
- ConfigurationPermission.cs
- ProfileProvider.cs
- ToolStripPanelCell.cs
- Span.cs
- CultureSpecificStringDictionary.cs
- CornerRadius.cs
- ChtmlLinkAdapter.cs
- DocumentApplicationState.cs
- GridViewAutomationPeer.cs
- CustomErrorsSection.cs
- TiffBitmapDecoder.cs
- ObjectDataSourceChooseTypePanel.cs
- ImageMap.cs
- GridPatternIdentifiers.cs
- FocusChangedEventArgs.cs
- FrameworkContentElement.cs
- QuaternionAnimationBase.cs
- TimeStampChecker.cs
- TextEffectResolver.cs
- XmlTextReaderImplHelpers.cs
- SrgsElement.cs
- ApplicationDirectoryMembershipCondition.cs
- RelationshipEndMember.cs
- PointConverter.cs
- BatchParser.cs
- TemplateKey.cs
- ComponentCommands.cs
- CodeTryCatchFinallyStatement.cs
- RoleGroup.cs
- XamlNamespaceHelper.cs
- FactoryGenerator.cs
- XdrBuilder.cs
- DataGridTable.cs
- ObjectContextServiceProvider.cs
- DashStyles.cs
- MethodCallTranslator.cs