File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -35,7 +35,7 @@ You can also search for groups of regular expressions using parentheses.
35
35
``` tut
36
36
import scala.util.matching.Regex
37
37
38
- val keyValPattern: Regex = "([0-9a-zA-Z-#() ]+): ([0-9a-zA-Z-#() ]+)".r
38
+ val keyValPattern: Regex = "([0-9a-zA-Z- ]+): ([0-9a-zA-Z-#()/. ]+)".r
39
39
40
40
val input: String =
41
41
"""background-color: #A03300;
@@ -53,7 +53,7 @@ for (patternMatch <- keyValPattern.findAllMatchIn(input))
53
53
Here we parse out the keys and values of a String. Each match has a group of sub-matches. Here is the output:
54
54
```
55
55
key: background-color value: #A03300
56
- key: background-image value: url(img
56
+ key: background-image value: url(img/header100.png)
57
57
key: background-position value: top center
58
58
key: background-repeat value: repeat-x
59
59
key: background-size value: 2160px 108px
You can’t perform that action at this time.
0 commit comments