# PackageManager::Options

<a id="options-7"></a>

# Options

```cpp
#include <icy/pacm/packagemanager.h>

struct Options
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:66](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L66)

Startup configuration for repository endpoints, credentials, and directories.

## Public Attributes

| Return | Name | Description |
|--------|------|-------------|
| `std::string` | [`endpoint`](#endpoint)  | The HTTP server endpoint. |
| `std::string` | [`indexURI`](#indexuri)  | The HTTP server URI for querying packages JSON. |
| `std::string` | [`httpUsername`](#httpusername)  | Username for HTTP basic auth. |
| `std::string` | [`httpPassword`](#httppassword)  | PAssword for HTTP basic auth. |
| `std::string` | [`httpOAuthToken`](#httpoauthtoken)  | Will be used instead of HTTP basic if provided. |
| `std::string` | [`tempDir`](#tempdir)  | Directory where package files will be downloaded and extracted. |
| `std::string` | [`dataDir`](#datadir)  | Directory where package manifests will be kept. |
| `std::string` | [`installDir`](#installdir-2)  | Directory where packages will be installed. |
| `std::string` | [`platform`](#platform)  | Platform (win32, linux, mac) |
| `std::string` | [`checksumAlgorithm`](#checksumalgorithm)  | Checksum algorithm (MDS/SHA1) |
| `bool` | [`clearFailedCache`](#clearfailedcache)  | This flag tells the package manager weather or not to clear the package cache if installation fails. |

---

<a id="endpoint"></a>

### endpoint

```cpp
std::string endpoint
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:68](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L68)

The HTTP server endpoint.

---

<a id="indexuri"></a>

### indexURI

```cpp
std::string indexURI
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:69](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L69)

The HTTP server URI for querying packages JSON.

---

<a id="httpusername"></a>

### httpUsername

```cpp
std::string httpUsername
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:70](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L70)

Username for HTTP basic auth.

---

<a id="httppassword"></a>

### httpPassword

```cpp
std::string httpPassword
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:71](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L71)

PAssword for HTTP basic auth.

---

<a id="httpoauthtoken"></a>

### httpOAuthToken

```cpp
std::string httpOAuthToken
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:72](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L72)

Will be used instead of HTTP basic if provided.

---

<a id="tempdir"></a>

### tempDir

```cpp
std::string tempDir
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:74](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L74)

Directory where package files will be downloaded and extracted.

---

<a id="datadir"></a>

### dataDir

```cpp
std::string dataDir
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:75](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L75)

Directory where package manifests will be kept.

---

<a id="installdir-2"></a>

### installDir

```cpp
std::string installDir
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:76](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L76)

Directory where packages will be installed.

---

<a id="platform"></a>

### platform

```cpp
std::string platform
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:78](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L78)

Platform (win32, linux, mac)

---

<a id="checksumalgorithm"></a>

### checksumAlgorithm

```cpp
std::string checksumAlgorithm
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:79](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L79)

Checksum algorithm (MDS/SHA1)

---

<a id="clearfailedcache"></a>

### clearFailedCache

```cpp
bool clearFailedCache
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:81](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L81)

This flag tells the package manager weather or not to clear the package cache if installation fails.

## Public Methods

| Return | Name | Description |
|--------|------|-------------|
|  | [`Options`](#options-8) `inline` |  |

---

<a id="options-8"></a>

### Options

`inline`

```cpp
inline Options(const std::string & root = getCwd())
```

[Defined in src/pacm/include/icy/pacm/packagemanager.h:84](https://github.com/auscaster/icey/blob/main/src/pacm/include/icy/pacm/packagemanager.h#L84)
