Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for byteCount (0.03 sec)

  1. samples/guide/src/main/java/okhttp3/recipes/UploadProgress.java

            private long totalBytesWritten = 0L;
            private boolean completed = false;
    
            @Override
            public void write(Buffer source, long byteCount) throws IOException {
              super.write(source, byteCount);
              totalBytesWritten += byteCount;
              progressListener.update(totalBytesWritten, contentLength(), completed);
            }
    
            @Override
            public void close() throws IOException {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Aug 30 17:01:12 UTC 2025
    - 4.2K bytes
    - Viewed (1)
  2. samples/guide/src/main/java/okhttp3/recipes/kt/UploadProgress.kt

              private var completed = false
    
              override fun write(
                source: Buffer,
                byteCount: Long,
              ) {
                super.write(source, byteCount)
                totalBytesWritten += byteCount
                progressListener.update(totalBytesWritten, contentLength(), completed)
              }
    
              override fun close() {
                super.close()
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Aug 30 17:01:12 UTC 2025
    - 3.8K bytes
    - Viewed (0)
  3. docs/recipes.md

                  private var totalBytesWritten: Long = 0
                  private var completed = false
    
                  override fun write(source: Buffer, byteCount: Long) {
                    super.write(source, byteCount)
                    totalBytesWritten += byteCount
                    progressListener.update(totalBytesWritten, contentLength(), completed)
                  }
    
                  override fun close() {
    Registered: Fri Sep 05 11:42:10 UTC 2025
    - Last Modified: Sat Aug 30 17:01:12 UTC 2025
    - 47.8K bytes
    - Viewed (0)
Back to top