Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / September 2007

Tip: Looking for answers? Try searching our database.

file Handling

Thread view: 
HESH - 27 Sep 2007 05:52 GMT
hi everyone,

I need a Java Code to extract a string from a file.File contains txt
but i only want to extract the txt after string Object Class. Actually
this file is the file containing classes and attributesbut i only want
to extract class name.
example file text:
object class "class1"mmmmmmmmmmm
mmmmmmmmmmmmmm
mmmmmm
object class "class2"
ghj

I want a string array containing class1,class2.

thnks & regards
maHESH
Knute Johnson - 27 Sep 2007 05:55 GMT
> hi everyone,
>
[quoted text clipped - 13 lines]
> thnks & regards
> maHESH

Look at Pattern and Matcher.

Signature

Knute Johnson
email s/nospam/knute/

Roedy Green - 27 Sep 2007 06:42 GMT
>I want a string array containing class1,class2.

See http://mindprod.com/jgloss/string.html
http://mindprod.com/jgloss/regex.html
to learn how to use the String handling tools.
Signature

Roedy Green Canadian Mind Products
The Java Glossary
http://mindprod.com



Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.