Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / xsp / System / Web / UI / WebParts / WebPartZoneCollection.cs / 1 / WebPartZoneCollection.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.WebParts { using System; using System.Collections; using System.Globalization; using System.Security.Permissions; ////// Read-only collection of WebPartZones. Collection cannot be modified after contstruction. /// [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class WebPartZoneCollection : ReadOnlyCollectionBase { public WebPartZoneCollection() { } public WebPartZoneCollection(ICollection webPartZones) { if (webPartZones == null) { throw new ArgumentNullException("webPartZones"); } foreach (object obj in webPartZones) { if (obj == null) { throw new ArgumentException(SR.GetString(SR.Collection_CantAddNull), "webPartZones"); } if (!(obj is WebPartZone)) { throw new ArgumentException(SR.GetString(SR.Collection_InvalidType, "WebPartZone"), "webPartZones"); } InnerList.Add(obj); } } internal int Add(WebPartZoneBase value) { return InnerList.Add(value); } public bool Contains(WebPartZoneBase value) { return InnerList.Contains(value); } public int IndexOf(WebPartZoneBase value) { return InnerList.IndexOf(value); } public WebPartZoneBase this[int index] { get { return (WebPartZoneBase) InnerList[index]; } } public WebPartZoneBase this[string id] { get { WebPartZoneBase selectedZone = null; foreach (WebPartZoneBase zone in InnerList) { if (String.Equals(zone.ID, id, StringComparison.OrdinalIgnoreCase)) { selectedZone = zone; break; } } return selectedZone; } } ////// public void CopyTo(WebPartZoneBase[] array, int index) { InnerList.CopyTo(array, index); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //Copies contents from the collection to a specified array with a /// specified starting index. ///// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.WebParts { using System; using System.Collections; using System.Globalization; using System.Security.Permissions; ////// Read-only collection of WebPartZones. Collection cannot be modified after contstruction. /// [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class WebPartZoneCollection : ReadOnlyCollectionBase { public WebPartZoneCollection() { } public WebPartZoneCollection(ICollection webPartZones) { if (webPartZones == null) { throw new ArgumentNullException("webPartZones"); } foreach (object obj in webPartZones) { if (obj == null) { throw new ArgumentException(SR.GetString(SR.Collection_CantAddNull), "webPartZones"); } if (!(obj is WebPartZone)) { throw new ArgumentException(SR.GetString(SR.Collection_InvalidType, "WebPartZone"), "webPartZones"); } InnerList.Add(obj); } } internal int Add(WebPartZoneBase value) { return InnerList.Add(value); } public bool Contains(WebPartZoneBase value) { return InnerList.Contains(value); } public int IndexOf(WebPartZoneBase value) { return InnerList.IndexOf(value); } public WebPartZoneBase this[int index] { get { return (WebPartZoneBase) InnerList[index]; } } public WebPartZoneBase this[string id] { get { WebPartZoneBase selectedZone = null; foreach (WebPartZoneBase zone in InnerList) { if (String.Equals(zone.ID, id, StringComparison.OrdinalIgnoreCase)) { selectedZone = zone; break; } } return selectedZone; } } ////// public void CopyTo(WebPartZoneBase[] array, int index) { InnerList.CopyTo(array, index); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.Copies contents from the collection to a specified array with a /// specified starting index. ///
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- PointLightBase.cs
- ComponentResourceKeyConverter.cs
- XmlDictionaryWriter.cs
- LabelLiteral.cs
- EditorZoneAutoFormat.cs
- WebPartEventArgs.cs
- ExpressionPrefixAttribute.cs
- RadialGradientBrush.cs
- XmlSchemaImport.cs
- ManagementObjectCollection.cs
- ImmutablePropertyDescriptorGridEntry.cs
- File.cs
- KnowledgeBase.cs
- ReachFixedPageSerializerAsync.cs
- FacetDescription.cs
- StylusLogic.cs
- BlurEffect.cs
- TextMarkerSource.cs
- CursorConverter.cs
- StoreItemCollection.cs
- ForeignConstraint.cs
- WsdlImporterElement.cs
- MappedMetaModel.cs
- Double.cs
- ExtensionWindowHeader.cs
- UsernameTokenFactoryCredential.cs
- WindowsEditBoxRange.cs
- _AcceptOverlappedAsyncResult.cs
- SQLByte.cs
- SiteMapNodeItem.cs
- OdbcDataReader.cs
- PrintControllerWithStatusDialog.cs
- ListViewEditEventArgs.cs
- GroupBoxAutomationPeer.cs
- StoreItemCollection.cs
- listitem.cs
- WebZone.cs
- BitmapCache.cs
- PasswordRecovery.cs
- SettingsPropertyValueCollection.cs
- XmlPropertyBag.cs
- HeaderCollection.cs
- QilGenerator.cs
- PersonalizablePropertyEntry.cs
- AttachedAnnotationChangedEventArgs.cs
- CodeArgumentReferenceExpression.cs
- BindingMemberInfo.cs
- XpsInterleavingPolicy.cs
- UserPreferenceChangingEventArgs.cs
- ResolveNameEventArgs.cs
- DecimalSumAggregationOperator.cs
- CompositeScriptReference.cs
- SpoolingTask.cs
- EntityParameterCollection.cs
- CurrentChangedEventManager.cs
- versioninfo.cs
- PathFigureCollectionValueSerializer.cs
- ClientSettings.cs
- BulletedList.cs
- SqlParameter.cs
- OleDbConnection.cs
- HtmlTableCell.cs
- KeyValueInternalCollection.cs
- BitmapSourceSafeMILHandle.cs
- KeySplineConverter.cs
- SudsCommon.cs
- TaskFileService.cs
- FileResponseElement.cs
- HttpCacheParams.cs
- ActionMismatchAddressingException.cs
- MutableAssemblyCacheEntry.cs
- OleServicesContext.cs
- GlobalizationAssembly.cs
- WindowsRebar.cs
- NetworkAddressChange.cs
- PrinterResolution.cs
- DesignerActionUIStateChangeEventArgs.cs
- TextFormatterHost.cs
- TextDecorations.cs
- EmptyStringExpandableObjectConverter.cs
- ConfigXmlReader.cs
- UpdateTracker.cs
- DataGridViewRowsAddedEventArgs.cs
- AssociationTypeEmitter.cs
- ProfileEventArgs.cs
- ImageMap.cs
- WebServiceEnumData.cs
- StreamSecurityUpgradeAcceptor.cs
- QueryIntervalOp.cs
- SmtpException.cs
- _SafeNetHandles.cs
- SystemUdpStatistics.cs
- PackagingUtilities.cs
- ThicknessConverter.cs
- ValidationErrorEventArgs.cs
- RemotingAttributes.cs
- ModelItemCollection.cs
- CodeVariableDeclarationStatement.cs
- ChangeInterceptorAttribute.cs
- SharedConnectionInfo.cs