Skip to content

Commit 6113018

Browse files
committed
[#1415] Grammatical errors in FreeLeaseQueue
Per review comments.
1 parent 3939643 commit 6113018

File tree

1 file changed

+10
-10
lines changed

1 file changed

+10
-10
lines changed

src/lib/dhcpsrv/free_lease_queue.h

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ namespace dhcp {
4646
/// available lease for the given pool. If the server decides to
4747
/// use this lease, it is removed from this container. Conversely,
4848
/// when the lease expires (and is reclaimed) or is released it is
49-
/// returned to this container so as it can be offered to a
49+
/// returned to this container so it can be offered to a
5050
/// requesting client at some later time.
5151
///
5252
/// The container with free leases is optimized for two use cases.
@@ -129,7 +129,7 @@ class FreeLeaseQueue {
129129
return (ranges_.get<1>().erase(range.start_) > 0);
130130
}
131131

132-
/// @brief Appends an address at the end of the queue for a range.
132+
/// @brief Appends an address to the end of the queue for a range.
133133
///
134134
/// This method is typically called when a lease expires and is reclaimed.
135135
/// The range is not specified by the caller. The method identifies
@@ -140,7 +140,7 @@ class FreeLeaseQueue {
140140
/// false otherwise.
141141
bool append(const asiolink::IOAddress& address);
142142

143-
/// @brief Appends a delegated prefix at the end of the queue for a range.
143+
/// @brief Appends a delegated prefix to the end of the queue for a range.
144144
///
145145
/// This method is typically called when a lease expires and is reclaimed.
146146
/// The range is not specified by the caller. The method identifies
@@ -151,7 +151,7 @@ class FreeLeaseQueue {
151151
/// false otherwise.
152152
bool append(const asiolink::IOAddress& prefix, const uint8_t delegated_length);
153153

154-
/// @brief Appends an address at the end of the queue for a range.
154+
/// @brief Appends an address to the end of the queue for a range.
155155
///
156156
/// This method is typically called upon server startup or reconfiguration.
157157
/// For each address belonging to the pool for which there is no lease
@@ -165,7 +165,7 @@ class FreeLeaseQueue {
165165
/// range or if the given range does not exist.
166166
void append(const AddressRange& range, const asiolink::IOAddress& address);
167167

168-
/// @brief Appends a prefix at the end of the queue for a range.
168+
/// @brief Appends a prefix to the end of the queue for a range.
169169
///
170170
/// This method is typically called upon server startup or reconfiguration.
171171
/// For each delegated prefix belonging to the pool for which there is no
@@ -179,7 +179,7 @@ class FreeLeaseQueue {
179179
/// range or if the given range does not exist.
180180
void append(const PrefixRange& range, const asiolink::IOAddress& prefix);
181181

182-
/// @brief Appends an address or prefix at the end of the queue for a range.
182+
/// @brief Appends an address or prefix to the end of the queue for a range.
183183
///
184184
/// This variant of the @c append method is called upon server startup or
185185
/// reconfiguration. It is considered faster than the overload of this
@@ -347,14 +347,14 @@ class FreeLeaseQueue {
347347
/// @param range range for which the container should be returned.
348348
/// @return Pointer to the container (if found).
349349
/// @throw BadValue if the specified range does not exist.
350-
LeasesPtr getContainer(const AddressRange& range) const;
350+
LeasesPtr getLeases(const AddressRange& range) const;
351351

352352
/// @brief Returns container for a given prefix range.
353353
///
354354
/// @param range range for which the container should be returned.
355355
/// @return Pointer to the container (if found).
356356
/// @throw BadValue if the specified range does not exist.
357-
LeasesPtr getContainer(const PrefixRange& range) const;
357+
LeasesPtr getLeases(const PrefixRange& range) const;
358358

359359
/// @brief Returns container descriptor for a given range index.
360360
///
@@ -365,7 +365,7 @@ class FreeLeaseQueue {
365365
/// returned.
366366
/// @return Range descriptor if found.
367367
/// @throw BadValue if the range with the given index does not exist.
368-
RangeDescriptor getContainerDescriptor(const uint64_t range_index) const;
368+
RangeDescriptor getRangeDescriptor(const uint64_t range_index) const;
369369

370370
/// @brief This is internal implemenation of the @c next and @c pop
371371
/// methods.
@@ -378,7 +378,7 @@ class FreeLeaseQueue {
378378
/// @throw BadValue if the range does not exist.
379379
template<typename RangeType>
380380
asiolink::IOAddress popNextInternal(const RangeType& range, const bool push) {
381-
auto cont = getContainer(range);
381+
auto cont = getLeases(range);
382382
if (cont->empty()) {
383383
return (range.start_.isV4() ? asiolink::IOAddress::IPV4_ZERO_ADDRESS() :
384384
asiolink::IOAddress::IPV6_ZERO_ADDRESS());

0 commit comments

Comments
 (0)