---
name: "ACE_Null_Semaphore"
section: "3"
platform: "linux"
package: "libace-doc"
version: "5.0.7-4"
release: "Debian 2.2 (Potato)"
platforms: ["linux"]
url: "https://new.carta.tech/ACE_Null_Semaphore"
---

# ACE\_Null\_Semaphore(3)

Implement a do nothing ACE\_Semaphore, i.e., all the methods are no ops.

## NAME

ACE\_Null\_Semaphore -  Implement a do nothing ACE\_Semaphore, i.e., all the methods are no ops.

## SYNOPSIS

```
#include <ace/Synch.h>
class ACE_Null_Semaphore
{
  public:
    ACE_Null_Semaphore (
        u_int count = 1,
        int type = USYNC_THREAD,
        LPCTSTR name = 0,
        void * = 0,
        int max = 0x7fffffff
        );
    ~ACE_Null_Semaphore (void);
    int remove (void);
    int acquire (ACE_Time_Value &);
    int acquire (void);
    int tryacquire (void);
    int release (void);
    int release (size_t);
    int acquire_write (void);
    int tryacquire_write (void);
    int acquire_read (void);
    int tryacquire_read (void);
    void dump (void) const;
    ACE_ALLOC_HOOK_DECLARE;
};
```

## DESCRIPTION

Wrappers for various synchronization routines.

## PUBLIC MEMBERS

```
ACE_Null_Semaphore (
    u_int count = 1,
    int type = USYNC_THREAD,
    LPCTSTR name = 0,
    void * = 0,
    int max = 0x7fffffff
    );
```

```
~ACE_Null_Semaphore (void);
```

```
int remove (void);
```

```
int acquire (ACE_Time_Value &);
```

```
int acquire (void);
```

```
int tryacquire (void);
```

```
int release (void);
```

```
int release (size_t);
```

```
int acquire_write (void);
```

```
int tryacquire_write (void);
```

```
int acquire_read (void);
```

```
int tryacquire_read (void);
```

```
void dump (void) const;
```

Dump the state of an object.

```
ACE_ALLOC_HOOK_DECLARE;
```

Declare the dynamic allocation hooks.

## AUTHOR

Doug Schmidt

## LIBRARY

ace
