Top Level Namespace

Defined Under Namespace

Modules: Net

Instance Method Summary collapse

Instance Method Details

#get_commandObject


3557
3558
3559
3560
3561
3562
3563
3564
# File 'lib/net/imap.rb', line 3557

def get_command
  printf("%[email protected]%s> ", $user, $host)
  if line = gets
    return line.strip.split(/\s+/)
  else
    return nil
  end
end

#get_passwordObject


3548
3549
3550
3551
3552
3553
3554
3555
# File 'lib/net/imap.rb', line 3548

def get_password
  print "password: "
  begin
    return _noecho(&:gets).chomp
  ensure
    puts
  end
end

#usageObject


3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
# File 'lib/net/imap.rb', line 3518

def usage
  <<EOF
usage: #{$0} [options] <host>

--help                        print this message
--port=PORT                   specifies port
--user=USER                   specifies user
--auth=AUTH                   specifies auth type
--starttls                    use starttls
--ssl                         use ssl
EOF
end