DockerSdk
the .NET SDK for Docker
Public Member Functions | Properties | List of all members
DockerSdk.Networks.INetwork Interface Reference

Represents a Docker network. More...

Inheritance diagram for DockerSdk.Networks.INetwork:
DockerSdk.Networks.INetworkInfo

Public Member Functions

Task AttachAsync (ContainerReference container, CancellationToken ct=default)
 Attaches the network to a Docker container. More...
 
Task AttachAsync (ContainerReference container, AttachNetworkOptions options, CancellationToken ct=default)
 Attaches the network to a Docker container. More...
 
Task AttachAsync (string container, CancellationToken ct=default)
 Attaches the network to a Docker container. More...
 
Task AttachAsync (string container, AttachNetworkOptions options, CancellationToken ct=default)
 Attaches the network to a Docker container. More...
 
Task< INetworkInfoGetDetailsAsync (CancellationToken ct=default)
 Loads detailed information about the Docker network. More...
 

Properties

NetworkFullId Id [get]
 Gets the networks's full ID. More...
 

Detailed Description

Represents a Docker network.

See also
NetworkInfo

Member Function Documentation

◆ AttachAsync() [1/4]

Task DockerSdk.Networks.INetwork.AttachAsync ( ContainerReference  container,
AttachNetworkOptions  options,
CancellationToken  ct = default 
)

Attaches the network to a Docker container.

Parameters
containerA reference to the container.
optionsOptions for how to perform the operation.
ctA token used to cancel the operation.
Returns
A Task that resolves when the network has been attached.
Exceptions
ArgumentNullExceptionOne or more of the inputs are null.
ArgumentExceptionThe options input has invalid values, such as an IPv6 address in the AttachNetworkOptions.IPv6Address property.
NetworkNotFoundExceptionThe network no longer exists.
ContainerNotFoundExceptionThe indicated container does not exist.
System.Net.Http.HttpRequestExceptionThe request failed due to an underlying issue such as network connectivity, DNS failure, server certificate validation, or timeout.

◆ AttachAsync() [2/4]

Task DockerSdk.Networks.INetwork.AttachAsync ( ContainerReference  container,
CancellationToken  ct = default 
)

Attaches the network to a Docker container.

Parameters
containerA reference to the container.
ctA token used to cancel the operation.
Returns
A Task that resolves when the network has been attached.
Exceptions
ArgumentNullExceptioncontainer is null.
NetworkNotFoundExceptionThe network no longer exists.
ContainerNotFoundExceptionThe indicated container does not exist.
System.Net.Http.HttpRequestExceptionThe request failed due to an underlying issue such as network connectivity, DNS failure, server certificate validation, or timeout.

◆ AttachAsync() [3/4]

Task DockerSdk.Networks.INetwork.AttachAsync ( string  container,
AttachNetworkOptions  options,
CancellationToken  ct = default 
)

Attaches the network to a Docker container.

Parameters
containerA reference to the container.
optionsOptions for how to perform the operation.
ctA token used to cancel the operation.
Returns
A Task that resolves when the network has been attached.
Exceptions
ArgumentNullExceptionOne or more of the inputs are null.
ArgumentExceptionThe options input has invalid values, such as an IPv6 address in the AttachNetworkOptions.IPv6Address property.
NetworkNotFoundExceptionThe network no longer exists.
MalformedReferenceExceptioncontainer is not a well-formed container reference.
ContainerNotFoundExceptionThe indicated container does not exist.
System.Net.Http.HttpRequestExceptionThe request failed due to an underlying issue such as network connectivity, DNS failure, server certificate validation, or timeout.

◆ AttachAsync() [4/4]

Task DockerSdk.Networks.INetwork.AttachAsync ( string  container,
CancellationToken  ct = default 
)

Attaches the network to a Docker container.

Parameters
containerA reference to the container.
ctA token used to cancel the operation.
Returns
A Task that resolves when the network has been attached.
Exceptions
ArgumentNullExceptioncontainer is null.
NetworkNotFoundExceptionThe network no longer exists.
MalformedReferenceExceptioncontainer is not a well-formed container reference.
ContainerNotFoundExceptionThe indicated container does not exist.
System.Net.Http.HttpRequestExceptionThe request failed due to an underlying issue such as network connectivity, DNS failure, server certificate validation, or timeout.

◆ GetDetailsAsync()

Task<INetworkInfo> DockerSdk.Networks.INetwork.GetDetailsAsync ( CancellationToken  ct = default)

Loads detailed information about the Docker network.

Parameters
ctA token used to cancel the operation.
Returns
A Task<TResult> that resolves to the details.
Exceptions
NetworkNotFoundExceptionThe network no longer exists.
System.Net.Http.HttpRequestExceptionThe request failed due to an underlying issue such as network connectivity.

Property Documentation

◆ Id

NetworkFullId DockerSdk.Networks.INetwork.Id
get

Gets the networks's full ID.


The documentation for this interface was generated from the following file: