Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OptionsFunc ¶
type OptionsFunc func(*ReadPasswordFromText)
OptionsFunc is a function used to configure ReadPasswordFromText
func WithText ¶
func WithText(text string) OptionsFunc
WithText set the text (password) into the ReadPasswordFromText
type ReadPasswordFromText ¶
type ReadPasswordFromText struct {
// contains filtered or unexported fields
}
ReadPasswordFromText allow to read a password as a plain text
func NewReadPasswordFromText ¶
func NewReadPasswordFromText(options ...OptionsFunc) *ReadPasswordFromText
NewReadPasswordFromText generates a ReadPasswordFromText struct
func (*ReadPasswordFromText) Options ¶
func (s *ReadPasswordFromText) Options(opts ...OptionsFunc)
Options configure the ReadPasswordFromText
func (*ReadPasswordFromText) Read ¶
func (s *ReadPasswordFromText) Read() (string, error)
Read returns a password save the text attribute from the ReadPasswordFromText struct
Click to show internal directories.
Click to hide internal directories.