Class: Polypass
- Inherits:
-
Object
- Object
- Polypass
- Includes:
- PolypassHelpers
- Defined in:
- lib/polypass.rb,
lib/polypass/version.rb
Overview
The polymorphous password generator
Direct Known Subclasses
Defined Under Namespace
Classes: AlphaNumeric, AlphaSymbol, NaturalLanguage
Constant Summary collapse
- VERSION =
'1.0.0'
Instance Attribute Summary collapse
-
#length ⇒ Object
Returns the value of attribute length.
-
#output_type ⇒ Object
Returns the value of attribute output_type.
Instance Method Summary collapse
-
#initialize(length = 32, output_type = 'stdout') ⇒ Polypass
constructor
A new instance of Polypass.
Methods included from PolypassHelpers
#alphanumeric_chars, #alphasymbol_chars, #output_json, #output_yaml, #random_element, #random_number, #random_sample_chars, #random_sample_set
Constructor Details
#initialize(length = 32, output_type = 'stdout') ⇒ Polypass
Returns a new instance of Polypass.
17 18 19 20 |
# File 'lib/polypass.rb', line 17 def initialize(length = 32, output_type = 'stdout') @length = length.to_i @output_type = output_type.to_s end |
Instance Attribute Details
#length ⇒ Object
Returns the value of attribute length.
15 16 17 |
# File 'lib/polypass.rb', line 15 def length @length end |
#output_type ⇒ Object
Returns the value of attribute output_type.
15 16 17 |
# File 'lib/polypass.rb', line 15 def output_type @output_type end |