tools/bdconfig/lib/google_hadoop/bdconfig_lib/path_validator.py
def AbsolutePath(path):
  """Validates that the given path is absolute."""
  if path is None:
    # Value is allowed to not be set
    return True
  components = urlparse.urlparse(path)
  if components.scheme:
    raise flags_validators.Error(
        'The given path must not be a url: ' + path)
  elif not os.path.isabs(path):
    raise flags_validators.Error('Path must be absolute: ' + path)
  else:
    return True
Validates that the given path is absolute.
Validates that the given path is absolute.
Validates that the given path is absolute .
def AbsolutePath(path):
  if path is None:
    return True
  components = urlparse.urlparse(path)
  if components.scheme:
    raise flags_validators.Error(
        'The given path must not be a url: ' + path)
  elif not os.path.isabs(path):
    raise flags_validators.Error('Path must be absolute: ' + path)
  else:
    return True
def AbsolutePath ( path ) : if path is None : return True components = urlparse . urlparse ( path ) if components . scheme : raise flags_validators . Error ( 'The given path must not be a url: ' + path ) elif not os . path . isabs ( path ) : raise flags_validators . Error ( 'Path must be absolute: ' + path ) else : return True
Validates that the given path is absolute.
Validates that the given path is absolute .
"""Validates that the given path is absolute.""" # Value is allowed to not be set
path