See {@link GoogleCloudStorage#listBucketInfo()} for details about expected behavior.
764641
@Override
  public List<GoogleCloudStorageItemInfo> listBucketInfo()
      throws IOException {
    logger.atFine().log("listBucketInfo()");
    List<Bucket> allBuckets = listBucketsInternal();
    List<GoogleCloudStorageItemInfo> bucketInfos = new ArrayList<>(allBuckets.size());
    for (Bucket bucket : allBuckets) {
      bucketInfos.add(new GoogleCloudStorageItemInfo(
          new StorageResourceId(bucket.getName()), bucket.getTimeCreated().getValue(), 0,
          bucket.getLocation(), bucket.getStorageClass()));
    }
    return bucketInfos;
  }
1317073
public void setClusterInfoList(java.util.Collection<ClusterInfo> clusterInfoList) {
        if (clusterInfoList == null) {
            this.clusterInfoList = null;
            return;
        }

        this.clusterInfoList = new java.util.ArrayList<ClusterInfo>(clusterInfoList);
    }
755212
def list_buckets(self, instance):
        
        # Server does not do pagination on listings of this resource.
        # Return an iterator anyway for similarity with other API methods
        response = self._client.get_proto(path='/buckets/' + instance)
        message = rest_pb2.ListBucketsResponse()
        message.ParseFromString(response.content)
        buckets = getattr(message, 'bucket')
        return iter([
            Bucket(bucket, instance, self) for bucket in buckets])
485295
public function checkIntegrityData()
    {
        $prevId = 0;
        $identifier = $this->getIdentifier();

        foreach ($this as $item) {
            $this->checkIdentifierType($item[$identifier]);

            if ($item[$identifier] < $prevId) {
                throw new DataStoreException("This storage type supports only a list ordered by id ASC");
            }

            $prevId = $item[$identifier];
        }

        return true;
    }
1224800
public List<Acl> listDefaultBucketAcls(String bucketName) {
    // [START listDefaultBucketAcls]
    List<Acl> acls = storage.listDefaultAcls(bucketName);
    for (Acl acl : acls) {
      // do something with ACL entry
    }
    // [END listDefaultBucketAcls]
    return acls;
  }
1137213
def _storage_list(args, _):
  
  target = args['object'] if args['object'] else args['bucket']
  project = args['project']
  if target is None:
    return _storage_list_buckets(project, '*')  # List all buckets.

  bucket_name, key = datalab.storage._bucket.parse_name(target)
  if bucket_name is None:
    raise Exception('Cannot list %s; not a valid bucket name' % target)

  if key or not re.search('\?|\*|\[', target):
    # List the contents of the bucket
    if not key:
      key = '*'
    if project:
      # Only list if the bucket is in the project
      for bucket in datalab.storage.Buckets(project_id=project):
        if bucket.name == bucket_name:
          break
      else:
        raise Exception('%s does not exist in project %s' % (target, project))
    else:
      bucket = datalab.storage.Bucket(bucket_name)

    if bucket.exists():
      return _storage_list_keys(bucket, key)
    else:
      raise Exception('Bucket %s does not exist' % target)

  else:
    # Treat the bucket name as a pattern and show matches. We don't use bucket_name as that
    # can strip off wildchars and so we need to strip off gs:// here.
    return _storage_list_buckets(project, target[5:])
1000763
protected void updateApiVersion(KubernetesResourceList list) {
    String version = getApiVersion();
    if (list != null && version != null && version.length() > 0) {
      List items = list.getItems();
      if (items != null) {
        for (Object item : items) {
          if (item instanceof HasMetadata) {
            updateApiVersion((HasMetadata) item);
          }
        }
      }
    }
  }
238121
private void listBlacklistedTrackers() throws IOException {
    ClusterStatus c = jobSubmitClient.getClusterStatus(true);
    Collection<String> trackers = c.getBlacklistedTrackerNames();
    for (String trackerName : trackers) {
      System.out.println(trackerName);
    }
  }
719765
public void markListDelivered(List list)
  {
    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.entry(tc, "markListDelivered", list);

    int len = list.size();
    for (int i = 0; i < len; i++)
    {
      AIValueTick valueTick = (AIValueTick) list.get(i);
      valueTick.setDelivered(true);
    }

    if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
      SibTr.exit(tc, "markListDelivered");

  }
1307782
def list_buckets(self):

        '''
            
        '''

        title = '%s.list_buckets' % self.__class__.__name__
        
        bucket_list = []
        
    # send request to s3
        try:
            response = self.connection.list_buckets()
        except:
            raise AWSConnectionError(title)

    # create list from response
        for bucket in response['Buckets']:
            bucket_list.append(bucket['Name'])

        self.bucket_list = bucket_list
        
        return self.bucket_list
973068
function(list){
            localStorage.setItem(localStorageKey, JSON.stringify(list));
            // if we used a real database, we would likely do the below in a callback
            this.list = list;
            this.trigger(list); // sends the updated list to all listening components (TodoApp)
        }
572346
public List<Friend> getPendingFriendRequests() {
		return getFriends(new Filter<Friend>() {

			public boolean accept(Friend friend) {
				return friend.getFriendStatus() == FriendStatus.ADD_REQUEST_PENDING;
			}
		});
	}
1270551
public List<URI> getCouchbaseBucketURIs() {
        if(!isCouchbaseBucketConfig())
            throw new IllegalStateException("This is not a couchbase bucket configuration.");
        final List<URI> result = new ArrayList<URI>(_address2Ids.size());
        final Matcher matcher = COUCHBASE_BUCKET_NODE_PATTERN.matcher(_memcachedNodes);
        while (matcher.find()) {
            try {
                result.add(new URI(matcher.group()));
            } catch (final URISyntaxException e) {
                throw new RuntimeException(e);
            }
        }
        return result;
    }
500749
def parse_list_buckets(data):
    
    root = S3Element.fromstring('ListBucketsResult', data)

    return [
        Bucket(bucket.get_child_text('Name'),
               bucket.get_localized_time_elem('CreationDate'))
        for buckets in root.findall('Buckets')
        for bucket in buckets.findall('Bucket')
    ]
224568
public void setHsmList(java.util.Collection<String> hsmList) {
        if (hsmList == null) {
            this.hsmList = null;
            return;
        }

        this.hsmList = new com.amazonaws.internal.SdkInternalList<String>(hsmList);
    }
939770
@Override
  public GoogleCloudStorageItemInfo getItemInfo(StorageResourceId resourceId) throws IOException {
    // Get the item from cache.
    GoogleCloudStorageItemInfo item = cache.getItem(resourceId);

    // If it wasn't in the cache, list all the objects in the parent directory and cache them
    // and then retrieve it from the cache.
    if (item == null && resourceId.isStorageObject()) {
      String bucketName = resourceId.getBucketName();
      String objectName = resourceId.getObjectName();
      int lastSlashIndex = objectName.lastIndexOf(PATH_DELIMITER);
      String directoryName =
          lastSlashIndex >= 0 ? objectName.substring(0, lastSlashIndex + 1) : null;
      List<GoogleCloudStorageItemInfo> cachedInDirectory =
          cache.listItems(bucketName, directoryName);
      filter(cachedInDirectory, bucketName, directoryName, PATH_DELIMITER);
      // If there are items already cached in directory, do not prefetch with list requests,
      // because metadata for this directory already could be prefetched
      if (cachedInDirectory.isEmpty()) {
        // make just 1 request to prefetch only 1 page of directory items
        listObjectInfoPage(bucketName, directoryName, PATH_DELIMITER, /* pageToken= */ null);
        item = cache.getItem(resourceId);
      }
    }

    // If it wasn't in the cache and wasn't cached in directory list request
    // then request and cache it directly.
    if (item == null) {
      item = super.getItemInfo(resourceId);
      cache.putItem(item);
    }

    return item;
  }
934260
@Override
  public void waitForBucketEmpty(String bucketName)
      throws IOException {
    Preconditions.checkArgument(!Strings.isNullOrEmpty(bucketName),
        "bucketName must not be null or empty");

    for (int i = 0; i < BUCKET_EMPTY_MAX_RETRIES; i++) {
      // We only need one item to see the bucket is not yet empty.
      List<String> objectNames = listObjectNames(bucketName, null, PATH_DELIMITER, 1);
      if (objectNames.isEmpty()) {
        return;
      }
      try {
        sleeper.sleep(BUCKET_EMPTY_WAIT_TIME_MS);
      } catch (InterruptedException ignored) {
        // Ignore the exception and loop.
      }
    }
    throw new IOException("Internal error: bucket not empty: " + bucketName);
  }