Code:
/ FX-1434 / FX-1434 / 1.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
- XmlSchemaComplexType.cs
- TextTreeNode.cs
- mda.cs
- XmlMembersMapping.cs
- ContractNamespaceAttribute.cs
- IndexedGlyphRun.cs
- SqlCacheDependency.cs
- ClockGroup.cs
- GeneratedView.cs
- DispatchChannelSink.cs
- TrackingMemoryStream.cs
- FusionWrap.cs
- DbConnectionStringBuilder.cs
- Compilation.cs
- _LocalDataStoreMgr.cs
- ProfileEventArgs.cs
- Collection.cs
- IndicShape.cs
- RegionInfo.cs
- CallbackValidatorAttribute.cs
- Configuration.cs
- RMEnrollmentPage2.cs
- ImageEditor.cs
- ColumnResizeUndoUnit.cs
- EntryIndex.cs
- Registry.cs
- Calendar.cs
- SqlFunctionAttribute.cs
- VectorAnimationBase.cs
- RecognizerInfo.cs
- QueryGeneratorBase.cs
- XXXInfos.cs
- XmlMemberMapping.cs
- ToolBarButtonClickEvent.cs
- ScriptingAuthenticationServiceSection.cs
- NullableFloatAverageAggregationOperator.cs
- AppendHelper.cs
- handlecollector.cs
- UpdatePanelTrigger.cs
- CookieParameter.cs
- TdsValueSetter.cs
- NavigationEventArgs.cs
- PrimitiveCodeDomSerializer.cs
- QueryCacheEntry.cs
- FileIOPermission.cs
- AppDomainProtocolHandler.cs
- ProcessHost.cs
- PolyLineSegmentFigureLogic.cs
- AutomationElement.cs
- SortDescriptionCollection.cs
- ConditionalAttribute.cs
- FieldAccessException.cs
- CommandDesigner.cs
- ConnectivityStatus.cs
- XmlTypeAttribute.cs
- VectorCollection.cs
- DesignerAutoFormat.cs
- XmlSerializerNamespaces.cs
- MachineKey.cs
- BamlTreeMap.cs
- DesignerProperties.cs
- BamlResourceContent.cs
- ComplexType.cs
- BamlLocalizationDictionary.cs
- XmlArrayItemAttributes.cs
- OdbcConnectionHandle.cs
- DataRowCollection.cs
- DataGridViewSelectedCellCollection.cs
- GroupItemAutomationPeer.cs
- FileAuthorizationModule.cs
- UpdatePanelTriggerCollection.cs
- UnsafeNativeMethods.cs
- DataTableTypeConverter.cs
- RegistryPermission.cs
- _TransmitFileOverlappedAsyncResult.cs
- SafeRightsManagementQueryHandle.cs
- EntityDataReader.cs
- UnmanagedMarshal.cs
- WindowsFormsSynchronizationContext.cs
- backend.cs
- BlurEffect.cs
- TableSectionStyle.cs
- EntityDataSourceValidationException.cs
- XPathBinder.cs
- _DisconnectOverlappedAsyncResult.cs
- RetrieveVirtualItemEventArgs.cs
- WebPartManagerInternals.cs
- TransformValueSerializer.cs
- SerializationInfo.cs
- MethodBody.cs
- ValidationRuleCollection.cs
- TextEffectCollection.cs
- SchemaExporter.cs
- ConditionalAttribute.cs
- LocationUpdates.cs
- CircleHotSpot.cs
- BindingOperations.cs
- categoryentry.cs
- HttpSysSettings.cs
- BuildProviderCollection.cs