Interface IProcessor<T>
The IProcessor interface describes a generic, extensible, processing chain for tasks within the social platform.
Namespace: EPiServer.Social.Common
Assembly: EPiServer.Social.Common.dll
Version: 1.5.4Syntax
public interface IProcessor<T>
Type Parameters
| Name | Description |
|---|---|
| T | Type of data to be processed |
Properties
HasSuccessor
Returns true if this node in the processing chain has a succeeding processor, false otherwise.
Declaration
bool HasSuccessor { get; }
Property Value
| Type | Description |
|---|---|
| System.Boolean |
Successor
Gets the succeeding processor in the chain.
Declaration
IProcessor<T> Successor { get; }
Property Value
| Type | Description |
|---|---|
| IProcessor<T> |
Methods
GetNext()
Returns the next processor in the processor chain.
Declaration
IProcessor<T> GetNext()
Returns
| Type | Description |
|---|---|
| IProcessor<T> | Next processor in the chain |
Process(T)
Processes the specified data, returning a reference to it's post-processed form.
Declaration
T Process(T itemToProcess)
Parameters
| Type | Name | Description |
|---|---|---|
| T | itemToProcess | Data to be processed |
Returns
| Type | Description |
|---|---|
| T | The item in its post-processed form |
Process<TExtension>(Composite<T, TExtension>)
Processes the specified data and its extension, returning a reference to it's post-processed composite.
Declaration
Composite<T, TExtension> Process<TExtension>(Composite<T, TExtension> compositeToProcess)
where TExtension : class
Parameters
| Type | Name | Description |
|---|---|---|
| Composite<T, TExtension> | compositeToProcess | Composite data to be processed |
Returns
| Type | Description |
|---|---|
| Composite<T, TExtension> | The item in its post-processed form |
Type Parameters
| Name | Description |
|---|---|
| TExtension |
SetLast(IProcessor<T>)
Appends the specified processor to the end of the processing chain.
Declaration
IProcessor<T> SetLast(IProcessor<T> processor)
Parameters
| Type | Name | Description |
|---|---|---|
| IProcessor<T> | processor | Processor to be added to the chain |
Returns
| Type | Description |
|---|---|
| IProcessor<T> | Reference to the processor that was appended |
SetNext(IProcessor<T>)
Sets the succeeding processor in the chain.
Declaration
IProcessor<T> SetNext(IProcessor<T> processor)
Parameters
| Type | Name | Description |
|---|---|---|
| IProcessor<T> | processor | Processor to succeed this processor in the chain |
Returns
| Type | Description |
|---|---|
| IProcessor<T> | A reference to the succeeding processor |