Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7128771
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T11:10:23+00:00 2026-05-28T11:10:23+00:00

I have learned a bit on Serialization in java . My basic understanding is

  • 0

I have learned a bit on Serialization in java . My basic understanding is it is a mechanism to persist the state of an object and write it to streams so that we can inflate and use it at any latter point in time or in any other “JVM” where the object was not created .
Now suppose if I have a class A and create an instance of the class A i.e. object a , serialize it and store it in a file “A.ser” . I copy the file to other system and deserialize the file “A.ser” to obtain the persisted state of the object a . But in that case the class definition of A should be present in the other system where I deserialize the object ! Is there any way we can save even the class definition and transport it to the other system , so that the other JVM does not have any idea of what class A is until we deserialize the file obtain the class definition and reconstruct the class over there ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T11:10:24+00:00Added an answer on May 28, 2026 at 11:10 am

    What you describe is a ClassLoader. To be able to load class A in a JVM that doesn’t have A in its classpath, you need to use a ClassLoader to load the class (and its dependencies).

    The ObjectInputSTream would then have to delegate to the custom class loader to resolve its classes.

    See the last post in https://forums.oracle.com/forums/thread.jspa?threadID=1149865 for an example that does that. Spring also has such an ObjectInputStream.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm required to write a JCE provider. I have learned that I need to
I am confused a bit. What I have learned or been told is that
I have learned so much from http://www.summerofnhibernate.com/ nhibernate screen casts that i wonder why
One CSS rule I have learned is that you should use the relative em
So I have learned that that the Microsoft.Jet.OLEDB.4.0 data provider for querying data sources
I have an application that stores images in a database. Now I have learned
All of us who work with relational databases have learned (or are learning) that
I only have a background knowledge of java and C, and a bit of
Recently I have learned the basics concepts of Git. We did use a bit
Very new to AJAX, but have learned a bit from online tutorials. If I

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.