Solved

Java Replace-A-Word handler..

Posted on 1997-08-11
1
150 Views
Last Modified: 2006-11-17
I need a simple handler that can replace a word in a text. The built-in replace() function can only replace one char. So actually what I need is a way to enumerate through a plain text in a fast way...?
0
Comment
Question by:lassefar
1 Comment
 
LVL 5

Accepted Solution

by:
msmolyak earned 50 total points
ID: 1224729
Is InputStream something you are looking for. If you have a file you can create a Data inputStram on top of a FileInputStream (or FileRedaer in JDK 1.1) and go though the bytes (or characters) in that file one by one). You can write the result to some OutputStream or (Writer). If the data is in a string, you can
create a StringBufferInputStream (or StringReader). You also have a TokenizerStream which allow you to do some simple parsing of your text.
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Suggested Solutions

This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
Java functions are among the best things for programmers to work with as Java sites can be very easy to read and prepare. Java especially simplifies many processes in the coding industry as it helps integrate many forms of technology and different d…
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now