1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319
|
<?xml version="1.0" encoding="utf-8"?>
<Type Name="CodeDomSerializer" FullName="System.ComponentModel.Design.Serialization.CodeDomSerializer">
<TypeSignature Language="C#" Value="public class CodeDomSerializer : System.ComponentModel.Design.Serialization.CodeDomSerializerBase" />
<AssemblyInfo>
<AssemblyName>System.Design</AssemblyName>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Base>
<BaseTypeName>System.ComponentModel.Design.Serialization.CodeDomSerializerBase</BaseTypeName>
</Base>
<Interfaces />
<Docs>
<remarks>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>You can implement a custom <see cref="T:System.ComponentModel.Design.Serialization.CodeDomSerializer" /> to control the generation of component initialization code for a type of component at design time.</para>
<para>To implement a custom <see cref="T:System.ComponentModel.Design.Serialization.CodeDomSerializer" /> for a type, you must: </para>
<list type="ordered">
<item>
<para>Define a class that derives from <see cref="T:System.ComponentModel.Design.Serialization.CodeDomSerializer" />.</para>
</item>
<item>
<para>Implement method overrides for serialization or deserialization methods. (See the information below for details.) </para>
</item>
<item>
<para>Associate your custom <see cref="T:System.ComponentModel.Design.Serialization.CodeDomSerializer" /> implementation with a type of component using a <see cref="T:System.ComponentModel.Design.Serialization.DesignerSerializerAttribute" />.</para>
</item>
</list>
<para>To implement a serialization method for generating configuration code for a component: </para>
<list type="ordered">
<item>
<para>Within a class that derives from <see cref="T:System.ComponentModel.Design.Serialization.CodeDomSerializer" />, override an appropriate serialization or deserialization method of the base class.</para>
</item>
<item>
<para>If you want the default serializer to generate code statements that perform the default component configuration, you must obtain and call the base serializer for the component. To obtain the base serializer for the component, call the <see cref="M:System.ComponentModel.Design.Serialization.IDesignerSerializationManager.GetSerializer(System.Type,System.Type)" /> method of the <see cref="T:System.ComponentModel.Design.Serialization.IDesignerSerializationManager" /> passed to your method override. Pass the <see cref="M:System.ComponentModel.Design.Serialization.IDesignerSerializationManager.GetSerializer(System.Type,System.Type)" /> method the type of the component to serialize the configuration of, along with the base type of serializer you are requesting, which is <see cref="T:System.ComponentModel.Design.Serialization.CodeDomSerializer" />. Call the method of the same name you are overriding on the base serializer, using the <see cref="T:System.ComponentModel.Design.Serialization.IDesignerSerializationManager" /> and object passed to your method override. If you are implementing the <see cref="M:System.ComponentModel.Design.Serialization.CodeDomSerializer.Serialize(System.ComponentModel.Design.Serialization.IDesignerSerializationManager,System.Object)" /> method, the <see cref="M:System.ComponentModel.Design.Serialization.CodeDomSerializer.Serialize(System.ComponentModel.Design.Serialization.IDesignerSerializationManager,System.Object)" /> method of the base serializer will return an object. The type of this object depends on the type of base serializer which depends on the type of component you are serializing the values of. If you are implementing the <see cref="M:System.ComponentModel.Design.Serialization.CodeDomSerializerBase.SerializeEvents(System.ComponentModel.Design.Serialization.IDesignerSerializationManager,System.CodeDom.CodeStatementCollection,System.Object,System.Attribute[])" />, <see cref="M:System.ComponentModel.Design.Serialization.CodeDomSerializerBase.SerializeProperties(System.ComponentModel.Design.Serialization.IDesignerSerializationManager,System.CodeDom.CodeStatementCollection,System.Object,System.Attribute[])" />, or <see cref="M:System.ComponentModel.Design.Serialization.CodeDomSerializerBase.SerializePropertiesToResources(System.ComponentModel.Design.Serialization.IDesignerSerializationManager,System.CodeDom.CodeStatementCollection,System.Object,System.Attribute[])" /> method, you must create a new <see cref="T:System.CodeDom.CodeStatementCollection" /> to contain the generated code statements, and pass it to the method.</para>
</item>
<item>
<para>If you have called a base serializer method, you will have a <see cref="T:System.CodeDom.CodeStatementCollection" /> that contains the statements to generate to initialize the component. Otherwise you should create a <see cref="T:System.CodeDom.CodeStatementCollection" />. You can add <see cref="T:System.CodeDom.CodeStatement" /> objects representing statements to generate in the component configuration code to this collection.</para>
</item>
<item>
<para>Return the <see cref="T:System.CodeDom.CodeStatementCollection" /> that represents the source code to generate to configure the component.</para>
</item>
</list>
</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Serializes an object graph to a series of CodeDOM statements. This class provides an abstract base class for a serializer.</para>
</summary>
</Docs>
<Members>
<Member MemberName=".ctor">
<MemberSignature Language="C#" Value="public CodeDomSerializer ();" />
<MemberType>Constructor</MemberType>
<Parameters />
<Docs>
<remarks>To be added.</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Initializes a new instance of the <see cref="T:System.ComponentModel.Design.Serialization.CodeDomSerializer" /> class. </para>
</summary>
</Docs>
<AssemblyInfo>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
</Member>
<Member MemberName="Deserialize">
<MemberSignature Language="C#" Value="public virtual object Deserialize (System.ComponentModel.Design.Serialization.IDesignerSerializationManager manager, object codeObject);" />
<MemberType>Method</MemberType>
<ReturnValue>
<ReturnType>System.Object</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="manager" Type="System.ComponentModel.Design.Serialization.IDesignerSerializationManager" />
<Parameter Name="codeObject" Type="System.Object" />
</Parameters>
<Docs>
<remarks>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>This method uses the serialization manager to create objects and resolve data types. The root of the object graph is returned.</para>
</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Deserializes the specified serialized CodeDOM object into an object.</para>
</summary>
<returns>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>The deserialized CodeDOM object.</para>
</returns>
<param name="manager">
<attribution license="cc4" from="Microsoft" modified="false" />A serialization manager interface that is used during the deserialization process. </param>
<param name="codeObject">
<attribution license="cc4" from="Microsoft" modified="false" />A serialized CodeDOM object to deserialize. </param>
</Docs>
<AssemblyInfo>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
</Member>
<Member MemberName="DeserializeStatementToInstance">
<MemberSignature Language="C#" Value="protected object DeserializeStatementToInstance (System.ComponentModel.Design.Serialization.IDesignerSerializationManager manager, System.CodeDom.CodeStatement statement);" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Object</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="manager" Type="System.ComponentModel.Design.Serialization.IDesignerSerializationManager" />
<Parameter Name="statement" Type="System.CodeDom.CodeStatement" />
</Parameters>
<Docs>
<remarks>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>The <see cref="M:System.ComponentModel.Design.Serialization.CodeDomSerializer.DeserializeStatementToInstance(System.ComponentModel.Design.Serialization.IDesignerSerializationManager,System.CodeDom.CodeStatement)" /> is equivalent of calling <see cref="M:System.ComponentModel.Design.Serialization.CodeDomSerializerBase.DeserializeStatement(System.ComponentModel.Design.Serialization.IDesignerSerializationManager,System.CodeDom.CodeStatement)" />, except that it returns an object instance if the resulting statement was a variable assign statement, a variable declaration with an init expression, or a field assignment statement.</para>
</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Deserializes a single statement.</para>
</summary>
<returns>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>An object instance resulting from deserializing <paramref name="statement" />.</para>
</returns>
<param name="manager">
<attribution license="cc4" from="Microsoft" modified="false" />The serialization manager to use for serialization.</param>
<param name="statement">
<attribution license="cc4" from="Microsoft" modified="false" />The statement to deserialize.</param>
</Docs>
</Member>
<Member MemberName="GetTargetComponentName">
<MemberSignature Language="C#" Value="public virtual string GetTargetComponentName (System.CodeDom.CodeStatement statement, System.CodeDom.CodeExpression expression, Type targetType);" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.String</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="statement" Type="System.CodeDom.CodeStatement" />
<Parameter Name="expression" Type="System.CodeDom.CodeExpression" />
<Parameter Name="targetType" Type="System.Type" />
</Parameters>
<Docs>
<remarks>To be added.</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Determines which statement group the given statement should belong to.</para>
</summary>
<returns>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>The name of the component with which <paramref name="statement" /> should be grouped.</para>
</returns>
<param name="statement">
<attribution license="cc4" from="Microsoft" modified="false" />The <see cref="T:System.CodeDom.CodeStatement" /> for which to determine the group.</param>
<param name="expression">
<attribution license="cc4" from="Microsoft" modified="false" />A <see cref="T:System.CodeDom.CodeExpression" /> that <paramref name="statement" /> has been reduced to.</param>
<param name="targetType">
<attribution license="cc4" from="Microsoft" modified="false" />The <see cref="T:System.Type" /> of <paramref name="statement" />.</param>
</Docs>
</Member>
<Member MemberName="Serialize">
<MemberSignature Language="C#" Value="public virtual object Serialize (System.ComponentModel.Design.Serialization.IDesignerSerializationManager manager, object value);" />
<MemberType>Method</MemberType>
<ReturnValue>
<ReturnType>System.Object</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="manager" Type="System.ComponentModel.Design.Serialization.IDesignerSerializationManager" />
<Parameter Name="value" Type="System.Object" />
</Parameters>
<Docs>
<remarks>To be added.</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Serializes the specified object into a CodeDOM object.</para>
</summary>
<returns>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>A CodeDOM object representing the object that has been serialized.</para>
</returns>
<param name="manager">
<attribution license="cc4" from="Microsoft" modified="false" />The serialization manager to use during serialization. </param>
<param name="value">
<attribution license="cc4" from="Microsoft" modified="false" />The object to serialize. </param>
</Docs>
<AssemblyInfo>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
</Member>
<Member MemberName="SerializeAbsolute">
<MemberSignature Language="C#" Value="public virtual object SerializeAbsolute (System.ComponentModel.Design.Serialization.IDesignerSerializationManager manager, object value);" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.Object</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="manager" Type="System.ComponentModel.Design.Serialization.IDesignerSerializationManager" />
<Parameter Name="value" Type="System.Object" />
</Parameters>
<Docs>
<remarks>To be added.</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Serializes the given object, accounting for default values.</para>
</summary>
<returns>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>A CodeDom object representing <paramref name="value" />.</para>
</returns>
<param name="manager">
<attribution license="cc4" from="Microsoft" modified="false" />The serialization manager to use for serialization.</param>
<param name="value">
<attribution license="cc4" from="Microsoft" modified="false" />The object to serialize.</param>
</Docs>
</Member>
<Member MemberName="SerializeMember">
<MemberSignature Language="C#" Value="public virtual System.CodeDom.CodeStatementCollection SerializeMember (System.ComponentModel.Design.Serialization.IDesignerSerializationManager manager, object owningobject, System.ComponentModel.MemberDescriptor member);" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.CodeDom.CodeStatementCollection</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="manager" Type="System.ComponentModel.Design.Serialization.IDesignerSerializationManager" />
<Parameter Name="owningobject" Type="System.Object" />
<Parameter Name="member" Type="System.ComponentModel.MemberDescriptor" />
</Parameters>
<Docs>
<param name="owningobject">To be added.</param>
<remarks>To be added.</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Serializes the given member on the given object.</para>
</summary>
<returns>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>A <see cref="T:System.CodeDom.CodeStatementCollection" /> representing the serialized state of <paramref name="member" />.</para>
</returns>
<param name="manager">
<attribution license="cc4" from="Microsoft" modified="false" />The serialization manager to use for serialization.</param>
<param name="member">
<attribution license="cc4" from="Microsoft" modified="false" />The member to serialize.</param>
</Docs>
</Member>
<Member MemberName="SerializeMemberAbsolute">
<MemberSignature Language="C#" Value="public virtual System.CodeDom.CodeStatementCollection SerializeMemberAbsolute (System.ComponentModel.Design.Serialization.IDesignerSerializationManager manager, object owningobject, System.ComponentModel.MemberDescriptor member);" />
<MemberType>Method</MemberType>
<AssemblyInfo>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
<ReturnValue>
<ReturnType>System.CodeDom.CodeStatementCollection</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="manager" Type="System.ComponentModel.Design.Serialization.IDesignerSerializationManager" />
<Parameter Name="owningobject" Type="System.Object" />
<Parameter Name="member" Type="System.ComponentModel.MemberDescriptor" />
</Parameters>
<Docs>
<param name="owningobject">To be added.</param>
<remarks>To be added.</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Serializes the given member, accounting for default values.</para>
</summary>
<returns>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>A CodeDom object representing <paramref name="member" />.</para>
</returns>
<param name="manager">
<attribution license="cc4" from="Microsoft" modified="false" />The serialization manager to use for serialization.</param>
<param name="member">
<attribution license="cc4" from="Microsoft" modified="false" />The member to serialize.</param>
</Docs>
</Member>
<Member MemberName="SerializeToReferenceExpression">
<MemberSignature Language="C#" Value="protected System.CodeDom.CodeExpression SerializeToReferenceExpression (System.ComponentModel.Design.Serialization.IDesignerSerializationManager manager, object value);" />
<MemberType>Method</MemberType>
<ReturnValue>
<ReturnType>System.CodeDom.CodeExpression</ReturnType>
</ReturnValue>
<Parameters>
<Parameter Name="manager" Type="System.ComponentModel.Design.Serialization.IDesignerSerializationManager" />
<Parameter Name="value" Type="System.Object" />
</Parameters>
<Docs>
<remarks>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>This method is similar to <see cref="M:System.ComponentModel.Design.Serialization.CodeDomSerializerBase.SerializeToExpression(System.ComponentModel.Design.Serialization.IDesignerSerializationManager,System.Object)" />, except that it stops if it cannot obtain a simple reference expression for the value. Call this method when you expect the resulting expression to be used as a parameter or target of a statement.</para>
</remarks>
<summary>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>Serializes the specified value to a CodeDOM expression.</para>
</summary>
<returns>
<attribution license="cc4" from="Microsoft" modified="false" />
<para>The serialized value. This returns null if no reference expression can be obtained for the specified value, or the value cannot be serialized.</para>
</returns>
<param name="manager">
<attribution license="cc4" from="Microsoft" modified="false" />The serialization manager to use during serialization. </param>
<param name="value">
<attribution license="cc4" from="Microsoft" modified="false" />The object to serialize. </param>
</Docs>
<AssemblyInfo>
<AssemblyVersion>2.0.0.0</AssemblyVersion>
</AssemblyInfo>
<Attributes>
<Attribute>
<AttributeName>System.Obsolete("This method has been deprecated. Use SerializeToExpression or GetExpression instead.")</AttributeName>
</Attribute>
</Attributes>
</Member>
</Members>
</Type>
|