Use new_ui
for the duration of block
.
SecureRandom.urlsafe_base64 generates a random URL-safe base64 string.
The argument n specifies the length, in bytes, of the random number to be generated. The length of the result string is about 4/3 of n.
If n is not specified or is nil, 16 is assumed. It may be larger in the future.
The boolean argument padding specifies the padding. If it is false or nil, padding is not generated. Otherwise padding is generated. By default, padding is not generated because “=” may be used as a URL delimiter.
The result may contain A-Z, a-z, 0-9, “-” and “_”. “=” is also used if padding is true.
require 'securerandom' SecureRandom.urlsafe_base64 #=> "b4GOKm4pOYU_-BOXcrUGDg" SecureRandom.urlsafe_base64 #=> "UZLdOkzop70Ddx-IJR0ABg" SecureRandom.urlsafe_base64(nil, true) #=> "i0XQ-7gglIsHGV2_BNPrdQ==" SecureRandom.urlsafe_base64(nil, true) #=> "-M8rLhr7JEpJlqFGUMmOxg=="
If a secure random number generator is not available, NotImplementedError
is raised.
See RFC 3548 for the definition of URL-safe base64.
Generates formatted random number from raw random bytes. See Random#rand
.
Filter’s a state’s possibilities to remove any that would not satisfy the requirements in the conflict we’ve just rewound from @param [UnwindDetails] unwind_details details of the conflict just unwound from @return [void]
Attempts to update the existing vertex’s ‘PossibilitySet` with a filtered version @return [void]
@param [DependencyState] state @param [Array] binding_requirements array of requirements @return [Boolean] whether or not the given state has any possibilities
that could satisfy the given requirements
Attempts to activate the current {#possibility} @return [void]
Generates a filtered version of the existing vertex’s ‘PossibilitySet` using the current state’s ‘requirement` @param [Object] vertex existing vertex @return [PossibilitySet] filtered possibility set
Returns the string that is used to insert a space between the tokens in a JSON
string.
Sets space to the string that is used to insert a space between the tokens in a JSON
string.
This integer returns the current depth of data structure nesting.
This sets the maximum level of data structure nesting in the generated JSON
to the integer depth, max_nesting
= 0 if no maximum should be checked.
Generates a valid JSON
document from object obj
and returns the result. If no valid JSON
document can be created this method raises a GeneratorError
exception.
Returns the generator of the group.
See the OpenSSL
documentation for EC_GROUP_get0_generator()
Returns the order of the group.
See the OpenSSL
documentation for EC_GROUP_get_order()
See the OpenSSL
documentation for EC_GROUP_get0_seed()
See the OpenSSL
documentation for EC_GROUP_set_seed()
Closes the tar entry
Is the tar entry closed?