Skip to content

Instantly share code, notes, and snippets.

package org.chromedriver;
import java.io.*;
import java.net.URL;
import java.nio.channels.Channels;
import java.nio.channels.ReadableByteChannel;
import java.util.zip.ZipEntry;
import java.util.zip.ZipInputStream;
public class ChromeDriverHelper {
@olecve
olecve / CollectionContains.java
Created August 19, 2013 08:29
Benchmark contains method with jmh HashSet vs ArrayList vs ImmutableList vs ImmutableSet
package benchmark;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableSet;
import com.google.common.collect.Lists;
import com.google.common.collect.Sets;
import org.openjdk.jmh.Main;
import org.openjdk.jmh.annotations.*;
import java.io.IOException;
@olecve
olecve / ContainsBenchmark.java
Created August 19, 2013 08:28
Benchmark contains method with caliper HashSet vs ArrayList vs ImmutableList vs ImmutableSet
import com.google.caliper.BeforeExperiment;
import com.google.caliper.Benchmark;
import com.google.caliper.Param;
import com.google.caliper.runner.CaliperMain;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.Lists;
import com.google.common.collect.Sets;
import com.google.monitoring.runtime.instrumentation.common.com.google.common.collect.ImmutableSet;
import java.util.ArrayList;