Sfoglia il codice sorgente

remove some class from Abstraction namespce to Internal.

undefined
Savorboard 7 anni fa
parent
commit
323abb7f4d
7 ha cambiato i file con 43 aggiunte e 38 eliminazioni
  1. +0
    -20
      src/DotNetCore.CAP/Abstractions/ConsumerInvokerContext.cs
  2. +0
    -15
      src/DotNetCore.CAP/Abstractions/IConsumerInvoker.cs
  3. +1
    -1
      src/DotNetCore.CAP/Internal/ConsumerContext.cs
  4. +22
    -0
      src/DotNetCore.CAP/Internal/ConsumerExecutedResult.cs
  5. +2
    -1
      src/DotNetCore.CAP/Internal/ConsumerExecutorDescriptor.cs
  6. +17
    -0
      src/DotNetCore.CAP/Internal/IConsumerInvoker.cs
  7. +1
    -1
      src/DotNetCore.CAP/Internal/IConsumerServiceSelector.cs

+ 0
- 20
src/DotNetCore.CAP/Abstractions/ConsumerInvokerContext.cs Vedi File

@@ -1,20 +0,0 @@
using System;

namespace DotNetCore.CAP.Abstractions
{
/// <summary>
/// a context of consumer invoker.
/// </summary>
public class ConsumerInvokerContext
{
public ConsumerInvokerContext(ConsumerContext consumerContext)
{
ConsumerContext = consumerContext ??
throw new ArgumentNullException(nameof(consumerContext));
}

public ConsumerContext ConsumerContext { get; set; }

public IConsumerInvoker Result { get; set; }
}
}

+ 0
- 15
src/DotNetCore.CAP/Abstractions/IConsumerInvoker.cs Vedi File

@@ -1,15 +0,0 @@
using System.Threading.Tasks;

namespace DotNetCore.CAP.Abstractions
{
/// <summary>
/// Perform user definition method of consumers.
/// </summary>
public interface IConsumerInvoker
{
/// <summary>
/// begin to invoke method.
/// </summary>
Task InvokeAsync();
}
}

src/DotNetCore.CAP/Abstractions/ConsumerContext.cs → src/DotNetCore.CAP/Internal/ConsumerContext.cs Vedi File

@@ -1,6 +1,6 @@
using System;

namespace DotNetCore.CAP.Abstractions
namespace DotNetCore.CAP.Internal
{
/// <summary>
/// A context for consumers, it used to be provider wrapper of method description and received message.

+ 22
- 0
src/DotNetCore.CAP/Internal/ConsumerExecutedResult.cs Vedi File

@@ -0,0 +1,22 @@
using System;
using System.Collections.Generic;
using System.Text;

namespace DotNetCore.CAP.Internal
{
public class ConsumerExecutedResult
{
public ConsumerExecutedResult(object result, string msgId, string callbackName)
{
Result = result;
MessageId = msgId;
CallbackName = callbackName;
}

public object Result { get; set; }

public string MessageId { get; set; }

public string CallbackName { get; set; }
}
}

src/DotNetCore.CAP/Abstractions/ConsumerExecutorDescriptor.cs → src/DotNetCore.CAP/Internal/ConsumerExecutorDescriptor.cs Vedi File

@@ -1,6 +1,7 @@
using System.Reflection;
using DotNetCore.CAP.Abstractions;

namespace DotNetCore.CAP.Abstractions
namespace DotNetCore.CAP.Internal
{
/// <summary>
/// A descriptor of user definition method.

+ 17
- 0
src/DotNetCore.CAP/Internal/IConsumerInvoker.cs Vedi File

@@ -0,0 +1,17 @@
using System.Threading.Tasks;
using DotNetCore.CAP.Abstractions;

namespace DotNetCore.CAP.Internal
{
/// <summary>
/// Perform user definition method of consumers.
/// </summary>
public interface IConsumerInvoker
{
/// <summary>
/// Invoke consumer method whit consumer context.
/// </summary>
/// <param name="context">consumer execute context</param>
Task<ConsumerExecutedResult> InvokeAsync(ConsumerContext context);
}
}

src/DotNetCore.CAP/Abstractions/IConsumerServiceSelector.cs → src/DotNetCore.CAP/Internal/IConsumerServiceSelector.cs Vedi File

@@ -1,6 +1,6 @@
using System.Collections.Generic;

namespace DotNetCore.CAP.Abstractions
namespace DotNetCore.CAP.Internal
{
/// <summary>
/// Defines an interface for selecting an consumer service method to invoke for the current message.

Caricamento…
Annulla
Salva