Interface IServiceConnector
Connects to an Umbraco service.
Namespace: Umbraco.Cms.Core.Deploy
Assembly: Umbraco.Core.dll
Syntax
public interface IServiceConnector : IDiscoverable
Methods
View SourceCompare(IArtifact, IArtifact, Nullable<ICollection<Difference>>)
Compares two artifacts.
Declaration
bool Compare(IArtifact art1, IArtifact art2, ICollection<Difference>? differences = null)
Parameters
Type | Name | Description |
---|---|---|
IArtifact | art1 | The first artifact. |
IArtifact | art2 | The second artifact. |
System.Nullable<ICollection<Difference>> | differences | A collection of differences to append to, if not |
Returns
Type | Description |
---|---|
System.Boolean | A boolean value indicating whether the artifacts are identical. |
ExpandRangeAsync(UdiRange, CancellationToken)
Expands an UDI range into UDIs.
Declaration
IAsyncEnumerable<Udi> ExpandRangeAsync(UdiRange range, CancellationToken cancellationToken = null)
Parameters
Type | Name | Description |
---|---|---|
UdiRange | range | The UDI range. |
CancellationToken | cancellationToken | The cancellation token. |
Returns
Type | Description |
---|---|
IAsyncEnumerable<Udi> | Returns an |
GetArtifactAsync(Object, IContextCache, CancellationToken)
Gets an artifact.
Declaration
Task<IArtifact> GetArtifactAsync(object entity, IContextCache contextCache, CancellationToken cancellationToken = null)
Parameters
Type | Name | Description |
---|---|---|
System.Object | entity | The entity. |
IContextCache | contextCache | The context cache. |
CancellationToken | cancellationToken | The cancellation token. |
Returns
Type | Description |
---|---|
Task<IArtifact> | A task that represents the asynchronous operation. The task result contains the corresponding artifact. |
GetArtifactAsync(Udi, IContextCache, CancellationToken)
Gets an artifact.
Declaration
Task<IArtifact> GetArtifactAsync(Udi udi, IContextCache contextCache, CancellationToken cancellationToken = null)
Parameters
Type | Name | Description |
---|---|---|
Udi | udi | The entity identifier of the artifact. |
IContextCache | contextCache | The context cache. |
CancellationToken | cancellationToken | The cancellation token. |
Returns
Type | Description |
---|---|
Task<IArtifact> | A task that represents the asynchronous operation. The task result contains the corresponding artifact or |
GetRangeAsync(String, String, String, CancellationToken)
Gets a named range for specified entity type, identifier and selector.
Declaration
Task<NamedUdiRange> GetRangeAsync(string entityType, string sid, string selector, CancellationToken cancellationToken = null)
Parameters
Type | Name | Description |
---|---|---|
System.String | entityType | The entity type. |
System.String | sid | The identifier. |
System.String | selector | The selector. |
CancellationToken | cancellationToken | The cancellation token. |
Returns
Type | Description |
---|---|
Task<NamedUdiRange> | A task that represents the asynchronous operation. The task result contains the named range for the specified entity type, identifier and selector. |
Remarks
This is temporary. At least we thought it would be, in sept. 2016. What day is it now?
At the moment our UI has a hard time returning proper UDIs, mainly because Core's tree do not manage GUIDs but only integers... so we have to provide a way to support it. The string id here can be either a real string (for string UDIs) or an "integer as a string", using the value "-1" to indicate the "root" i.e. an open UDI.
GetRangeAsync(Udi, String, CancellationToken)
Gets a named range for a specified UDI and selector.
Declaration
Task<NamedUdiRange> GetRangeAsync(Udi udi, string selector, CancellationToken cancellationToken = null)
Parameters
Type | Name | Description |
---|---|---|
Udi | udi | The UDI. |
System.String | selector | The selector. |
CancellationToken | cancellationToken | The cancellation token. |
Returns
Type | Description |
---|---|
Task<NamedUdiRange> | A task that represents the asynchronous operation. The task result contains the named range for the specified UDI and selector. |
ProcessAsync(ArtifactDeployState, IDeployContext, Int32, CancellationToken)
Processes an artifact.
Declaration
Task ProcessAsync(ArtifactDeployState state, IDeployContext context, int pass, CancellationToken cancellationToken = null)
Parameters
Type | Name | Description |
---|---|---|
ArtifactDeployState | state | The state of the artifact being deployed. |
IDeployContext | context | The deploy context. |
System.Int32 | pass | The processing pass number. |
CancellationToken | cancellationToken | The cancellation token. |
Returns
Type | Description |
---|---|
Task | A task that represents the asynchronous operation. |
ProcessInitAsync(IArtifact, IDeployContext, CancellationToken)
Initializes processing for an artifact.
Declaration
Task<ArtifactDeployState> ProcessInitAsync(IArtifact artifact, IDeployContext context, CancellationToken cancellationToken = null)
Parameters
Type | Name | Description |
---|---|---|
IArtifact | artifact | The artifact. |
IDeployContext | context | The deploy context. |
CancellationToken | cancellationToken | The cancellation token. |
Returns
Type | Description |
---|---|
Task<ArtifactDeployState> | A task that represents the asynchronous operation. The task result contains the state of an artifact being deployed. |