Export (0) Print
Expand All

RootDesignerSerializerAttribute Class

NOTE: This class is now obsolete. The non-obsolete alternative is DesignerSerializerAttribute.

Indicates the base serializer to use for a root designer object. This class cannot be inherited.

Namespace: System.ComponentModel.Design.Serialization
Assembly: System (in system.dll)

[AttributeUsageAttribute(AttributeTargets.Class|AttributeTargets.Interface, AllowMultiple=true, Inherited=true)] 
[ObsoleteAttribute("This attribute has been deprecated. Use DesignerSerializerAttribute instead.  For example, to specify a root designer for CodeDom, use DesignerSerializerAttribute(...,typeof(TypeCodeDomSerializer)).  http://go.microsoft.com/fwlink/?linkid=14202")] 
public sealed class RootDesignerSerializerAttribute : Attribute
/** @attribute AttributeUsageAttribute(AttributeTargets.Class|AttributeTargets.Interface, AllowMultiple=true, Inherited=true) */ 
/** @attribute ObsoleteAttribute("This attribute has been deprecated. Use DesignerSerializerAttribute instead.  For example, to specify a root designer for CodeDom, use DesignerSerializerAttribute(...,typeof(TypeCodeDomSerializer)).  http://go.microsoft.com/fwlink/?linkid=14202") */ 
public final class RootDesignerSerializerAttribute extends Attribute
AttributeUsageAttribute(AttributeTargets.Class|AttributeTargets.Interface, AllowMultiple=true, Inherited=true) 
ObsoleteAttribute("This attribute has been deprecated. Use DesignerSerializerAttribute instead.  For example, to specify a root designer for CodeDom, use DesignerSerializerAttribute(...,typeof(TypeCodeDomSerializer)).  http://go.microsoft.com/fwlink/?linkid=14202") 
public final class RootDesignerSerializerAttribute extends Attribute
Not applicable.

RootDesignerSerializerAttribute indicates the serializer to use when the serialization manager serializes the design document, and whether the specified serializer supports automatic reloading of the design document without first completely disposing of the document.

This attribute contains the following significant members:

  • SerializerTypeName indicates what serialization object to use to serialize the class at design time.

  • SerializerBaseTypeName indicates the fully qualified name of the serialization object's base type.

  • Reloadable indicates whether the serializer supports reloading a design document without user interaction to open a new designer view.

The following example code applies a RootDesignerSerializerAttribute to a component.

[DesignerSerializer(typeof(MyCodeDomSerializer), typeof(CodeDomSerializer))]
public class MyComponent : Component {
    private string localProperty = "Component Property Value";
    public string LocalProperty {
        get {
            return localProperty;
        }
        set {
            localProperty = value;
        }
    }
}

/** @attribute DesignerSerializer(MyCodeDomSerializer.class,
  CodeDomSerializer.class)
 */

public class MyComponent extends Component
{
    private String localProperty = "Component Property Value";
      
    /** @property 
     */
    public String get_LocalProperty()
    {
        return localProperty;
    } //get_LocalProperty

    /** @property 
     */
    public void set_LocalProperty (String value )
    {
        localProperty = value;
    } //set_LocalProperty
} //MyComponent

System.Object
   System.Attribute
    System.ComponentModel.Design.Serialization.RootDesignerSerializerAttribute

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 1.0, 1.1, 2.0
Obsolete (compiler warning) in 3.0

Community Additions

ADD
Show:
© 2014 Microsoft