'Returns True if this URI names a directory or bucket. Will return
False for bucket subdirs; providing bucket subdir semantics needs to
be done by the caller (like gsutil does).'

def names_container(self):

    return bool((not self.object_name))
