Show / Hide Table of Contents

Interface IBlockRepositoryApi

Manages all the blocks stored locally.

Namespace: Ipfs.CoreApi
Assembly: Ipfs.Core.dll
Syntax
public interface IBlockRepositoryApi

Methods

| Improve this Doc View Source

RemoveGarbageAsync(CancellationToken)

Perform a garbage collection sweep on the repo.

Declaration
Task RemoveGarbageAsync(CancellationToken cancel = default(CancellationToken))
Parameters
Type Name Description
CancellationToken cancel

Is used to stop the task. When cancelled, the TaskCanceledException is raised.

Returns
Type Description
Task

TODO: not sure what this should return.

| Improve this Doc View Source

StatisticsAsync(CancellationToken)

Get statistics on the repository.

Declaration
Task<RepositoryData> StatisticsAsync(CancellationToken cancel = default(CancellationToken))
Parameters
Type Name Description
CancellationToken cancel

Is used to stop the task. When cancelled, the TaskCanceledException is raised.

Returns
Type Description
Task<RepositoryData>

A task that represents the asynchronous operation. The task's result is the current RepositoryData.

Remarks

Same as RepositoryAsync(CancellationToken).

| Improve this Doc View Source

VerifyAsync(CancellationToken)

Verify all blocks in repo are not corrupted.

Declaration
Task VerifyAsync(CancellationToken cancel = default(CancellationToken))
Parameters
Type Name Description
CancellationToken cancel

Is used to stop the task. When cancelled, the TaskCanceledException is raised.

Returns
Type Description
Task

TODO: not sure what this should return.

| Improve this Doc View Source

VersionAsync(CancellationToken)

Gets the version number of the repo.

Declaration
Task<string> VersionAsync(CancellationToken cancel = default(CancellationToken))
Parameters
Type Name Description
CancellationToken cancel

Is used to stop the task. When cancelled, the TaskCanceledException is raised.

Returns
Type Description
Task<String>

A task that represents the asynchronous operation. The task's result is the version number of the data block repository.

See Also

IBlockApi
  • Improve this Doc
  • View Source
Back to top Generated by DocFX