# DocTextFinderMatch Class

> A phrase in the document that matched the supplied regular expression along with its associated quad bounding box(es).

- Product: Adobe PDF Library 21
- Language: Modern C++
- Version: 21.2.0
- HTML page: https://docs.datalogics.com/apdfl21/ModernCPP/21.2.0/class/DocTextFinderMatch
- Version index: https://docs.datalogics.com/apdfl21/ModernCPP/21.2.0/llms.txt

```cpp
class DocTextFinderMatch
```

**Namespace:** `datalogics_interface`

## Description

A phrase matching a regular expression, with location information.

**Referenced by:** [`DocTextFinder`](https://docs.datalogics.com/apdfl21/ModernCPP/21.2.0/class/DocTextFinder.md)

**Uses types:** [`DocTextFinderQuadInfo`](https://docs.datalogics.com/apdfl21/ModernCPP/21.2.0/class/DocTextFinderQuadInfo.md)

## Constructors

### DocTextFinderMatch

```cpp
datalogics_interface::DocTextFinderMatch::DocTextFinderMatch()=default
```

*constructor*

Default constructor. Produces an empty match with no quad-info.

### DocTextFinderMatch

```cpp
datalogics_interface::DocTextFinderMatch::DocTextFinderMatch(std::string match_string, std::vector< DocTextFinderQuadInfo > quad_info)
```

*constructor*

**Parameters**

- `match_string` (`std::string`): The text that matched the regular expression.
- `quad_info` ([`std::vector< DocTextFinderQuadInfo >`](https://docs.datalogics.com/apdfl21/ModernCPP/21.2.0/class/DocTextFinderQuadInfo.md)): Bounding-box quads (with page numbers) that cover the matched text; one entry per page the match spans.

Construct a match from the matched text and its bounding boxes.

## Methods

### get_match_string

```cpp
const std::string & datalogics_interface::DocTextFinderMatch::get_match_string() const
```

**Returns:** `const std::string &`

The matched text string from the document.

Gets the text string that matched the regular expression.

### get_quad_info

```cpp
const std::vector< DocTextFinderQuadInfo > & datalogics_interface::DocTextFinderMatch::get_quad_info() const
```

**Returns:** [`const std::vector< DocTextFinderQuadInfo > &`](https://docs.datalogics.com/apdfl21/ModernCPP/21.2.0/class/DocTextFinderQuadInfo.md)

A list of DocTextFinderQuadInfo objects describing where the match is located.

Each DocTextFinderQuadInfo in the returned list contains the page number and bounding box quads for a portion of the matched text.
