Example usage for com.google.common.collect ImmutableList asList

List of usage examples for com.google.common.collect ImmutableList asList

Introduction

In this page you can find the example usage for com.google.common.collect ImmutableList asList.

Prototype

@Override
    public ImmutableList<E> asList() 

Source Link

Usage

From source file:com.facebook.buck.rules.Manifest.java

@VisibleForTesting
protected static HashCode hashSourcePathGroup(FileHashCache fileHashCache, SourcePathResolver resolver,
        ImmutableList<SourcePath> paths) throws IOException {
    if (paths.size() == 1) {
        return hashSourcePath(paths.asList().get(0), fileHashCache, resolver);
    }/*w w w  .  j a  v  a 2s .  com*/
    Hasher hasher = Hashing.md5().newHasher();
    for (SourcePath path : paths) {
        hasher.putBytes(hashSourcePath(path, fileHashCache, resolver).asBytes());
    }
    return hasher.hash();
}