Java Matcher useTransparentBounds() MethodThe useTransparentBounds(boolean b) method of Matcher class is used to set the transparency of the region bounds for this matcher. If the parameter is true then it will set this matcher to use transparent bounds otherwise the opaque bounds will be used. By default, a matcher uses opaque bounds. SyntaxParametersb - a boolean indicating whether to use opaque or transparent regions Returnsthis matcher Since1.5 Example 1Test it NowOutput of the above program: true Example 2Test it NowOutput of the above program: true java.util.regex.Matcher[pattern=^<abc> region=0,15 lastmatch=<abc>] Example 3Test it NowOutput of the above program: true java.util.regex.Matcher[pattern=<abc>* region=0,15 lastmatch=<abc>] java.util.regex.Matcher[pattern=<abc>* region=0,15 lastmatch=<abc>]
Next TopicJava Matcher
|