Match

scala.util.matching.Regex.Match
See theMatch companion class
object Match

An extractor object for Matches, yielding the matched string.

This can be used to help writing replacer functions when you are not interested in match data. For example:

import scala.util.matching.Regex.Match
"""\w+""".r replaceAllIn ("A simple example.", _ match { case Match(s) => s.toUpperCase })

Attributes

Companion
class
Source
Regex.scala
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Match.type

Members list

Value members

Concrete methods

def unapply(m: Match): Some[String]

Attributes

Source
Regex.scala