Package paramiko :: Module py3compat
[frames] | no frames]

Module py3compat

source code

Classes
  string_types
str(object='') -> string
  text_type
str(object='') -> string
  bytes
str(object='') -> string
  bytes_types
str(object='') -> string
  integer_types
int(x=0) -> int or long int(x, base=10) -> int or long
  long
Functions
string
input(prompt=...)
Read a string from standard input.
 
bytestring(s) source code
 
byte_ord(c) source code
 
byte_chr(c) source code
 
byte_mask(c, mask) source code
 
b(s, encoding='utf8')
cast unicode or bytes to bytes
source code
 
u(s, encoding='utf8')
cast bytes or unicode to unicode
source code
 
b2s(s) source code
 
is_callable(c) source code
 
next(c) source code
Variables
  PY2 = sys.version_info [0] < 3
  decodebytes = base64.decodebytes
  encodebytes = base64.encodebytes
  StringIO = io.StringIO
  BytesIO = io.BytesIO
  MAXSIZE = sys.maxsize
Function Details

input(prompt=...)

 

Read a string from standard input. The trailing newline is stripped. If the user hits EOF (Unix: Ctl-D, Windows: Ctl-Z+Return), raise EOFError. On Unix, GNU readline is used if enabled. The prompt string, if given, is printed without a trailing newline before reading.

Returns: string