package h;

import java.io.IOException;

/* JADX INFO: compiled from: ForwardingSink.java */
/* JADX INFO: loaded from: classes.dex */
public abstract class g implements r {
    private final r delegate;

    public g(r rVar) {
        if (rVar == null) {
            throw new IllegalArgumentException("delegate == null");
        }
        this.delegate = rVar;
    }

    @Override // h.r, java.io.Closeable, java.lang.AutoCloseable
    public void close() throws IOException {
        this.delegate.close();
    }

    public final r delegate() {
        return this.delegate;
    }

    @Override // h.r, java.io.Flushable
    public void flush() throws IOException {
        this.delegate.flush();
    }

    @Override // h.r
    public t timeout() {
        return this.delegate.timeout();
    }

    public String toString() {
        return getClass().getSimpleName() + "(" + this.delegate.toString() + ")";
    }

    @Override // h.r
    public void write(c cVar, long j2) throws IOException {
        this.delegate.write(cVar, j2);
    }
}
