W3cubDocs

/Kotlin

MatchGroup

data class MatchGroup

Represents the results from a single capturing group within a MatchResult of Regex.

Parameters

value - The value of captured group.

range -

The range of indices in the input string where group was captured.

The range property is available on JVM only.

Constructors

<init>

MatchGroup(value: String, range: IntRange)
MatchGroup(value: String)

Represents the results from a single capturing group within a MatchResult of Regex.

Properties

range

val range: IntRange

value

val value: String

© 2010–2018 JetBrains s.r.o.
Licensed under the Apache License, Version 2.0.
https://kotlinlang.org/api/latest/jvm/stdlib/kotlin.text/-match-group/index.html