How to save and restore serialized map?

Hi all,
I have here a Serializable object with a map and some other variables in it.
For distribution reasons I would like to get this object serialised and store it in a file (or just a string to test) and afterwards read it out and unserialize the string to the original object again.
I didn't find it yet, but is anything like this possible?
Many thanks in advance,
Steven

tombatore wrote:
ooookey I just bumped into the ObjectOutputStream class, giving that one a try first ;)How about you give this a try: [http://java.sun.com/docs/books/tutorial/reallybigindex.html]?
And seaching the (web|fora)?
:)

Similar Messages

  • How to save and restore Music from iTunes without using library ?

    Could yous help me please ?
    I use an 60 giga iPod I started to fill it with my CDs without using library, just directly in it, I delete the Music in the library after record to save place on may computer. I have nearly 7 megas of Music stored. To fill 60 Giga it wille takes at least 6 months on my rest time. At the end if i loose my iPod or if stolen or broken or if i want to buy a new iPod of 80 Giga for example to store more Music ? How can i save Music in my iPod on a Hard Disk or DVD and restore on it or on a new one ? Is it possible or not allowed by iTunes to avoid Music copie ?
    Thank you for your help....

    Frank31,
    Syncing music to the iPod is a one-way street, as discussed in this article:
    http://docs.info.apple.com/article.html?artnum=302155
    If you are concerned about using up your computer's hard drive for music, and are using iTunes 7, you might consider creating your library on an external drive if one is available.
    This article discusses creating an alternate iTunes library in another location, such as another drive:
    http://docs.info.apple.com/article.html?artnum=304447
    Thank you,
    Nathan C.

  • How to save and restore a Key?

    Hi,
    I Am working through some example code based on the Sun documentation here:
    http://java.sun.com/j2se/1.4/docs/guide/security/jce/JCERefGuide.html
    Here is part of the program:
            KeyGenerator keygen = KeyGenerator.getInstance("DES");
            SecretKey desKey = keygen.generateKey();
                Cipher desCipher;
            // Create the cipher
            desCipher = Cipher.getInstance("DES/ECB/PKCS5Padding");
            // Initialize the cipher for encryption
            desCipher.init(Cipher.ENCRYPT_MODE, desKey);
            // Our cleartext
            byte[] clearBytes =  "Joe".getBytes("UTF8");
            // Encrypt the cleartext
            byte[] cipherBytes = desCipher.doFinal(clearBytes);
            // Initialize the same cipher for decryption
            desCipher.init(Cipher.DECRYPT_MODE, desKey);
            // Decrypt the ciphertext
            byte[]  decryptedBytes = desCipher.doFinal(cipherBytes);This all works fine. Now, suppose I want to save desKey for future use. (Maybe I want to save my encrypted bytes to a file and decrypt them in the future. Maybe I want to give someone else the key for decrypting cipherBytes. )
    In the Key interface there is a method getEncoded() => byte[] which appears to be a way to save the key as a byte array for future use. However, I don't see how to restore the key from the byte array. That is, I expected a Key interface constructor something like: Key(bytes[], encodedKey). What am I misunderstanding?
    Regards,
    Joe

    >
    This works fine: SecretKey myKey = new SecretKeySpec(rawKey, "DES");
    And indeed it does. Thanks, mut - I learned something new today. (Of course, I feel stupid for not having ever noticed that SKSpec isA SecretKey - but that happens to me allll the time...)
    I couldn't get Grant's code to compile. Seems like
    the SecretKeyFactory class doesn't have a
    method named generateKey (in my 1.4 SDK).
    I replaced generateKey with
    generateSecret which compiled without error,Yup, sorry, I hadn't run the code thru a compiler or I'd've caught that.
    but then when I ran the code the third line threw an
    exception:
    java.security.spec.InvalidKeySpecException:
    Inappropriate key specification
    Any idea what's going on?Interesting. I don't offhand see any way for one to work and the other to fail with the same raw data. Then again, having been wrong twice in one post, I'm feeling abruptly unqualified to comment! ;)
    Will experiment some, and let you know what I find out.

  • How Do I save and restore keywords, categories and tags in PE6?

    I have my photos backed up on an external hard drive, but if and when my hard drive crashes, how do I get back the tags, keywords, categories, etc. that I have used in the PE 6 Organizer?  Can I save them and, if so, when I need to restore this, how do I do that?  How do I reconnect tags, categories, keywords, etc. with photos that I re-import after a hard drive crash?

    John: Many thanks for this help.  I use CS3, but my mom has PE6 and I'm trying to help her.  I'm not as familiar with PE6.
    Again, thanks,
    Mark
    Date: Sat, 12 Sep 2009 13:24:12 -0600
    From: [email protected]
    To: [email protected]
    Subject: How Do I save and restore keywords, categories and tags in PE6?
    PSE keeps your keywords, categories, albums, stacks, version sets, captions, notes, dates, and star ratings in a file in a "catalog folder".  (Do Help > System Info to find the location of your catalog folder).  When you make a backup with the PSE File > Backup command, it copies all your photos and the catalog file into the backup.   When you restore from that backup, it copies that catalog file and all your photos to the location you specify.
    >

  • How to view and restore sharepoint 2013 designer workflows and how to redeploy with newer version to environments

    how to view and restore sharepoint 2013 designer workflows and how to redeploy with newer version to environments
    MCTS Sharepoint 2010, MCAD dotnet, MCPDEA, SharePoint Lead

    Hi,
    In SharePoint Designer 2010, we could not save the workflow as a template directly except the reusable workflow.
    However, in SharePoint Designer 2013, we can just save all the types workflow as a template, then you can import the workflow into the new environment.
    http://blogs.msdn.com/b/workflows_for_product_catalogs/archive/2012/11/02/deploying-a-workflow-on-a-different-server.aspx
    In SharePoint Designer 2013, every time we publish the workflow, we would get a newer version workflow, and the old workflow version would be overwritten.
    So, when you deploy the workflow in the environment, the workflow would the newer version.
    Thanks,
    Jason
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Jason Guo
    TechNet Community Support

  • HT1766 Now, I understand how the backup and restore the backup functions. However, if I don't want to transfer the music that I have on iTunes to my phone, how do I avoid it? How do I not transfer the music or take it out of my iPhone if it is already the

    Now, I understand how the backup and restore the backup features function. However, if I don't want to transfer the music that I have on iTunes to my phone, how do I avoid it? How do I not transfer the music or take it out of my iPhone if it is already there? I really do not want any music on my iPhone because I have an iPod for that. Thanks. Hope someone can help.

    When you connect your phone and start iTunes on the left side you will see your phone listed under devices.Click on te icon next to it that looks like a battery. Click on the music button at the top and uncheck the sync music box.

  • How to backup and restore in sap ECC 6.0  EHP 6 in HANA database

    how to backup and restore in sap ECC 6.0  EHP 6 in HANA database

    Stop loading your interview questions here - otherwise your user ID will be deleted.
    Thread locked!

  • How to save and  move an application

    Hi,
    I have made an application on Oracle Express. How to save and move that to another machine ?
    Many thanks.

    I'm in the process of porting my XE app to a 10.1 instance.
    I created an app export and export file of the schema. Then I installed a client on the same machine so I could connect and I get errors detailed in the end of this thread when attempting to import. Most of the tables are successful however, none of the procedural code goes in. The app export imported fine.
    Now, I can manually copy the objects that remain but only if I can connect to XE and this ability seems to have been lost with the install of the 10.1 client.
    Does anyone know how I can connect to XE using PLSQL Developer or is it indeed possible to connect to XE on a machine that is configured to also connect to a 10.1 remote server? I have installed the 10.1 client into a new Oracle home.
    . importing CODESPEED's objects into PRIMPATH
    IMP-00008: unrecognized statement in the export file:
    IMP-00017: following statement failed with ORACLE error 1950:
    "CREATE TABLE "FOLDER" ("FOLDER_ID" NUMBER NOT NULL ENABLE, "STAFF_ID_CREATE"
    "" NUMBER NOT NULL ENABLE, "STAFF_ID_MODIFY" NUMBER, "FOLDER_NAME" VARCHAR2("
    "100) NOT NULL ENABLE, "FOLDER_CREATED" DATE NOT NULL ENABLE, "FOLDER_MODIFI"
    "ED" DATE NOT NULL ENABLE, "FOLDER_NOTES" CLOB, "FOLDER_OWNER" NUMBER NOT NU"
    "LL ENABLE, "DRA_VERSION_ID" NUMBER, "ASSIGNED" NUMBER NOT NULL ENABLE, ""
    "UNASSIGNED" NUMBER NOT NULL ENABLE, "APPROVED" NUMBER NOT NULL ENABLE, "FOL"
    "DER_STATUS" VARCHAR2(1) NOT NULL ENABLE, "CODING_RULE_SET" NUMBER) PCTFREE"
    " 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 STORAGE(INITIAL 65536 FREELISTS 1 FR"
    "EELIST GROUPS 1 BUFFER_POOL DEFAULT) TABLESPACE "USERS" LOGGING NOCOMPRESS "
    "LOB ("FOLDER_NOTES") STORE AS (TABLESPACE "USERS" ENABLE STORAGE IN ROW CH"
    "UNK 8192 PCTVERSION 10 NOCACHE LOGGING STORAGE(INITIAL 65536 FREELISTS 1 F"
    "REELIST GROUPS 1 BUFFER_POOL DEFAULT))"
    IMP-00003: ORACLE error 1950 encountered
    ORA-01950: no privileges on tablespace 'USERS'
    IMP-00017: following statement failed with ORACLE error 2248:
    "ALTER SESSION SET PLSQL_OPTIMIZE_LEVEL = 2 NLS_LENGTH_SEMANTICS = 'BYTE' PL"
    "SQL_CODE_TYPE = 'INTERPRETED' PLSQL_DEBUG = TRUE PLSQL_WARNINGS = 'DISABLE:"
    "ALL'PLSQL_CCFLAGS = ''"
    IMP-00003: ORACLE error 2248 encountered
    ORA-02248: invalid option for ALTER SESSION
    IMP-00000: Import terminated unsuccessfully
    C:\Documents and Settings\PWin>

  • How to save and edit a Word template and excel??

    How to save and edit a Word template and excel (extension. doc and. xls) in an XE database, which can be opened to allow the document and record all changes made by the user of the palicacion.
      or where it a clear tutorial on this topic.?
    I appreciate your attention and collaboration.
    good day ...

    You should not expect to do this in Oracle. But by .net, it can be fine
    http://www.codeproject.com/Articles/36432/Edit-Microsoft-Word-Document-From-Your-Application

  • How to install and configure "SAP MAPI Service Provider" in 470(basis 620)?

    Hi everyone,
    Requse:
    Send E-mail from SAP and Recive E-mail from MS outlook2003.
    My question:
    How to install and configure "SAP MAPI Service Provider" in 470(basis 620)?
    For example:
    Which setting need to do in R/3 server?
    Which parameters need to select when install 620gui?
    Which setting need to mark in MS outlook2003?
    Thanks and Regards,
    Colin.

    Hi Colin,
    For SAP MAPI read,
    http://help.sap.com/saphelp_46c/helpdata/en/04/81dd4ebf2811d2897f0000e8216438/frameset.htm
    For Sending mail from SAP,
    http://help.sap.com/saphelp_46c/helpdata/en/55/a8b538891b11d2a25a00a0c943858e/frameset.htm
    For Receiving mails read,
    http://help.sap.com/saphelp_nw04/helpdata/en/af/73563c1e734f0fe10000000a114084/frameset.htm
    <b>Which parameters need to select when install 620gui?</b>
    Don't get this question...
    <b>Which setting need to mark in MS outlook2003?</b>
    None
    Regards
    Juan
    Please reward with points if helpful

  • How to download and keep multiple maps using Mac/E...

    I use my mac and this site
    http://nokiamaps.site666.info/
    to download maps via my mac to my E71. It works fine. I can install any map, however, only one map at a time.
    I would be happy if anyone knows and could tell me how to download and keep several maps active using my mac and E71. For example, I would like to have US, Japan and some countries in Europe loaded to my E71.
    I can of course keep several maps on my mac but I want to have them loaded to the E71.
    Can I have several maps loaded in the E7? Where to put the maps (which directory)?

    I do not know if anyone is interested but I have figured out one way to do it. Not the nicest perhaps but it works.
    On my mac I create a directory named MyMaps and then I download the maps I want and put them into directories (one directory per map). I copy using the -r flag, which merges/adds on files.
    For example if MyMaps is empty and I use:
    cp -r Sweden/* MyMaps/
    I will get the Swedish map in MyMaps.
    To add the map of Netherlands I simply do:
    cp -r Netherlands* MyMaps/
    I have now merged the map of Netherlands with the map of Sweden and all maps are in MyMaps. And I can add more maps by running cp -r again. And when I am done, I transfer the directory structure in MyMaps to my E71.
    I had some troubles with the diskcache structure. It worked fine for me to remove everything (all files) in the diskcache. They will be created when I move MyMaps.

  • How to backup and restore iPhone 4

    how to backup and restore iphone 4

    How to back up: http://support.apple.com/kb/HT1766.
    How to restore: http://support.apple.com/kb/ht1414.

  • Please help! I am currently using iPhone 5 and changing to iphone 6 in sometime. I have taken backup of my photos, videos, contacts, notes and whatsapp. The only thing that remains is my iMessage. Can someone tell me how to backup and restore my iMes

    I am currently using iPhone 5 and changing to iphone 6 in sometime. I have taken backup of my photos, videos, contacts, notes and whatsapp. The only thing that remains is my iMessage. Can someone tell me how to backup and restore my iMessages?

    iMessages are backed up in the normal backup of your phone so it will be restored when you restore the backup.

  • Built-in SSH Terminal question on how to save and exit

    Howdy, Heres my question and problem.
    I haven't been able to figure out how to save and exit the editor for the SSH terminal that the mac has. I've read that to save you press control -O hit return and to exit hit control -X but that doesn't seem to be working.
    I'm trying to install imagemagick onto my web server and I get stuck at that point of saving and then exiting.
    can anyone tell me how to save and exit the editor?
    I hold down control press -O i let go of the buttons then i press control -X and it stays at the same editor like nothing happened. I try quitting the terminal and reloading it all but that just causes me to restart and nothing saved. and I actually hit the "-" key should i do that or no?
    heres the instructions I'm following for the imagemagick install.
    (For this next part, if you don't have "pico", you can use "vi" instead)
    $ cd libtiff-lzw-compression-kit
    $ pico Makefile
    change
    TIFFSRCDIR = /tmp/libtiff
    to
    TIFFSRCDIR = ../tiff-v3.5.5
    Then save and exit the Editor $ make install
    $ cd ..
    $ cd tiff-v3.5.5
    $ ./configure
    thanks for any help
    -Ahufs

    ctrl+x (thats both keys at the same time) will invoke the exit of the program. at wich point if youve made changes to the file it will ask you if you want to save the data or not. If yes you need to type yes or y and hit enter... if no then no or n. Then it will ask you what you want the file name to be with the default being whatever the file was that you opend to buffer to work on so in most cases you hit enter again.
    hitting ctrl+o (thats both at the same time again) should write the file out and close the application without prompting i think (i dunno for sure... i always use ctrl+x myself).
    At least thats on the OS X version of pico... your server is probably linux so it may differ although i wouldnt expect it to. my pico bindings have always been the same from Debian to CentOS to Darwin.
    Also i msut ask... why cant you pass the TIFFSRCDIR as an option to ./configure like normal instead of manually editing the make file?

  • Can anyone tell me how to find and restore previously purchased OS updates to my iMac?

    Can anyone tell me how to find and restore previously purchased OS updates to my iMac?

    Please go to the Apple (upper left corner) and click on About this Mac. In the resulting window, click on the numbers underneath until they display the OS version.
    Snow Leopard, Lion, and Mountain Lion are all OS X - they are 10.6, 10.7, and 10.8 respectively. After you get the OS version, click until you get the "Build" number and post that as well.
    If your Mac is from 2010, it most likely came with Snow Leopard. If you purchased Lion, then you should be able to see it under your Purchases in the App Store (not iTunes). But, first, we need to figure out what was installed on your machine after the hard drive replacement.
    Not sure about iPhoto at this point - may have to do with whaever OS version is installed. Check in Applications folder in column view and post back which version of iPhoto you have installed.

Maybe you are looking for

  • How to remove background of a animated GIF file?

    i have revoling rings animated gif file, i want remove its blackgroung and want add plain white backgroung. how to do that? i use PS cs 5

  • Equal Distribution of cost among Cost Centers

    Hi All! My requiremnt is like this: CC          Cost           Equal Distb     Total Value X1          100                         100              x2          200            20           220            x3          300            20           320    

  • *****Can we make charcterstics as a Input ready in the input ready query.**

    Hi experts, Our business requirement as follows. the existing business scenerio is, Master data ( say Product list ) )will comes from CRM , By using the input ready query , we will plan against to that master data by using IP. But my requiment is " t

  • Setting Data Manager Packages Priority

    Hi Experts Is it possible to set the priority of data manager packages, for example, if we have multiple scheduled data manager packages running on a server in different appsets. all of the packages are scheduled to run at different time intervals, b

  • Phone crashed while trying to upgrade to 4

    tried to upgrade to 4 but phone crashed after the download, now the screen has an itunes icon with a arrow poiting to it with a usb cacble under, any idae how to restore? I can only power down & power up now, that image stays the same.