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
- RegistrySecurity.cs
- DataView.cs
- SortQuery.cs
- SafeCertificateContext.cs
- KnownIds.cs
- PixelFormat.cs
- filewebrequest.cs
- ModelVisual3D.cs
- MetafileHeader.cs
- XmlNamespaceDeclarationsAttribute.cs
- LassoHelper.cs
- FontFaceLayoutInfo.cs
- ReadOnlyCollection.cs
- SafeFileMapViewHandle.cs
- OrderedDictionaryStateHelper.cs
- SqlNodeAnnotation.cs
- Sentence.cs
- WebPartExportVerb.cs
- SecurityVersion.cs
- ComponentEvent.cs
- InternalBase.cs
- XamlDesignerSerializationManager.cs
- PointCollectionConverter.cs
- AssemblyNameProxy.cs
- SessionStateUtil.cs
- ProvidePropertyAttribute.cs
- MappingModelBuildProvider.cs
- BaseTemplateBuildProvider.cs
- PageThemeBuildProvider.cs
- TagPrefixCollection.cs
- PopOutPanel.cs
- HttpCachePolicy.cs
- ConstraintStruct.cs
- BinaryUtilClasses.cs
- AuthenticodeSignatureInformation.cs
- CreateUserErrorEventArgs.cs
- EntitySqlQueryState.cs
- ObjectComplexPropertyMapping.cs
- DES.cs
- _CookieModule.cs
- CustomPeerResolverService.cs
- WriteTimeStream.cs
- HttpApplicationFactory.cs
- OleDbCommandBuilder.cs
- WarningException.cs
- NullableFloatAverageAggregationOperator.cs
- DefaultMemberAttribute.cs
- LassoHelper.cs
- XmlUtil.cs
- CommonRemoteMemoryBlock.cs
- ApplicationSecurityInfo.cs
- ReceiveActivityDesigner.cs
- ReferencedAssembly.cs
- InvalidProgramException.cs
- WebPartDescriptionCollection.cs
- FtpWebResponse.cs
- ChoiceConverter.cs
- RuleElement.cs
- DataBoundControlDesigner.cs
- DataGridViewCellPaintingEventArgs.cs
- CommonXSendMessage.cs
- glyphs.cs
- TrustManagerPromptUI.cs
- XmlDataSource.cs
- XmlWrappingWriter.cs
- BroadcastEventHelper.cs
- CorrelationTokenInvalidatedHandler.cs
- RoutedEventArgs.cs
- XmlAttributeCollection.cs
- NullableBoolConverter.cs
- TransformFinalBlockRequest.cs
- Int32CAMarshaler.cs
- MaterialGroup.cs
- SafeLibraryHandle.cs
- WpfSharedXamlSchemaContext.cs
- ChtmlTextBoxAdapter.cs
- SerTrace.cs
- EmptyStringExpandableObjectConverter.cs
- ClientTarget.cs
- Vector3DAnimation.cs
- peernodeimplementation.cs
- DeflateStream.cs
- DoubleCollection.cs
- MetadataItem.cs
- SchemaElement.cs
- ObjectComplexPropertyMapping.cs
- EnumValAlphaComparer.cs
- PropertyToken.cs
- SHA256.cs
- FixedDocument.cs
- ParallelDesigner.cs
- PackageRelationship.cs
- Schema.cs
- QueryOpeningEnumerator.cs
- DesignerActionHeaderItem.cs
- OpenTypeLayoutCache.cs
- HttpValueCollection.cs
- InArgument.cs
- QuadraticEase.cs
- HttpNamespaceReservationInstallComponent.cs