Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / xsp / System / Web / UI / WebParts / WebPartDescription.cs / 1305376 / WebPartDescription.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.WebParts { using System; public class WebPartDescription { private string _id; private string _title; private string _description; private string _imageUrl; private WebPart _part; private WebPartDescription() { } public WebPartDescription(string id, string title, string description, string imageUrl) { if (String.IsNullOrEmpty(id)) { throw new ArgumentNullException("id"); } if (String.IsNullOrEmpty(title)) { throw new ArgumentNullException("title"); } _id = id; _title = title; _description = (description != null) ? description : String.Empty; _imageUrl = (imageUrl != null) ? imageUrl : String.Empty; } public WebPartDescription(WebPart part) { string id = part.ID; if (String.IsNullOrEmpty(id)) { throw new ArgumentException(SR.GetString(SR.WebPartManager_NoWebPartID), "part"); } _id = id; string displayTitle = part.DisplayTitle; _title = (displayTitle != null) ? displayTitle : String.Empty; string description = part.Description; _description = (description != null) ? description : String.Empty; string imageUrl = part.CatalogIconImageUrl; _imageUrl = (imageUrl != null) ? imageUrl : String.Empty; _part = part; } public string CatalogIconImageUrl { get { return _imageUrl; } } public string Description { get { return _description; } } public string ID { get { return _id; } } public string Title { get { return _title; } } internal WebPart WebPart { get { return _part; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.WebControls.WebParts { using System; public class WebPartDescription { private string _id; private string _title; private string _description; private string _imageUrl; private WebPart _part; private WebPartDescription() { } public WebPartDescription(string id, string title, string description, string imageUrl) { if (String.IsNullOrEmpty(id)) { throw new ArgumentNullException("id"); } if (String.IsNullOrEmpty(title)) { throw new ArgumentNullException("title"); } _id = id; _title = title; _description = (description != null) ? description : String.Empty; _imageUrl = (imageUrl != null) ? imageUrl : String.Empty; } public WebPartDescription(WebPart part) { string id = part.ID; if (String.IsNullOrEmpty(id)) { throw new ArgumentException(SR.GetString(SR.WebPartManager_NoWebPartID), "part"); } _id = id; string displayTitle = part.DisplayTitle; _title = (displayTitle != null) ? displayTitle : String.Empty; string description = part.Description; _description = (description != null) ? description : String.Empty; string imageUrl = part.CatalogIconImageUrl; _imageUrl = (imageUrl != null) ? imageUrl : String.Empty; _part = part; } public string CatalogIconImageUrl { get { return _imageUrl; } } public string Description { get { return _description; } } public string ID { get { return _id; } } public string Title { get { return _title; } } internal WebPart WebPart { get { return _part; } } } } // 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
- XmlCountingReader.cs
- PrintController.cs
- DataGridViewCellLinkedList.cs
- FileEnumerator.cs
- HttpPostedFile.cs
- DispatchProxy.cs
- PassportIdentity.cs
- HtmlFormWrapper.cs
- StrokeRenderer.cs
- WebControlAdapter.cs
- JoinTreeSlot.cs
- BodyGlyph.cs
- CollectionViewProxy.cs
- SystemThemeKey.cs
- GeneralTransform3DCollection.cs
- TextElement.cs
- DataObjectCopyingEventArgs.cs
- CodeConditionStatement.cs
- ParameterRefs.cs
- DoubleUtil.cs
- _DisconnectOverlappedAsyncResult.cs
- TaiwanLunisolarCalendar.cs
- IssuedTokenParametersEndpointAddressElement.cs
- ResourceManagerWrapper.cs
- TripleDES.cs
- CallbackValidatorAttribute.cs
- MexHttpsBindingElement.cs
- Keywords.cs
- PagePropertiesChangingEventArgs.cs
- RelationshipSet.cs
- PropertyEntry.cs
- DataBoundControlAdapter.cs
- WhitespaceSignificantCollectionAttribute.cs
- SystemIPv6InterfaceProperties.cs
- StreamResourceInfo.cs
- _SslStream.cs
- ResizeBehavior.cs
- SqlMethodCallConverter.cs
- Exception.cs
- ExtendedPropertyInfo.cs
- DBSchemaRow.cs
- InvokePatternIdentifiers.cs
- XsdSchemaFileEditor.cs
- OdbcUtils.cs
- StateDesigner.TransitionInfo.cs
- DbMetaDataFactory.cs
- ObjectConverter.cs
- ProfileGroupSettings.cs
- XXXOnTypeBuilderInstantiation.cs
- DocComment.cs
- RegisteredArrayDeclaration.cs
- ProcessHostServerConfig.cs
- ShaderEffect.cs
- DataGridViewCellConverter.cs
- CompilerTypeWithParams.cs
- WebHttpDispatchOperationSelectorData.cs
- TypeExtensionSerializer.cs
- HideDisabledControlAdapter.cs
- XPathParser.cs
- ParentQuery.cs
- WebBrowsableAttribute.cs
- DeploymentExceptionMapper.cs
- WebPartManagerInternals.cs
- SelectionRange.cs
- MimeFormImporter.cs
- TextFormatterHost.cs
- QilStrConcatenator.cs
- SourceElementsCollection.cs
- DoWorkEventArgs.cs
- TextRangeSerialization.cs
- DataTableNewRowEvent.cs
- returneventsaver.cs
- WindowsTooltip.cs
- DataColumnMapping.cs
- Section.cs
- EntityParameter.cs
- MenuAdapter.cs
- AsymmetricKeyExchangeFormatter.cs
- SerialPinChanges.cs
- ResolveNameEventArgs.cs
- HostingEnvironmentSection.cs
- ComAdminInterfaces.cs
- XamlToRtfParser.cs
- odbcmetadatacollectionnames.cs
- SectionUpdates.cs
- MultipartIdentifier.cs
- ResXDataNode.cs
- NavigationService.cs
- ObjectTag.cs
- EndPoint.cs
- MetadataPropertyvalue.cs
- AutoCompleteStringCollection.cs
- ReachPageContentSerializerAsync.cs
- PartitionedDataSource.cs
- WorkflowOwnershipException.cs
- HashCryptoHandle.cs
- externdll.cs
- regiisutil.cs
- DrawingVisualDrawingContext.cs
- TextPatternIdentifiers.cs