Skip to content

Commit 4e3d7d7

Browse files
committed
Finish up XML docs.
1 parent 0538354 commit 4e3d7d7

File tree

3 files changed

+30
-8
lines changed

3 files changed

+30
-8
lines changed

RabbitMQ.AMQP.Client/IPublisher.cs

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ public enum OutcomeState
3333
}
3434

3535
/// <summary>
36-
/// PublishOutcome represents the outcome of a publish operation.
37-
/// It contains the state of the outcome and an error if the outcome is not successful.
36+
/// Represents the outcome of a publish operation.
37+
/// It contains the state of the outcome and an error if the outcome is not successful.
3838
/// </summary>
3939
public class PublishOutcome
4040
{
@@ -44,11 +44,21 @@ public PublishOutcome(OutcomeState state, Error? error)
4444
Error = error;
4545
}
4646

47+
/// <summary>
48+
/// The <see cref="OutcomeState"/>.
49+
/// </summary>
4750
public OutcomeState State { get; }
4851

52+
/// <summary>
53+
/// The <see cref="Error"/>, if any.
54+
/// </summary>
4955
public Error? Error { get; }
5056
}
5157

58+
/// <summary>
59+
/// Represents the result of a publish operation.
60+
/// It contains the <see cref="PublishOutcome"/> and the original <see cref="IMessage"/>.
61+
/// </summary>
5262
public class PublishResult
5363
{
5464
public PublishResult(IMessage message, PublishOutcome outcome)
@@ -63,8 +73,8 @@ public PublishResult(IMessage message, PublishOutcome outcome)
6373
}
6474

6575
/// <summary>
66-
/// Interface for publishing messages to an AMQP broker.
67-
/// Implementations of this interface are expected to be thread-safe.
76+
/// Interface for publishing messages to an AMQP broker.
77+
/// Implementations of this interface are expected to be thread-safe.
6878
/// </summary>
6979
public interface IPublisher : ILifeCycle
7080
{

RabbitMQ.AMQP.Client/Impl/AmqpConsumer.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@
1414

1515
namespace RabbitMQ.AMQP.Client.Impl
1616
{
17+
/// <summary>
18+
/// Implementation of <see cref="IConsumer"/>.
19+
/// </summary>
1720
public class AmqpConsumer : AbstractReconnectLifeCycle, IConsumer
1821
{
1922
private enum PauseStatus

RabbitMQ.AMQP.Client/Impl/AmqpPublisher.cs

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@
1313

1414
namespace RabbitMQ.AMQP.Client.Impl
1515
{
16+
/// <summary>
17+
/// Implementation of <see cref="IPublisher"/>.
18+
/// </summary>
1619
public class AmqpPublisher : AbstractReconnectLifeCycle, IPublisher
1720
{
1821
private readonly AmqpConnection _connection;
@@ -30,6 +33,10 @@ public AmqpPublisher(AmqpConnection connection, string? address, IMetricsReporte
3033
_connection.AddPublisher(_id, this);
3134
}
3235

36+
/// <summary>
37+
/// Open this publisher
38+
/// </summary>
39+
/// <returns>A <see cref="Task"/> representing the async operation.</returns>
3340
public override async Task OpenAsync()
3441
{
3542
try
@@ -91,13 +98,11 @@ await base.OpenAsync()
9198
}
9299

93100
/// <summary>
94-
/// Publishes a message to the broker in an asynchronous manner.
95-
/// The PublishResult is synchronous. In order to increase the performance
96-
/// you can use more tasks to publish messages in parallel
101+
/// Publishes a message to the broker asynchronously.
97102
/// </summary>
98103
/// <param name="message"></param>
99104
/// <param name="cancellationToken"></param>
100-
/// <returns></returns>
105+
/// <returns>A <see cref="Task"/> representating the await-able result of the publish operation.</returns>
101106
/// <exception cref="InvalidOperationException"></exception>
102107
/// <exception cref="NotSupportedException"></exception>
103108
/// <exception cref="PublisherException"></exception>
@@ -201,6 +206,10 @@ void OutcomeCallback(ILink sender, Message inMessage, Outcome outcome, object st
201206
return publishResultTcs.Task;
202207
}
203208

209+
/// <summary>
210+
/// Close this publisher
211+
/// </summary>
212+
/// <returns>A <see cref="Task"/> representing the async operation.</returns>
204213
public override async Task CloseAsync()
205214
{
206215
if (_senderLink is null)

0 commit comments

Comments
 (0)