def InsistDstUrlNamesContainer(exp_dst_url, have_existing_dst_container,
                               command_name):
  if ((exp_dst_url.IsFileUrl() and not exp_dst_url.IsDirectory()) or
      (exp_dst_url.IsCloudUrl() and exp_dst_url.IsBucket()
       and not have_existing_dst_container)):
    raise CommandException('Destination URL must name a directory, bucket, '
                           'or bucket\nsubdirectory for the multiple '
                           'source form of the %s command.' % command_name)
Ensures the destination URL names a container.
dataset/ETHPy150Open GoogleCloudPlatform/gsutil/gslib/copy_helper.py/InsistDstUrlNamesContainer