Snippets tagged “pattern”
5 snippets use this tag.
- Double decimal formatting in JavaJava
To format a double value as a decimal in Java, you can use the DecimalFormat class from the java.text package. Here's an example of how to use it:
- How to extract a substring using regexJava
To extract a substring from a string using a regular expression in Java, you can use the following steps:
- How to Set a Minlength Validation in HTML5HTML
In this snippet, find out what alternative attributes to minlength can be used to set a minlength validation in HTML5. Read our snippet and try examples.
- Regex pattern including all special charactersJava
To create a regular expression that includes all special characters, you can use the following pattern:
- Remove HTML tags from a StringJava
To remove HTML tags from a string, you can use a regular expression to match and replace the tags with an empty string.