remove « replace « Java Regex Q&A

Home
Java Regex Q&A
1.Development
2.find
3.group
4.Match
5.matcher
6.number
7.Operation
8.parse
9.Pattern
10.replace
11.validation
12.word
Java Regex Q&A » replace » remove 

1. Java Regex to remove start/end single quotes but leave inside quotes    stackoverflow.com

I have data from a CSV file that is enclosed in single quotes, like:

'Company name'
'Price: $43.50'
'New York, New York'
I want to be able to replace the single quotes at the start/end ...

2. Java Regex: Replacing full stops with spaces, or removing them if they are part of an abbreviation    stackoverflow.com

I have a series of text fields, which I need to clean of all full stops. The input text is company names, which sometimes contain abbreviations and sometimes full stops ...

3. Java: String.replace(regex, string) to remove content from XML    stackoverflow.com

Lets say I have an XML in the form of a string. I wish to remove the content between two tags within the XML String, say . I have tried:

String newString ...

4. Remove leading zeros with regex but keep minus-sign    stackoverflow.com

I want to replace leading zeros in java with this expression found on this thread: s.replaceFirst("^0+(?!$)", "") But how can I make it work for values like -00.8899?

java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.