File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java in General and the fly likes Removing specific line from code Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "Removing specific line from code" Watch "Removing specific line from code" New topic
Author

Removing specific line from code

ron ray chaudhuri
Greenhorn

Joined: Aug 27, 2003
Posts: 7
Hi All,

I am trying to write an Ant task for removing a specific method call from Javascript files.

I presume I would have to use Java for this, but since I'm having to use Jdk 1.3, I cannot use the java.util.regex for my purpose. Can anyone suggest, how I could actually achieve what I want to do?

Thanks in advance,
Ron
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61103
    
  66

Since your question seems to be more about how to write the Java to do this rather than how to make the Ant task out of the Java, I'm moving this to the Java in General(intermediate) forum.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Ian Darwin
author
Ranch Hand

Joined: Aug 03, 2001
Posts: 64
In the First Edition of the Java Cookbook, I used one of the free Apache Regular Expression packages to explain regexes. I think any of these would work with Java 1.3. See jakarta.apache.org and look for either ORO or Regular Expressions.

Ian


Ian Darwin
Many questions are answered in my Java Cookbook, 2nd Edition
ron ray chaudhuri
Greenhorn

Joined: Aug 27, 2003
Posts: 7
HI Ian,

Thanks for your response.

I'm really a novice with regexps. Coud you give some guidance in how to use the jakarta regexp package for my purposes?

Thanks in advance,
Ron
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Removing specific line from code