Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / Design / Serialization / DesignerSerializerAttribute.cs / 1 / DesignerSerializerAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.ComponentModel.Design.Serialization { using System.Security.Permissions; ////// This attribute can be placed on a class to indicate what serialization /// object should be used to serialize the class at design time. /// [AttributeUsage(AttributeTargets.Class | AttributeTargets.Interface, AllowMultiple = true, Inherited = true)] public sealed class DesignerSerializerAttribute : Attribute { private string serializerTypeName; private string serializerBaseTypeName; private string typeId; ////// Creates a new designer serialization attribute. /// public DesignerSerializerAttribute(Type serializerType, Type baseSerializerType) { this.serializerTypeName = serializerType.AssemblyQualifiedName; this.serializerBaseTypeName = baseSerializerType.AssemblyQualifiedName; } ////// Creates a new designer serialization attribute. /// public DesignerSerializerAttribute(string serializerTypeName, Type baseSerializerType) { this.serializerTypeName = serializerTypeName; this.serializerBaseTypeName = baseSerializerType.AssemblyQualifiedName; } ////// Creates a new designer serialization attribute. /// public DesignerSerializerAttribute(string serializerTypeName, string baseSerializerTypeName) { this.serializerTypeName = serializerTypeName; this.serializerBaseTypeName = baseSerializerTypeName; } ////// Retrieves the fully qualified type name of the serializer. /// public string SerializerTypeName { get { return serializerTypeName; } } ////// Retrieves the fully qualified type name of the serializer base type. /// public string SerializerBaseTypeName { get { return serializerBaseTypeName; } } ////// /// public override object TypeId { get { if (typeId == null) { string baseType = serializerBaseTypeName; int comma = baseType.IndexOf(','); if (comma != -1) { baseType = baseType.Substring(0, comma); } typeId = GetType().FullName + baseType; } return typeId; } } } }/// This defines a unique ID for this attribute type. It is used /// by filtering algorithms to identify two attributes that are /// the same type. For most attributes, this just returns the /// Type instance for the attribute. EditorAttribute overrides /// this to include the type of the editor base type. /// ///
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- LocalizationParserHooks.cs
- TranslateTransform3D.cs
- WorkflowDebuggerSteppingAttribute.cs
- TableLayoutSettingsTypeConverter.cs
- VisualBasicSettings.cs
- Int64Converter.cs
- Highlights.cs
- TemplateEditingVerb.cs
- ValueConversionAttribute.cs
- DecimalConverter.cs
- ZipIORawDataFileBlock.cs
- TransactionScope.cs
- BitmapMetadataEnumerator.cs
- documentsequencetextpointer.cs
- CollectionViewSource.cs
- InternalMappingException.cs
- ObjectViewFactory.cs
- XpsManager.cs
- TransactionFlowOption.cs
- BinaryFormatter.cs
- XmlParserContext.cs
- WebFormsRootDesigner.cs
- LiteralTextContainerControlBuilder.cs
- Version.cs
- WorkflowViewManager.cs
- TypedTableBase.cs
- MultitargetUtil.cs
- CodeDelegateInvokeExpression.cs
- Vector3DValueSerializer.cs
- SoundPlayer.cs
- SmtpMail.cs
- PropertyValueUIItem.cs
- RectKeyFrameCollection.cs
- ConvertEvent.cs
- CompressStream.cs
- BinHexDecoder.cs
- DesignerObjectListAdapter.cs
- Internal.cs
- Item.cs
- VectorAnimation.cs
- WS2007HttpBindingCollectionElement.cs
- HttpEncoder.cs
- Command.cs
- TrackBar.cs
- TagMapInfo.cs
- ComponentRenameEvent.cs
- PropertySourceInfo.cs
- NativeMethods.cs
- TreeView.cs
- RuleValidation.cs
- ConnectionStringsExpressionBuilder.cs
- TextBoxBase.cs
- SqlDataSourceView.cs
- OpenTypeCommon.cs
- InternalBase.cs
- ClientTarget.cs
- UniformGrid.cs
- Cursor.cs
- sqlnorm.cs
- Rijndael.cs
- BinaryWriter.cs
- GridViewItemAutomationPeer.cs
- WebPartDisplayModeEventArgs.cs
- CaseCqlBlock.cs
- CachingHintValidation.cs
- FragmentQueryKB.cs
- PaperSource.cs
- ArgumentOutOfRangeException.cs
- UrlAuthFailedErrorFormatter.cs
- SmtpSection.cs
- WeakEventManager.cs
- SAPICategories.cs
- Label.cs
- LinkTarget.cs
- DataTemplateSelector.cs
- MemoryMappedView.cs
- GeometryDrawing.cs
- DataGridViewCellStyleChangedEventArgs.cs
- OleDbFactory.cs
- CompilationSection.cs
- XmlElement.cs
- ModelItemExtensions.cs
- TextServicesLoader.cs
- SafeNativeMethods.cs
- SafeArrayTypeMismatchException.cs
- updatecommandorderer.cs
- TreeWalkHelper.cs
- FixedSOMPage.cs
- CharacterShapingProperties.cs
- XmlSchemaExternal.cs
- TypeBuilder.cs
- LayoutTable.cs
- SingleAnimationBase.cs
- ChannelManagerService.cs
- InitializerFacet.cs
- TextDecoration.cs
- AuthenticatedStream.cs
- TextTreeRootNode.cs
- XmlSerializerNamespaces.cs
- OleServicesContext.cs