A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://scala-lang.org/api/3.x/scala/util/matching/Regex$$Groups$.html below:

Groups

Groups

scala.util.matching.Regex.Groups

An extractor object that yields the groups in the match. Using this extractor rather than the original Regex ensures that the match is not recomputed.

import scala.util.matching.Regex.Groups

val date = """(\d\d\d\d)-(\d\d)-(\d\d)""".r
val text = "The doc spree happened on 2011-07-15."
val day = date replaceAllIn(text, _ match { case Groups(_, month, day) => s"$month/$day" })
Attributes
Source
Regex.scala
Graph
Supertypes
Self type
Members list

Generated with

Copyright (c) 2002-2025, LAMP/EPFL

Copyright (c) 2002-2025, LAMP/EPFL


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4