locked
what is the fastest way to serialize and compress a class? RRS feed

  • Question

  • what is the fastest way to serialize and compress a class?

     

    what are the consideration to be made when a long list of objects(classes) have to be serialized and compressed one after the other?

    Thursday, June 10, 2010 3:35 PM

Answers

All replies

  • what is the fastest way to serialize and compress a class?

     

    what are the consideration to be made when a long list of objects(classes) have to be serialized and compressed one after the other?

    Hi marck68,

    In the case of serializing a series of objects to a file, you must read them back in, in the same order.

    There was a recent thread which gave an example of serialization, I will see if I can find it. :-)

     

    Regards,

    John

    Thursday, June 10, 2010 3:50 PM
  • Take a look at serialization sample tutorial

    http://www.vbdotnetheaven.com/UploadFile/Nimusoft/Serialization105022008052559AM/Serialization1.aspx              http://devcity.net/Articles/113/1/dotnet_serialization.aspx

    kaymaf


    CODE CONVERTER SITE

    http://www.carlosag.net/Tools/CodeTranslator/.

    http://www.developerfusion.com/tools/convert/csharp-to-vb/.

    Thursday, June 10, 2010 4:19 PM
  • Hello marck68,
    Thanks for your post.
    Check the following examples about object serialization and file compression. Hope them helpful.
    (1)http://www.vbdotnetheaven.com/Uploadfile/psingh/ObjectSerializationVbDotNet04202005014407AM/ObjectSerializationVbDotNet.aspx
    (Object Serialization in VB.NET)
    (2)
    http://aspalliance.com/1287_Compression_and_Decompression_of_Files_using_Visual_Basic_2005.all
    (Compression and Decompression of Files using Visual Basic 2005)

    If you have any problems, please feel free to follow up.
    Best regards,
    Liliane


    Please mark the replies as answers if they help and unmark them if they provide no help. Thanks
    Tuesday, June 15, 2010 7:14 AM
  • Depends what kind of object.

    If it is a list of strings then it is not even clever to serialize it first.

    So asking what is the fastest way to go from here to New York, if we don't know where for you here is it is impossible to answer.

    Be aware that a class cannot be serialized, you can only serialize an object where you need the Type (Class)


    Success
    Cor
    Tuesday, June 15, 2010 8:48 AM