[]
        
(Showing Draft Content)

FarPoint.Web.Spread.Model.Serializer.SaveObject

SaveObject Method

SaveObject(object, string, string)

Saves an object as XML to a file.

Declaration
public static bool SaveObject(object o, string fileName, string rootElement)
Public Shared Function SaveObject(o As Object, fileName As String, rootElement As String) As Boolean
Parameters
Type Name Description
object o

Object to save (must implement ISerializeSupport)

string fileName

File name to save object to

string rootElement

Name of root XML element

Returns
Type Description
bool

SaveObject(object, Stream, string)

Saves an object as XML to a stream.

Declaration
public static bool SaveObject(object o, Stream stream, string rootElement)
Public Shared Function SaveObject(o As Object, stream As Stream, rootElement As String) As Boolean
Parameters
Type Name Description
object o

Object to save (must implement ISerializeSupport)

Stream stream

Stream to save object to

string rootElement

Name of root XML element

Returns
Type Description
bool

SaveObject(object, Type, string, string)

Saves an object as XML to a file using the specified serialization interface.

Declaration
public static bool SaveObject(object o, Type saveInterface, string fileName, string rootElement)
Public Shared Function SaveObject(o As Object, saveInterface As Type, fileName As String, rootElement As String) As Boolean
Parameters
Type Name Description
object o

Object to save (must implement the specified serialization interface)

Type saveInterface

Serialization interface to use (must be ISerializeSupport, ISerializeSettings, ISerializeData, ISerializeStyles, ISerializeDrawing, or ISerializePresentation)

string fileName

File name to save object to

string rootElement

Name of root XML element

Returns
Type Description
bool

SaveObject(object, Type, string, string, Assembly)

Saves an object as XML to a file using the specified serialization interface.

Declaration
public static bool SaveObject(object o, Type saveInterface, string fileName, string rootElement, Assembly callingAssembly)
Public Shared Function SaveObject(o As Object, saveInterface As Type, fileName As String, rootElement As String, callingAssembly As Assembly) As Boolean
Parameters
Type Name Description
object o

Object to save (must implement the specified serialization interface)

Type saveInterface

Serialization interface to use (must be ISerializeSupport, ISerializeSettings, ISerializeData, ISerializeStyles, ISerializeDrawing, or ISerializePresentation)

string fileName

File name to save object to

string rootElement

Name of root XML element

Assembly callingAssembly

Calling assembly

Returns
Type Description
bool

SaveObject(object, Type, Stream, string)

Saves an object as XML to a stream using the specified serialization interface.

Declaration
public static bool SaveObject(object o, Type saveInterface, Stream stream, string rootElement)
Public Shared Function SaveObject(o As Object, saveInterface As Type, stream As Stream, rootElement As String) As Boolean
Parameters
Type Name Description
object o

Object to save (must implement the specified serialization interface)

Type saveInterface

Serialization interface to use (must be ISerializeSupport, ISerializeSettings, ISerializeData, ISerializeStyles, ISerializeDrawing, or ISerializePresentation)

Stream stream

Stream to save object to

string rootElement

Name of root XML element

Returns
Type Description
bool

SaveObject(object, Type, Stream, string, Assembly)

Saves an object as XML to a stream using the specified serialization interface.

Declaration
public static bool SaveObject(object o, Type saveInterface, Stream stream, string rootElement, Assembly callingAssembly)
Public Shared Function SaveObject(o As Object, saveInterface As Type, stream As Stream, rootElement As String, callingAssembly As Assembly) As Boolean
Parameters
Type Name Description
object o

Object to save (must implement the specified serialization interface)

Type saveInterface

Serialization interface to use (must be ISerializeSupport, ISerializeSettings, ISerializeData, ISerializeStyles, ISerializeDrawing, or ISerializePresentation)

Stream stream

Stream to save object to

string rootElement

Name of root XML element

Assembly callingAssembly

Calling assembly

Returns
Type Description
bool