3 Replies Latest reply: Jan 15, 2013 7:35 AM by 841361 RSS

    Taking Backup of Java Object instance

    984684
      How to take back-up of Java instance and use slave instance across,with out disturbing master backuped copies.
        • 1. Re: Taking Backup of Java Object instance
          TPD-Opitz
          Welcome to the forum.

          could you please use more words to describe your problem?

          bye
          TPD
          • 2. Re: Taking Backup of Java Object instance
            gimbal2
            981681 wrote:
            How to take back-up of Java instance and use slave instance across,with out disturbing master backuped copies.
            Java instance? I'll assume you mean object instance since that is in the title of your post.

            In such a case a 'backup' is a clone, which you can do with the Cloneable interface in Java. In your case I'm guessing it should even be a "deep clone" which is not so easy. But now you know what to Google.
            • 3. Re: Taking Backup of Java Object instance
              841361
              >
              How to take back-up of Java instance and use slave instance across,*with out disturbing master backuped copies.*
              >
              You need a deep copy of your object as also mentioned by gimbal2
              you can create this by the use of object output streams and object input streams , provided the belonging class is serlizable.
              You can write the object on memory or file system, read it back and save it as a master copy.