*/
package org.opendaylight.openflowjava.protocol.impl.core.connection;
-import java.util.concurrent.TimeoutException;
+import static java.util.Objects.requireNonNull;
+import com.google.common.cache.Cache;
+import java.util.concurrent.TimeoutException;
import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.protocol.rev130731.OfHeader;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
-import com.google.common.base.Preconditions;
-import com.google.common.cache.Cache;
-
final class ResponseExpectedRpcListener<T extends OfHeader> extends AbstractRpcListener<T> {
private static final Logger LOG = LoggerFactory.getLogger(ResponseExpectedRpcListener.class);
private final Cache<RpcResponseKey, ResponseExpectedRpcListener<?>> cache;
ResponseExpectedRpcListener(final Object message, final String failureInfo,
final Cache<RpcResponseKey, ResponseExpectedRpcListener<?>> cache, final RpcResponseKey key) {
super(message, failureInfo);
- this.cache = Preconditions.checkNotNull(cache);
- this.key = Preconditions.checkNotNull(key);
+ this.cache = requireNonNull(cache);
+ this.key = requireNonNull(key);
}
public void discard() {