Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 6 of 6 for RegisterCompressor (0.26 sec)

  1. src/archive/zip/register.go

    	if _, dup := decompressors.LoadOrStore(method, dcomp); dup {
    		panic("decompressor already registered")
    	}
    }
    
    // RegisterCompressor registers custom compressors for a specified method ID.
    // The common methods [Store] and [Deflate] are built in.
    func RegisterCompressor(method uint16, comp Compressor) {
    	if _, dup := compressors.LoadOrStore(method, comp); dup {
    		panic("compressor already registered")
    	}
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Oct 13 18:36:46 UTC 2023
    - 3.7K bytes
    - Viewed (0)
  2. src/archive/zip/example_test.go

    	// Create a buffer to write our archive to.
    	buf := new(bytes.Buffer)
    
    	// Create a new zip archive.
    	w := zip.NewWriter(buf)
    
    	// Register a custom Deflate compressor.
    	w.RegisterCompressor(zip.Deflate, func(out io.Writer) (io.WriteCloser, error) {
    		return flate.NewWriter(out, flate.BestCompression)
    	})
    
    	// Proceed to add files to w.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 27 00:22:03 UTC 2016
    - 2K bytes
    - Viewed (0)
  3. src/cmd/distpack/pack.go

    			extra := ""
    			if f.Name != "" {
    				extra = " " + f.Name
    			}
    			log.Fatalf("writing %s%s: %v", name, extra, err)
    		}
    	}()
    
    	zw := zip.NewWriter(out)
    	zw.RegisterCompressor(zip.Deflate, func(out io.Writer) (io.WriteCloser, error) {
    		return flate.NewWriter(out, flate.BestCompression)
    	})
    	for _, f = range a.Files {
    		h := check(zip.FileInfoHeader(f.Info()))
    		h.Name = f.Name
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue May 14 19:41:17 UTC 2024
    - 10.9K bytes
    - Viewed (0)
  4. api/go1.6.txt

    pkg archive/zip, method (*ReadCloser) RegisterDecompressor(uint16, Decompressor)
    pkg archive/zip, method (*Reader) RegisterDecompressor(uint16, Decompressor)
    pkg archive/zip, method (*Writer) RegisterCompressor(uint16, Compressor)
    pkg bufio, method (*Scanner) Buffer([]uint8, int)
    pkg bufio, var ErrFinalToken error
    pkg crypto/tls, const TLS_RSA_WITH_AES_128_GCM_SHA256 = 156
    pkg crypto/tls, const TLS_RSA_WITH_AES_128_GCM_SHA256 uint16
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 13 23:40:13 UTC 2016
    - 12.9K bytes
    - Viewed (0)
  5. src/cmd/vendor/golang.org/x/tools/internal/stdlib/manifest.go

    		{"(*Writer).Copy", Method, 17},
    		{"(*Writer).Create", Method, 0},
    		{"(*Writer).CreateHeader", Method, 0},
    		{"(*Writer).CreateRaw", Method, 17},
    		{"(*Writer).Flush", Method, 4},
    		{"(*Writer).RegisterCompressor", Method, 6},
    		{"(*Writer).SetComment", Method, 10},
    		{"(*Writer).SetOffset", Method, 5},
    		{"Compressor", Type, 2},
    		{"Decompressor", Type, 2},
    		{"Deflate", Const, 0},
    		{"ErrAlgorithm", Var, 0},
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Apr 02 02:20:05 UTC 2024
    - 534.2K bytes
    - Viewed (0)
  6. api/go1.2.txt

    pkg archive/zip, func RegisterCompressor(uint16, Compressor)
    pkg archive/zip, func RegisterDecompressor(uint16, Decompressor)
    pkg archive/zip, method (*File) DataOffset() (int64, error)
    pkg archive/zip, type Compressor func(io.Writer) (io.WriteCloser, error)
    pkg archive/zip, type Decompressor func(io.Reader) io.ReadCloser
    pkg bufio, method (*Reader) Reset(io.Reader)
    pkg bufio, method (*Writer) Reset(io.Writer)
    pkg compress/flate, method (*Writer) Reset(io.Writer)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Oct 18 04:36:59 UTC 2013
    - 1.9M bytes
    - Viewed (0)
Back to top