Skip to content

Commit 59985ee

Browse files
Improve XML documentation (#406)
* Improve XML documentation Co-authored-by: bchavez <bchavez@bitarmory.com>
1 parent 321341a commit 59985ee

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

Source/Bogus/Randomizer.cs

+21-21
Original file line numberDiff line numberDiff line change
@@ -210,8 +210,8 @@ public float Float(float min = 0.0f, float max = 1.0f)
210210
/// <summary>
211211
/// Generate a random byte between 0 and 255.
212212
/// </summary>
213-
/// <param name="min">Min value, default 0</param>
214-
/// <param name="max">Max value, default 255</param>
213+
/// <param name="min">Min value, default byte.MinValue 0</param>
214+
/// <param name="max">Max value, default byte.MaxValue 255</param>
215215
public byte Byte(byte min = byte.MinValue, byte max = byte.MaxValue)
216216
{
217217
return Convert.ToByte(Number(min, max));
@@ -234,8 +234,8 @@ public byte[] Bytes(int count)
234234
/// <summary>
235235
/// Generate a random sbyte between -128 and 127.
236236
/// </summary>
237-
/// <param name="min">Min value, default -128</param>
238-
/// <param name="max">Max value, default 127</param>
237+
/// <param name="min">Min value, default sbyte.MinValue -128</param>
238+
/// <param name="max">Max value, default sbyte.MaxValue 127</param>
239239
public sbyte SByte(sbyte min = sbyte.MinValue, sbyte max = sbyte.MaxValue)
240240
{
241241
return Convert.ToSByte(Number(min, max));
@@ -244,8 +244,8 @@ public sbyte SByte(sbyte min = sbyte.MinValue, sbyte max = sbyte.MaxValue)
244244
/// <summary>
245245
/// Generate a random int between MinValue and MaxValue.
246246
/// </summary>
247-
/// <param name="min">Min value, default MinValue</param>
248-
/// <param name="max">Max value, default MaxValue</param>
247+
/// <param name="min">Min value, default int.MinValue</param>
248+
/// <param name="max">Max value, default int.MaxValue</param>
249249
public int Int(int min = int.MinValue, int max = int.MaxValue)
250250
{
251251
return this.Number(min, max);
@@ -254,18 +254,18 @@ public int Int(int min = int.MinValue, int max = int.MaxValue)
254254
/// <summary>
255255
/// Generate a random uint between MinValue and MaxValue.
256256
/// </summary>
257-
/// <param name="min">Min value, default MinValue</param>
258-
/// <param name="max">Max value, default MaxValue</param>
257+
/// <param name="min">Min value, default uint.MinValue</param>
258+
/// <param name="max">Max value, default uint.MaxValue</param>
259259
public uint UInt(uint min = uint.MinValue, uint max = uint.MaxValue)
260260
{
261261
return Convert.ToUInt32(Double() * (max - min) + min);
262262
}
263263

264264
/// <summary>
265-
/// Generate a random ulong between -128 and 127.
265+
/// Generate a random ulong between MinValue and MaxValue.
266266
/// </summary>
267-
/// <param name="min">Min value, default -128</param>
268-
/// <param name="max">Max value, default 127</param>
267+
/// <param name="min">Min value, default ulong.MinValue</param>
268+
/// <param name="max">Max value, default ulong.MaxValue</param>
269269
public ulong ULong(ulong min = ulong.MinValue, ulong max = ulong.MaxValue)
270270
{
271271
return Convert.ToUInt64(Double() * (max - min) + min);
@@ -274,8 +274,8 @@ public ulong ULong(ulong min = ulong.MinValue, ulong max = ulong.MaxValue)
274274
/// <summary>
275275
/// Generate a random long between MinValue and MaxValue.
276276
/// </summary>
277-
/// <param name="min">Min value, default MinValue</param>
278-
/// <param name="max">Max value, default MaxValue</param>
277+
/// <param name="min">Min value, default long.MinValue</param>
278+
/// <param name="max">Max value, default long.MaxValue</param>
279279
public long Long(long min = long.MinValue, long max = long.MaxValue)
280280
{
281281
var range = (decimal)max - min; //use more bits?
@@ -285,8 +285,8 @@ public long Long(long min = long.MinValue, long max = long.MaxValue)
285285
/// <summary>
286286
/// Generate a random short between MinValue and MaxValue.
287287
/// </summary>
288-
/// <param name="min">Min value, default MinValue</param>
289-
/// <param name="max">Max value, default MaxValue</param>
288+
/// <param name="min">Min value, default short.MinValue -32768</param>
289+
/// <param name="max">Max value, default short.MaxValue 32767</param>
290290
public short Short(short min = short.MinValue, short max = short.MaxValue)
291291
{
292292
return Convert.ToInt16(Double() * (max - min) + min);
@@ -295,8 +295,8 @@ public short Short(short min = short.MinValue, short max = short.MaxValue)
295295
/// <summary>
296296
/// Generate a random ushort between MinValue and MaxValue.
297297
/// </summary>
298-
/// <param name="min">Min value, default MinValue</param>
299-
/// <param name="max">Max value, default MaxValue</param>
298+
/// <param name="min">Min value, default ushort.MinValue 0</param>
299+
/// <param name="max">Max value, default ushort.MaxValue 65535</param>
300300
public ushort UShort(ushort min = ushort.MinValue, ushort max = ushort.MaxValue)
301301
{
302302
return Convert.ToUInt16(Double() * (max - min) + min);
@@ -305,8 +305,8 @@ public ushort UShort(ushort min = ushort.MinValue, ushort max = ushort.MaxValue)
305305
/// <summary>
306306
/// Generate a random char between MinValue and MaxValue.
307307
/// </summary>
308-
/// <param name="min">Min value, default MinValue</param>
309-
/// <param name="max">Max value, default MaxValue</param>
308+
/// <param name="min">Min value, default char.MinValue</param>
309+
/// <param name="max">Max value, default char.MaxValue</param>
310310
public char Char(char min = char.MinValue, char max = char.MaxValue)
311311
{
312312
return Convert.ToChar(Number(min, max));
@@ -315,8 +315,8 @@ public char Char(char min = char.MinValue, char max = char.MaxValue)
315315
/// <summary>
316316
/// Generate a random chars between MinValue and MaxValue.
317317
/// </summary>
318-
/// <param name="min">Min value, default MinValue</param>
319-
/// <param name="max">Max value, default MaxValue</param>
318+
/// <param name="min">Min value, default char.MinValue</param>
319+
/// <param name="max">Max value, default char.MaxValue</param>
320320
/// <param name="count">The length of chars to return</param>
321321
public char[] Chars(char min = char.MinValue, char max = char.MaxValue, int count = 5)
322322
{

0 commit comments

Comments
 (0)