Sha256: 0d903de783403622949158ad36aec47fc9fd5d094b182c8117acaedda3e525db

Contents?: true

Size: 578 Bytes

Versions: 1

Compression:

Stored size: 578 Bytes

Contents

#### Multiple Captures

This example shows a ```MatchData``` with multiple captures.

```show.rb```:
```ruby
require 'debug_helper'

match_data = /(.)(.)(\d+)(\d)/.match('THX1138.')
DebugHelper.show(match_data, 'My MatchData with named captures')
```

The output shows details of the ```MatchData```.

```show.yaml```:
```yaml
---
MatchData (message='My MatchData with named captures'):
  size: 5
  regexp: !ruby/regexp /(.)(.)(\d+)(\d)/
  to_a:
  - HX1138
  - H
  - X
  - '113'
  - '8'
  captures:
  - H
  - X
  - '113'
  - '8'
  names: []
```

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
debug_helper-1.8.0 markdown/readme/classes/match_data/multiple_captures/show.md