---
name: "std::shared_timed_mutex"
section: "3cxx"
platform: "linux"
package: "libstdc++-12-doc"
version: "12.4.0-5"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/std::shared_timed_mutex/3cxx"
---

# std::shared\_timed\_mutex(3cxx)

The standard shared timed mutex type.

## NAME

std::shared\_timed\_mutex - The standard shared timed mutex type.

## SYNOPSIS

`#include <shared_mutex>`

Inherits \_\_shared\_timed\_mutex\_base.

### Public Member Functions

**shared\_timed\_mutex** (const **shared\_timed\_mutex** &)=**delete**\
 **void** **lock** ()\
 **void** **lock\_shared** ()\
 **shared\_timed\_mutex** & **operator=** (const **shared\_timed\_mutex** &)=**delete**\
 bool **try\_lock** ()\
 template\<**typename** \_Rep , **typename** **\_Period** \> bool **try\_lock\_for** (const **chrono::duration**\< \_Rep, **\_Period** \> &**\_\_rtime**)\
 bool **try\_lock\_shared** ()\
 template\<**typename** \_Rep , **typename** **\_Period** \> bool **try\_lock\_shared\_for** (const **chrono::duration**\< \_Rep, **\_Period** \> &**\_\_rtime**)\
 template\<**typename** **\_Clock** , **typename** **\_Duration** \> bool **try\_lock\_shared\_until** (const **chrono::time\_point**\< **\_Clock**, **\_Duration** \> &**\_\_abs\_time**)\
 template\<**typename** **\_Clock** , **typename** **\_Duration** \> bool **try\_lock\_until** (const **chrono::time\_point**\< **\_Clock**, **\_Duration** \> &**\_\_abs\_time**)\
 **void** **unlock** ()\
 **void** **unlock\_shared** ()\

## Detailed Description

The standard shared timed mutex type.

## Author

Generated automatically by Doxygen for libstdc++ from the source code.
