---
name: "mongoc_matcher_match"
section: "3"
platform: "linux"
package: "libmongoc-doc"
version: "1.23.1-1+deb12u3"
release: "Debian 12 (Bookworm)"
platforms: ["linux"]
url: "https://new.carta.tech/mongoc_matcher_match"
---

# mongoc\_matcher\_match(3)

mongoc\_matcher\_match()

## NAME

mongoc\_matcher\_match - mongoc\_matcher\_match()

## SYNOPSIS

```
bool
mongoc_matcher_match (const mongoc_matcher_t *matcher, const bson_t *document);
```

This function will check to see if the query compiled in **matcher** matches **document**.

## DEPRECATED

**WARNING:**

**mongoc\_matcher\_t** is deprecated and will be removed in version 2.0.

## PARAMETERS

- •

  **matcher**: A *mongoc\_matcher\_t*.

- •

  **query**: A *bson\_t* that contains the query.

## RETURNS

**true** if **document** matches the query specification provided to *mongoc\_matcher\_new()*. Otherwise, **false**.

## AUTHOR

MongoDB, Inc

## COPYRIGHT

2017-present, MongoDB, Inc
