Back to Dagger

Workspace

docs/static/reference/php/Dagger/Workspace.html

0.20.76.0 KB
Original Source

Workspace

class Workspace extends AbstractObject implements IdAble

A Dagger workspace detected from the current working directory.

Properties

| | $lastQuery | | from AbstractObject |

Methods

__construct(AbstractClient $client, QueryBuilderChain $queryBuilderChain)

No description

from AbstractObject

null|array|string|int|float|bool

queryLeaf(QueryBuilder $leafQueryBuilder, string $leafKey)

No description

from AbstractObject

string

address()

Canonical Dagger address of the workspace directory.

CheckGroup

checks(array|null $include = null)

Return all checks from modules loaded in the workspace.

string

clientId()

The client ID that owns this workspace's host filesystem.

string

configPath()

Path to config.toml relative to the workspace boundary (empty if not initialized).

Directory

directory(string $path, array|null $exclude = null, array|null $include = null, bool|null $gitignore = false)

Returns a Directory from the workspace.

File

file(string $path)

Returns a File from the workspace.

string

findUp(string $name, string|null $from = '.')

Search for a file or directory by walking up from the start path within the workspace.

GeneratorGroup

generators(array|null $include = null)

Return all generators from modules loaded in the workspace.

bool

hasConfig()

Whether a config.toml file exists in the workspace.

AbstractId

id()

A unique identifier for this Workspace.

bool

initialized()

Whether .dagger/config.toml exists.

string

path()

Workspace directory path relative to the workspace boundary.

UpGroup

services(array|null $include = null)

Return all services from modules loaded in the workspace.

Details

in AbstractObject at line 13 __construct(AbstractClient $client, QueryBuilderChain $queryBuilderChain)

No description

Parameters

| AbstractClient | $client | | | QueryBuilderChain | $queryBuilderChain | |

in AbstractObject at line 19 protected null|array|string|int|float|bool queryLeaf(QueryBuilder $leafQueryBuilder, string $leafKey)

No description

Parameters

| QueryBuilder | $leafQueryBuilder | | | string | $leafKey | |

Return Value

| null|array|string|int|float|bool | |

at line 19 string address()

Canonical Dagger address of the workspace directory.

Return Value

| string | |

at line 28 CheckGroup checks(array|null $include = null)

Return all checks from modules loaded in the workspace.

Parameters

| array|null | $include | |

Return Value

| CheckGroup | |

at line 40 string clientId()

The client ID that owns this workspace's host filesystem.

Return Value

| string | |

at line 49 string configPath()

Path to config.toml relative to the workspace boundary (empty if not initialized).

Return Value

| string | |

at line 60 Directory directory(string $path, array|null $exclude = null, array|null $include = null, bool|null $gitignore = false)

Returns a Directory from the workspace.

Relative paths resolve from the workspace directory. Absolute paths resolve from the workspace boundary.

Parameters

| string | $path | | | array|null | $exclude | | | array|null | $include | | | bool|null | $gitignore | |

Return Value

| Directory | |

at line 85 File file(string $path)

Returns a File from the workspace.

Relative paths resolve from the workspace directory. Absolute paths resolve from the workspace boundary.

Parameters

| string | $path | |

Return Value

| File | |

at line 101 string findUp(string $name, string|null $from = '.')

Search for a file or directory by walking up from the start path within the workspace.

Returns the absolute workspace path if found, or null if not found.

Relative start paths resolve from the workspace directory.

The search stops at the workspace boundary and will not traverse above it.

Parameters

| string | $name | | | string|null | $from | |

Return Value

| string | |

at line 114 GeneratorGroup generators(array|null $include = null)

Return all generators from modules loaded in the workspace.

Parameters

| array|null | $include | |

Return Value

| GeneratorGroup | |

at line 126 bool hasConfig()

Whether a config.toml file exists in the workspace.

Return Value

| bool | |

at line 135 AbstractId id()

A unique identifier for this Workspace.

Return Value

| AbstractId | |

at line 144 bool initialized()

Whether .dagger/config.toml exists.

Return Value

| bool | |

at line 153 string path()

Workspace directory path relative to the workspace boundary.

Return Value

| string | |

at line 162 UpGroup services(array|null $include = null)

Return all services from modules loaded in the workspace.

Parameters

| array|null | $include | |

Return Value

| UpGroup | |

Generated by Doctum, a API Documentation generator and fork of Sami.