---
name: "corelinux_Command"
section: "3"
platform: "linux"
package: "libcorelinux-dev"
version: "0.4.32-5"
release: "Debian 3.1 (Sarge)"
platforms: ["linux"]
url: "https://new.carta.tech/corelinux_Command"
---

# corelinux\_Command(3)

Command captures the semantics of allowing commands to be added as a reverse command type.

## NAME

corelinux::Command - **Command** captures the semantics of allowing commands to be added as a reverse command type.

## SYNOPSIS

`#include <Command.hpp>`

Inherits **corelinux::AbstractCommand**.

Inherited by RestoreCaseCommand, UglyCommand, and UpperCaseCommand.

### Public Member Functions

**Command** (void)\
 *Default Constructor.*  **Command** (**CommandCref**)\
 *Copy constructor.*  **Command** (**AbstractCommandPtr**)\
 *Constructor with reverse command.*  virtual **~Command** (void)\
 *Virtual Destructor.*  **CommandRef** **operator=** (**CommandCref**)\
 *Assignment operator.*  bool **operator==** (**CommandCref**) const \
 *Equality operator.*  virtual **AbstractCommandPtr** **getReverseCommand** (void) const \
 *Retrieves the reverse command.*  virtual void **setReverseCommand** (**AbstractCommandPtr**)\
 *Sets the reverse command pointer to be used by the executeReverse call.*  virtual void **executeReverse** (void)\
 *If theReverseCommand is not null, call its execute method.*

### Protected Attributes

**AbstractCommandPtr** **theReverseCommand**\
 *The infamous reverse command.*

## Detailed Description

**Command** captures the semantics of allowing commands to be added as a reverse command type.

It adds the reverse execution interface along with the storage for the **AbstractCommand** that is considered the reverse.

## Member Function Documentation

### AbstractCommandPtr corelinux::Command::getReverseCommand (void) const` [virtual]`

Retrieves the reverse command. **Returns:**

**AbstractCommand** pointer or NULLPTR

### void corelinux::Command::setReverseCommand (AbstractCommandPtr)` [virtual]`

Sets the reverse command pointer to be used by the executeReverse call. **Parameters:**

*AbstractCommand* pointer to valid command or NULLPTR

## Author

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