hi,
I have an text file grouped into records that I need to be parsed into a object. The record is like :
H10000 ( H from header of the record )
I1,name,age,sex (Information1)
C1,text... (Comment 1 for Information1)
....
Cn,text... (Comment n for Information1)
I2,name,age,sex (Information2)
C1,text... (Comment1 for Information2)
....
Cn,text... (Commentn for Information2)
...
In,name,age,sex (Information n)
C1,text... (Comment1 for Information n)
....
Cn,text... (Commentn for Information n)
E1 (End message)
There is a class for each Tag (H,I,C,E) and a Record class that is the superclass for the classes(H,I,C,E) . I need to parse this file and store the informations from the records into a object using generics. For the informations I must use a list. I also need the reverse operation : from object to write to file.
I realize that the code must be written by myself but I would appreciate some general help about how to create the object from file
thanks
I have an text file grouped into records that I need to be parsed into a object. The record is like :
H10000 ( H from header of the record )
I1,name,age,sex (Information1)
C1,text... (Comment 1 for Information1)
....
Cn,text... (Comment n for Information1)
I2,name,age,sex (Information2)
C1,text... (Comment1 for Information2)
....
Cn,text... (Commentn for Information2)
...
In,name,age,sex (Information n)
C1,text... (Comment1 for Information n)
....
Cn,text... (Commentn for Information n)
E1 (End message)
There is a class for each Tag (H,I,C,E) and a Record class that is the superclass for the classes(H,I,C,E) . I need to parse this file and store the informations from the records into a object using generics. For the informations I must use a list. I also need the reverse operation : from object to write to file.
I realize that the code must be written by myself but I would appreciate some general help about how to create the object from file
thanks