Early Preview
This is currently very much a preview. Please feel free to try things out,
but don't be upset if anything is not yet working. Feedback is welcome over on our
GitHub Dicussions page.
class System.​ComponentModel.​Design.​Serialization.​ComponentSerializationService
Assembly: System.ComponentModel.TypeConverter
Inheritance: object → ComponentSerializationService
Provides the base class for serializing a set of components or serializable objects into a serialization store.
Methods
public
SerializationStore
CreateStore​()
Creates a new <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> .
Returns A new created serialization store.
Deserialize​(SerializationStore store)
Deserializes the given store to produce a collection of objects.
Returns A collection of objects created according to the stored state.
store
The <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to deserialize.
Deserialize​(SerializationStore store,
IContainer container)
Deserializes the given store and populates the given <see cref="T:System.ComponentModel.IContainer" /> with deserialized <see cref="T:System.ComponentModel.IComponent" /> objects.
Returns A collection of objects created according to the stored state.
store
The <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to deserialize.
container
The <see cref="T:System.ComponentModel.IContainer" /> to which <see cref="T:System.ComponentModel.IComponent" /> objects will be added.
public
void
DeserializeTo​(SerializationStore store,
IContainer container)
Deserializes the given <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to the given container.
store
The <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to deserialize.
container
The container to which <see cref="T:System.ComponentModel.IComponent" /> objects will be added.
public
void
DeserializeTo​(SerializationStore store,
IContainer container,
bool validateRecycledTypes)
Deserializes the given <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to the given container, optionally validating recycled types.
store
The <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to deserialize.
container
The container to which <see cref="T:System.ComponentModel.IComponent" /> objects will be added.
validateRecycledTypes
<see langword="true" /> to guarantee that the deserialization will only work if applied to an object of the same type.
public
void
DeserializeTo​(SerializationStore store,
IContainer container,
bool validateRecycledTypes,
bool applyDefaults)
Deserializes the given <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to the given container, optionally applying default property values.
store
The <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to deserialize.
container
The container to which <see cref="T:System.ComponentModel.IComponent" /> objects will be added.
validateRecycledTypes
<see langword="true" /> to guarantee that the deserialization will only work if applied to an object of the same type.
applyDefaults
<see langword="true" /> to indicate that the default property values should be applied.
public
SerializationStore
LoadStore​(IO.​Stream stream)
Loads a <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> from a stream.
Returns A new <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> instance.
stream
The <see cref="T:System.IO.Stream" /> from which the store will be loaded.
public
void
Serialize​(SerializationStore store,
object value)
Serializes the given object to the given <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> .
store
The <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to which the state of <paramref name="value" /> will be written.
value
The object to serialize.
public
void
SerializeAbsolute​(SerializationStore store,
object value)
Serializes the given object, accounting for default property values.
store
The <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to which the state of <paramref name="value" /> will be serialized.
value
The object to serialize.
public
void
SerializeMember​(SerializationStore store,
object owningObject,
MemberDescriptor member)
Serializes the given member on the given object.
store
The <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to which the state of <paramref name="member" /> will be serialized.
owningObject
The object to which <paramref name="member" /> is attached.
member
A <see cref="T:System.ComponentModel.MemberDescriptor" /> specifying the member to serialize.
public
void
SerializeMemberAbsolute​(SerializationStore store,
object owningObject,
MemberDescriptor member)
Serializes the given member on the given object, accounting for the default property value.
store
The <see cref="T:System.ComponentModel.Design.Serialization.SerializationStore" /> to which the state of <paramref name="member" /> will be serialized.
owningObject
The object to which <paramref name="member" /> is attached.
member
The member to serialize.
public
bool
Equals​(object obj)
Inherited from object
protected
void
Finalize​()
Inherited from object
public
int
GetHashCode​()
Inherited from object
protected
object
MemberwiseClone​()
Inherited from object
public
string
ToString​()
Inherited from object