RandomUnicode class

Class for the random uncode string generation

Constructors

RandomUnicode([Random? random])
The constructor

Properties

excluded List<RandomUnicodeRange>
List of ranges to exclude
final
hashCode int
The hash code for this object.
no setterinherited
included List<RandomUnicodeRange>
List of ranges to include
final
random Random
Random number generator
latefinal
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

add({bool isIncluded = false, int? min, int? max, List<int>? list, RandomUnicodeRange? range}) → void
Add a set of characters to included or excluded list either as a proper range or as char code(s) converted to the list of the trivial ranges
addExcluded({int? min, int? max, List<int>? list, RandomUnicodeRange? range}) → void
A wrapper for add(isIncluded: false, ...)
addFrom(RandomUnicode other) → void
Add all included and excluded ranges from other object
addIncluded({int? min, int? max, List<int>? list, RandomUnicodeRange? range}) → void
A wrapper for add(isIncluded: true, ...)
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
string(int minLen, [int? maxLen]) String
Generate random string of a given length or or of a random length within the length ramge
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

ascii([Random? random]) RandomUnicode
Helper method to limit random strings to the ASCII set
asciiAlpha([Random? random]) RandomUnicode
Helper method to limit random strings to A-Z and a-z
asciiAlphaNumeric([Random? random]) RandomUnicode
Helper method to limit random strings to 0-9, A-Z and a-z
asciiHexadecimal([Random? random]) RandomUnicode
Helper method to limit random strings to 0-9, A-F and a-f
asciiNumeric([Random? random]) RandomUnicode
Helper method to limit random strings to 0-9
bmp([Random? random]) RandomUnicode
Helper method to limit random strings to the Basic Multilingual Plane
validFileName([Random? random, bool isStrict = false]) RandomUnicode
Helper method to exclude characters not handled by Windows If isStrict is set, then some extra characters excluded to avoid general user problems (on POSIX-compliant systems, all of these characters are allowed)