Class RandomExtensions
Extensions to System.Random in order to randomly generate types and specially formatted strings that assist with testing custom extensions to Lucene.NET.
Inheritance
System.Object
RandomExtensions
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Lucene.Net
Assembly: Lucene.Net.TestFramework.dll
Syntax
public static class RandomExtensions
Methods
| Improve this Doc View SourceNextAnalysisString(Random, Int32, Boolean)
Declaration
public static string NextAnalysisString(this Random random, int maxLength, bool simple)
Parameters
Type | Name | Description |
---|---|---|
System.Random | random | |
System.Int32 | maxLength | |
System.Boolean | simple |
Returns
Type | Description |
---|---|
System.String |
NextFilterStrategy(Random)
Declaration
public static FilteredQuery.FilterStrategy NextFilterStrategy(this Random random)
Parameters
Type | Name | Description |
---|---|---|
System.Random | random |
Returns
Type | Description |
---|---|
Lucene.Net.Search.FilteredQuery.FilterStrategy |
NextSubString(Random, Int32, Boolean)
Declaration
public static string NextSubString(this Random random, int wordLength, bool simple)
Parameters
Type | Name | Description |
---|---|---|
System.Random | random | |
System.Int32 | wordLength | |
System.Boolean | simple |
Returns
Type | Description |
---|---|
System.String |
NextWhitespace(Random, Int32, Int32)
Returns a random string in the specified length range consisting entirely of whitespace characters.
Declaration
public static string NextWhitespace(this Random random, int minLength, int maxLength)
Parameters
Type | Name | Description |
---|---|---|
System.Random | random | |
System.Int32 | minLength | |
System.Int32 | maxLength |
Returns
Type | Description |
---|---|
System.String |