Firstly, I am a beginner in Java, and I have never been into any programming before, so it seems like I need a little help to solve a task. The task is "I've a text file with the size of more than 5 MB, & I need to clear the contents between the strings CATCH_IN and CATCH_OUT, so whenever CATCH_IN and CATCH_OUT are coming, need to clear the contents between them, after clearing this, white space should be there in the text file I guess, and it should also need to be cleared.

Finally , I’m expecting the output would look like below.

MATCH_START;
CHANGE;
PLAY_START
DFSHDG_FDGSDFGFD"FGFSDG@FSAASDF";
SDHDG_SADFASF:"FGFSDG_FGSDG";
SDFASF_FASFFDGFSDSDFA"A";
SDFSAD_FDGFSDG:"GHFDG";
DFADSF_DSFSHDG;
CATCH_IN;
CATCH_OUT;
SDFSAD_FDGFSDG:"GHFDG";
FGSDGGHG:"1033";
GHJGFH:"FSDGSFDFG";
SOURCE:"894";
FGSDFGF:"24";
SEASOFSDGSFDFGL:"FSDGSFDFG";
HGDHGD:"64916";
GFHFDHD:"FSDGSFDFG";
KEY_INDICATOR:"TRUE";
REAL_NOMIFSDGSFDFGL:"FSDGSFDFG";
TIMESTAMP_ATTR:"20.06.14 17:11:28";
TIMESTAMP_VALUES:"20.06.14 17:11:28";
TSERIES_END;
MATCH_START;
CHANGE;
PLAY_START
DFSHDG_FDGSDFGFD"GFSDGSDG@ADSFSF";
SDHDG_SADFASF:"GFSDGSDG_HDG";
SDFASF_FASFFDGFSDSDFA"M";
SDFSAD_FDGFSDG:"GHFDG";
DFADSF_DSFSHDG;
CATCH_IN;

CATCH_OUT;
-------

if follows ............

Like this, I need the output for the entire text file, so please e-mail/post me the entire java code for this task, any help would be much appreciated.

FYI, I'll e-mail the text file if anyone is coming forward to help me out of this. Any help that would be much appreciated.

I have to get it done in one day, so I'll look forward to your reply ASAP.

Please let me know if you need any more information, I will try to do the best to get you that.

Thanks for your time & kind help!!

Recommended Answers

All 3 Replies

DaniWeb Member Rules (which you agreed to when you signed up) include:
"Do provide evidence of having done some work yourself if posting questions from school or work assignments"
http://www.daniweb.com/community/rules

Post what you have done so far and someone will help you from there.

I'm a beginner in Java, so I've got something in the internet search, but nothing will help out. Can u give me the entire code for this, that would be much appreciated.

Can u give me the entire code for this

Maybe you didn't understand first time? This isn't a "we do your homework site". We don't cheat for people.
I'm closing this thread. If you want to show some effort then feel free to start a new thread and post what you have achieved so far. Otherwize, there's nothing for you here.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.