Skip to content

Commit f9c9cb5

Browse files
committed
Make provides/requires parameter order consistent with rest of API surface.
1 parent 92f5808 commit f9c9cb5

1 file changed

Lines changed: 12 additions & 12 deletions

File tree

DependencyQueue/DependencyQueue.cs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -99,15 +99,15 @@ public DependencyQueueBuilder<T> CreateBuilder()
9999
/// <param name="value">
100100
/// The object to store in the queue item.
101101
/// </param>
102-
/// <param name="requires">
103-
/// An optional collection of names of the topics that the queue item
104-
/// requires. A name cannot be <see langword="null"/> or empty.
105-
/// </param>
106102
/// <param name="provides">
107103
/// An optional collection of names of the topics that the queue item
108104
/// provides in addition to the specified <paramref name="name"/>. A
109105
/// name cannot be <see langword="null"/> or empty.
110106
/// </param>
107+
/// <param name="requires">
108+
/// An optional collection of names of the topics that the queue item
109+
/// requires. A name cannot be <see langword="null"/> or empty.
110+
/// </param>
111111
/// <returns>
112112
/// The item that was added to the queue.
113113
/// </returns>
@@ -128,23 +128,23 @@ public DependencyQueueBuilder<T> CreateBuilder()
128128
public DependencyQueueItem<T> Enqueue(
129129
string name,
130130
T value,
131-
IEnumerable<string>? requires = null,
132-
IEnumerable<string>? provides = null)
131+
IEnumerable<string>? provides = null,
132+
IEnumerable<string>? requires = null)
133133
{
134134
var item = new DependencyQueueItem<T>(name, value, Comparer);
135135

136-
if (requires is not null)
137-
{
138-
RequireValidNames(requires, nameof(requires));
139-
item.AddRequires(requires);
140-
}
141-
142136
if (provides is not null)
143137
{
144138
RequireValidNames(provides, nameof(provides));
145139
item.AddProvides(provides);
146140
}
147141

142+
if (requires is not null)
143+
{
144+
RequireValidNames(requires, nameof(requires));
145+
item.AddRequires(requires);
146+
}
147+
148148
Enqueue(item);
149149
return item;
150150
}

0 commit comments

Comments
 (0)