Document from file - how better store information about document?

I have a text file that contains information about documents (content from groups than define the document - one row is one document). Every group content from fields (from 10 to 70 in every group). Document consist of 9 groups. In one documen can difference number of groups (> 1 group). E.g. one document can have 3 group1, 2 group6. In another document 2 group9, 1 group 6 and so on. I need to store document in DB and must edit document (by JFrame). To store document I use object MyDocument to store information about document.
3 solutions:
1. Store every group as list from hastables
public class MyDocument {
   private ArrayList<Hashtable<String, String>> group1;
   private ArrayList<Hashtable<String, String>> group2;
   private ArrayList<Hashtable<String, String>> group3;
   private ArrayList<Hashtable<String, String>> group4;
   private ArrayList<Hashtable<String, String>> group5;
   private ArrayList<Hashtable<String, String>> group6;
   private ArrayList<Hashtable<String, String>> group7;
   private ArrayList<Hashtable<String, String>> group8;
   private ArrayList<Hashtable<String, String>> group9; 2. Store all groups as one list from hashtables
public class MyDocument2 {
  private ArrayList<Hashtable<String, String>> allGroups;
} 3. Store groups as lists consist from individual objects (MyDocumentGroup1, MyDocumentGroup2 and so on.)
public class MyDocument3 {
   private ArrayList<MyDocumentGroup1> group1;
   private ArrayList<MyDocumentGroup2> group2;
   private ArrayList<MyDocumentGroup3> group3;
   private ArrayList<MyDocumentGroup4> group4;
   private ArrayList<MyDocumentGroup5> group5;
   private ArrayList<MyDocumentGroup6> group6;
   private ArrayList<MyDocumentGroup7> group7;
   private ArrayList<MyDocumentGroup8> group8;
   private ArrayList<MyDocumentGroup9> group9;
public class MyDocumentGroup1 {
   private ArrayList<Hashtable<String, String>> group1;
public class MyDocumentGroup9 {
   private ArrayList<Hashtable<String, String>> group9;
}What solutions is better? Or maybe has another solution?

Maybe better to store one document in ONE HashMap
public class M2Document {
     private HashMap<String, String> data = null;in the next format:
-------------key ---------value----------
GroupID_FN | some value
where, GroupID is ID of group, FN - field number
example:
-------------key ---------value----------
Group1_1 | some value
Group1_2 | some value
Group2_1 | some value
Group2_2 | some value
Group3_1 | some value
Group3_2 | some value

Similar Messages

  • How to get information about limitation Internal Memory on device

    hallo ..
    have some question here, so please some person able to answer my questions 
    1. How to get Information about limitation internal memory on device 
    2. is possible to improve internal memory on Blackberry ( move apps on external memory )
    3. any tools to get internal memory activity ?
    thanks for this people who joins here, hope we can share more information about blackberry .. 

    In addition...
    There are three types of potential memory on a BB: 1) Application Memory, 2) Device Memory, and 3) Media/SD Card Memory.
    Application Memory -- This is the most crucial; it is the protected (not user accessible), dedicated, and fixed (in size) space that is available as the destination for the installation of applications (plus some application storage, overhead and such). You cannot touch AppMemory. You cannot improve the maximum AppMemory that your BB has. It is what it is. Applications can only install here...there is no option.
    Device Memory -- This is space on your BB that you can touch to store files, pictures, media, etc. Typically, it is not terribly large, but it is available to you.
    SD/Media Card Memory-- This is what it says...your SD card, for you to store files, media, pictures, etc. It can be as large as your BB OS can support...see this KB:
    KB05461MicroSD card sizes supported by the BlackBerry device software
    On some devices/OS levels, you can only see "File Free" (Options > Status), which I think is equivalent to AppMemory. On other devices, you can see all three memory usage levels (Options > Memory). Here are some guidelines to use:
    KB02843What is the Low Memory Manager feature on the BlackBerry smartphone
    KB14320How to maximize free space and battery power on the BlackBerry smartphone
    KB14213Call logs, SMS text messages, and email messages are deleted from the BlackBerry smartphone
    Lastly, it is always important to properly close applications when you are done with them. Using the Back or the Red key will not do this -- those leave it to the app to decide what to do...and some will leave themselves resident in memory, consuming resources on your BB, slowing the overall performance. Rather, to close an app, press and select "Close" or "Exit"...that will force the application to be closed, freeing up for your new use the resources it was consuming. Some apps will always remain running (typically -- BBMessenger, Browser, Homescreen, Phone, and Messages)...but, you should still close them properly - especially the Browser...if it is left on an active web page, it will not only consume extra resources but battery power as well.
    Further, anytime random strange behavior or sluggishness creeps in, the first thing to do is a battery pop reboot. With power ON, remove the back cover and pull out the battery. Wait about a minute then replace the battery and cover. Power up and wait patiently through the long reboot -- ~5 minutes. See if things have returned to good operation. Like all computing devices, BB's suffer from memory leaks and such...with a hard reboot being the best cure. Some have taken to doing this on a regular basis as a preventive measure...some as frequently as once per day. Others have obtained the QuickPull app to automate a simulated Batt-Pull.
    Good luck!
    Occam's Razor nearly always applies when troubleshooting technology issues!
    If anyone has been helpful to you, please show your appreciation by clicking the button inside of their post. Please click here and read, along with the threads to which it links, for helpful information to guide you as you proceed. I always recommend that you treat your BlackBerry like any other computing device, including using a regular backup schedule...click here for an article with instructions.
    Join our BBM Channels
    BSCF General Channel
    PIN: C0001B7B4   Display/Scan Bar Code
    Knowledge Base Updates
    PIN: C0005A9AA   Display/Scan Bar Code

  • HOW TO GET INFORMATION ABOUT THE CLIENT MACHINE AT DATABASE LEVEL

    HOW TO GET INFORMATION ABOUT THE CLIENT MACHINE AT DATABASE LEVEL USING 10g Database and 10g Application Server
    we have developed an application using oracle forms 10g with
    oracle database 10g and Application server 10g
    Application uses a single Oracle User name to connect to database
    where as at Application level there are different users (these are not database users)
    Now how can we get the information about the user/his machine etc. at database level. earlier in 6i/8i we use to get by using
    USERENV('TERMINAL')
    we had written a triggers on tables on Insert/Update where we used to update a database field Last user terminal with USERENV('TERMINAL')
    but not this information is comming to be the machine name of application server where as we wish this to be the machine name of Client. Any Way outs
    thanks
    Chaand Kackria

    hi, you can use the sys_context function, like this:
    select sys_context('userenv','current_user'),
         sys_context('userenv','os_user'),
         sys_context('userenv','host'),
         sys_context('userenv','ip_address'),
         sys_context('userenv','instance'),
         sys_context('userenv','sessionid'),
         sys_context('userenv','terminal')
    from dual;
    Is this what you 're looking for?

  • How to store information in icloud

    Hi all we have just set up the icloud account.  is there any easy to use instructions on how to store information from our computer ie music into icloud.

    Welcome to the Apple Community.
    Your iCloud account is not for storing music, that is done through your iTunes account. Any previous purchases can be redownloaded using iTunes in the cloud (use the purchased section in the iTunes store), or if you subscribe to iTunes match you can store all your library (up to 25,000 tunes) in the cloud.

  • How to get information about creation of a virtual machine on a Hyper-v host.

    Hi,
    How to get information about creation of a virtual machine on a Hyper-v host?
    I need: host name, time created, creator user.
    I saw in Hyper-V-VMMS but I found info about movements of VM between hosts.
    Thank's in advance.
    Denius Valiant

    For Host Name * Created Time Use This Command In PowerShell 
    Get-VM -Name (Read-Host "Type Your Vm Name") |select CreationTime , ComputerName
    and for Create User , As i know you should see on Event Log . 
    Go To Event Log Viewer--->Applications And Services Logs--->Microsoft--->Windows--->Hyper-V-VMMS--->Operational 
    You can see in Event Log who create the Vm.
    Whenever you see a helpful reply, click on Vote As Helpful & click on
    Mark As Answer if a post answers your question.
    LinkedIn:
      Facebook:
      

  • How to get information about cursor? I had only a reference on it.

    Hello
    How to get information about cursor, that I receive in my procedure as a reference. For example I need to know, a number of columns. I know nothing about this cursor, except the link on it.
    Best Regards, Kostya Proskudin!

    However, I would seriously reconsider what you are trying to achieve.
    It looks like you are trying to write some ultimately generic cursor processor. i.e. pass any cursor and process it in some generic way.
    Good design should include knowledge of what is expected to be passed and that knowledge can be put into the code.
    Generic code is inherently difficult to maintain and debug and will never 100% deal with all possible situations e.g. even if you know the table being queried in the cursor you can't rely on the data dictionary to give you all the returned columns if some of the returned columns of the cursor are computed columns.
    Be careful you aren't writing something that's going to cause problems later.

  • How do I save documents from the new Pages into a Word Document

    How do I save documents from the new Pages into a Word Document?

    Thank you so much - so simple!  I had been using the 'share' option (worked in old Pages) and only had icloud or email as options.  I have to attach word documents to emails to send to work. I don't want to use icloud because it's too public and I don't trust it.  Also, you have to be able to access the internet and I need word documents on my USB stick for work where there's no internet.
    I love my Mac but I do wish Apple would remember those of us living in less-than-perfect computer-land.
    Thanks again
    Lindsay

  • HT5649 I have a new iphone 5s and am trying to download already purchased music from file, how do I do this

    I have a new iphone 5s and am trying to download already purchased music from file, how do i do this

    see
    http://support.apple.com/kb/HT2519
    peace, Clyde

  • When I open a pdf document from my dropbox to view it, the document shows up blank, even though it is filled out. This also happened with pdf documents that have been e-mailed to me.

    When I open a pdf document from my dropbox to view it, the document appears blank, even though I know the information is actually there. This also has happened with pdf documents that have been e-mailed to me, then opened to view and they are blank?? Why are they showing up blank?

    When I open emails with PDFs I click on the attachment (doing this all on my iPad) it gives me the option to "open in iBooks", I accept then after that the document is sucked into my iPad but I can't do anything with the PDF after that.  Where is the actual file on my iPad? Why can't I email or send these PDFs to my cloud (Dropbox)?
    It's like once they go into iBooks they're stuck forever.

  • How does Jbuilder store information about user created packages

    Hi ,
    I am new to Jbuilder . I am trying to create a hierarchy of classes, eg:- com.test.first.servlet.abc.java . How do i add this hierarchy to the Jbuilder project. I have manually tried creating folders using New Folder feature, i guess thats not the way its supposed to be done.
    I also opened the .jpx with a wordpad , to see what kinda xml tag is being used to create a package of classes. There is no information about that at all. Right now i am copying a .jpx file, i got from god knows where & editing that for my present project.
    Any suggestions as to whats the right way of creating one !!?
    Thanx b4 hand,
    Maddy

    If you're trying to add an existing java projects source files to a jbuilder project then select the Project Properties dialog from the Project menu. Navigate to the Source tab and add the directory that contains the new source files.
    Dave

  • How to get information about the modules used in the RT system from host pc.

    hi all,
    i am trying to  read the modules of the RT tragets from my host pc without deploying the program.
    i have 2 or more than 2 rt systems from which i am trying to get the information about the modules used in that particular system.
    Regards,
    Santhosh M

    hi, you can use the sys_context function, like this:
    select sys_context('userenv','current_user'),
         sys_context('userenv','os_user'),
         sys_context('userenv','host'),
         sys_context('userenv','ip_address'),
         sys_context('userenv','instance'),
         sys_context('userenv','sessionid'),
         sys_context('userenv','terminal')
    from dual;
    Is this what you 're looking for?

  • How to get information about PowerPivot options

    I was going through the Custom Xml structure present after unzipping a PowerPivot enabled excel file.
    My main motive is to extract information pertaining to PowerPivot options present in the Excel File.
    It had around 16- 19 Custom Xmls, I had a little confusion and it would be great if you could help me on this :
    1. In the workbook.xml.rels file, there is entry for each Cutomxml file. For ex. –
    But according to my interpretation, each of these entries must be referenced also. What i mean is that the specific Rel ID i.e. rId30 (for the above entry) must be referred somewhere in the package that is why it is mentioned in the Workbook.xml.rels.
    But i couldn’t find it anywhere. So how does Excel does all the mapping that which Custom XML is referred to?
    2. I found out that for each table in the PowerPivot window, there is a Custom XML present in the Custom XML’s folder.
    But, there are other field also present such as ‘ColumnFormat’, ‘ColumnNegativePattern’, but these are not getting updated whenever I am changing these for any table.
    I can get the Column names of the table but how can i find out what Format has been applied to the Column of the tables.
    3. Moreover, I found a bunch of Custom XML’s but couldn’t really make sense out of them that what they were pointing to.
    For ex. – CustomXml with namespace – Gemini xmlns=”http://gemini/pivotcustomization/a1265ca3-5c9c-4281-be48-a1a026385b0a”
    or “Gemini xmlns=”http://gemini/pivotcustomization/IsSandboxEmbedded””
    It would be highly beneficial if you can help with these namespaces and their interpretation.
    4. I understand that majority information is present in the database i.e. Item.data file and also in the Temp folders when the file is opened.
    I got through some files present in the Temp Folder and could get my hands on information about Column Format, Formula in case of Calculated Columns. But how do I find out the exact path for the Temp folder every time I open the file.
    I could find some paths in the Item.data file in the BackUpFile nodes but those didn’t exist.
    So is there is any way by which I can get those paths.
    Sorry if the query is a little long, but I am actually stuck with the above questions acting as bottleneck.
    Thanks a lot!!
    Sahil Puri

    What version of Power Pivot are you on?
    Thanks!
    Ed Price, Azure & Power BI Customer Program Manager (Blog,
    Small Basic,
    Wiki Ninjas,
    Wiki)
    Answer an interesting question?
    Create a wiki article about it!

  • I have text documents in my email folders which I can't open.They are PDF files and Open Office files.How do I open these documents or type additional text documents?

    I have text documents in my email folders which I can't open. They are PDF files and Open Office documents. How do I open these documents?

    These are the "out of the box" file formats that you can view on the iPad as mail attachments. If the file is not listed here, you cannot view it without a compatible third party app. What is the file extension?
    Viewable document types: .jpg, .tiff, .gif (images); .doc and .docx (Microsoft Word); .htm and .html (web pages); .key (Keynote); .numbers (Numbers); .pages (Pages); .pdf (Preview and Adobe Acrobat); .ppt and .pptx (Microsoft PowerPoint); .txt (text); .rtf (rich text format); .vcf (contact information); .xls and .xlsx (Microsoft Excel)

  • Multiple MailAttachment  to File   -   How to store as multiple files ?

    Hi Friends ,
                      Can you please tell me  How to Store as Multiple files which i read as attachements  from Mail Sender Adapter .
                         In My scenario i can able to bring the Multiple attachement in the Paylod using PaylodSwapBean .<b> I wan to store these attachements to a file system.</b>   ie. Whatever attachements i am reading i have to store in a file .             
               For eg., In my scenario i have designed the Data Type as DT_Test--> Row --- > Details .
                     Details can able to hold each line of Each File . One file contains multiple Line data .
                   <b>  If i use Message Transform Bean</b> , first attachement only getting Tranformed rest of them as it is . Not getting tranformed to required format.
                     Please give some suggestions !
    Regards .,
    V.Rangarajan

    Oops didn't observe abt the message transform bean usage... .....
    check with these
    3.2.3 Changing the Name and Type of the Payload................................. 6
    3.2.4 Sending a Mail with Attachment ...................................................... 7
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/9e6c7911-0d01-0010-1aa3-8e1bb1551f05
    SAP Note 793922
    http://help.sap.com/saphelp_nw04s/helpdata/en/2e/bf37423cf7ab04e10000000a1550b0/frameset.htm
    <b>Cheers,
    *RAJ*<b>

  • How to get information about time of triggering and entire time waveform

    I have been trying to capture a certain portion of waveform from Textronix DPO2024 using triggering in Labview. Further, I want to save the the entire triggered waveform (triggered time as one array and triggered signal amplitude as second array)  in .xlxs format.
    With the present setup (screenshot, and output of program attached). I only get the triggered portion of signal, I get time stamp (that I do not want) but require the time array, instead.
    I know there are methods to convert the timestamp to time array. I do not want to use this, as I need to capture the data every 10 ms  or even faster, and this slows the acquisition process.
    Any help will be much appreciated.
    Thanks

    Hi Dennis,
    Thank you for the response.
    Please find the .vi attached. In the case - without triggered, with the information of dt and length of Y, we can determine the time waveform (as calculated using matlab script on right). But in the presence of triggering, neither  the length of waveform nor the start time of triggering is known, so calculating the time waveform is tricky. In addition, since the waveform is continuously changing, and keeping trigger fixed at a particular level,  the length of waveform is also changing in some of the acquisition. So I wanted  a 'simple' method where I can get the time information about the triggered waveform in each acquisition.
    More specifically, I wanted help in regard to getting time array of the triggered signal and save it as a column in excel file.
    Thanks

Maybe you are looking for

  • "Error loading plugins" on sample plugin

    This is happening on a new installation of the Illustrator CS6 and new, out-of-the-box builds of sample plugins. I tried MenuPlay and Annotator in both Debug and Relese with the same error on AI startup. Here is what I do: - open xcode project for a

  • Why when I open a meeting.ics attachment it changes the appointment schedule?

    When I receive an e-mail containing a meeting schedule or appointment and click on the meeting.ics attachment, the appointment opens with an appointment time that is one hour earlier. Yet, when I open the e-mail in G-mail for example, the appointment

  • Batch files

    This probably gets asked regularly, but how do I create a batch file to run a java application? Is there somewhere I can go to get an online tutorial or something? I want to make batch files for both Windows and Linux...

  • Tried to purchase Garageband sounds, and cannot use iTunes gift card.

    I redeemed the code and added the funds to my account, but when I go to purchase from Garageband, it only gives me credit card options. I closed it and retried multiple times and now my account is locked because I signed in too many times and couldn'

  • HT1657 how do I search rental movies on itunes?

    I can't figure out how to search movies available for rental in iTunes.