Module Expr Str Assign NameStore Str ClassDef bases NameLoad body Expr Str decorator_list ClassDef bases NameLoad body Expr Str decorator_list ClassDef bases NameLoad body Expr Str decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Num TryExcept body Assign NameStore Call NameLoad NameLoad handlers ExceptHandler type NameLoad body Raise Call NameLoad BinOpMod Str NameLoad If BoolOpOr CompareLt NameLoad Num CompareGt NameLoad Num body Raise Call NameLoad BinOpMod Str NameLoad Return NameLoad decorator_list
N/A N/A Common library for network ports and protocol handling. N/A __author__ watson@google.com (Tony Watson) Error N/A Exception N/A N/A Base error class. N/A BadPortValue N/A Error N/A N/A Invalid port format. N/A BadPortRange N/A Error N/A N/A Invalid port range. N/A Port N/A N/A port N/A N/A N/A Sanitize a port value.
   
  Args:
    port: a port value

  Returns:
    port: a port value

  Raises:
    BadPortValue: port is not valid integer or string
    BadPortRange: port is outside valid range
   N/A pval -1 N/A N/A N/A pval N/A int port N/A N/A N/A ValueError N/A N/A N/A BadPortValue N/A port %s is not valid. port N/A N/A N/A pval 0 N/A pval 65535 N/A N/A N/A BadPortRange N/A port %s is out of range 0-65535. port N/A pval N/A