class Crypto::Prime::Generator23
Overview
Generates all integers which are greater than 2 and are not divisible by either 2 or 3.
This is a pseudo-prime generator, suitable on checking primality of an integer by brute force method.
Defined in:
crypto/utils/prime.crConstructors
Instance Method Summary
-
#rewind : self
Rewinds the internal position for enumeration.
-
#succ : Int::Signed
returns the next pseudo-prime number, and move the internal position forward.
Instance methods inherited from class Crypto::Prime::PseudoPrimeGenerator
each(&)
each,
next
next,
rewind : self
rewind,
size
size,
succ : Int::Signed
succ,
upper_bound : Int128 | Int16 | Int32 | Int64 | Int8 | Nil
upper_bound,
upper_bound=(ubound : Int128 | Int16 | Int32 | Int64 | Int8 | Nil)
upper_bound=
Constructor methods inherited from class Crypto::Prime::PseudoPrimeGenerator
new(ubound : Int128 | Int16 | Int32 | Int64 | Int8 | Nil = nil)
new
Constructor Detail
Instance Method Detail
def rewind : self
#
Description copied from class Crypto::Prime::PseudoPrimeGenerator
Rewinds the internal position for enumeration.
def succ : Int::Signed
#
Description copied from class Crypto::Prime::PseudoPrimeGenerator
returns the next pseudo-prime number, and move the internal position forward.