Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for BSD (0.13 sec)

  1. src/archive/zip/example_test.go

    // Copyright 2012 The Go Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package zip_test
    
    import (
    	"archive/zip"
    	"bytes"
    	"compress/flate"
    	"fmt"
    	"io"
    	"log"
    	"os"
    )
    
    func ExampleWriter() {
    	// Create a buffer to write our archive to.
    	buf := new(bytes.Buffer)
    
    	// Create a new zip archive.
    	w := zip.NewWriter(buf)
    
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Wed Jan 27 00:22:03 GMT 2016
    - 2K bytes
    - Viewed (0)
  2. src/archive/tar/example_test.go

    // Copyright 2013 The Go Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package tar_test
    
    import (
    	"archive/tar"
    	"bytes"
    	"fmt"
    	"io"
    	"log"
    	"os"
    )
    
    func Example_minimal() {
    	// Create and add some files to the archive.
    	var buf bytes.Buffer
    	tw := tar.NewWriter(&buf)
    	var files = []struct {
    		Name, Body string
    	}{
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Thu Nov 16 16:54:08 GMT 2017
    - 1.4K bytes
    - Viewed (0)
  3. src/bufio/example_test.go

    // Copyright 2013 The Go Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package bufio_test
    
    import (
    	"bufio"
    	"bytes"
    	"fmt"
    	"os"
    	"strconv"
    	"strings"
    )
    
    func ExampleWriter() {
    	w := bufio.NewWriter(os.Stdout)
    	fmt.Fprint(w, "Hello, ")
    	fmt.Fprint(w, "world!")
    	w.Flush() // Don't forget to flush!
    	// Output: Hello, world!
    }
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Mon Oct 23 09:06:30 GMT 2023
    - 4.9K bytes
    - Viewed (0)
  4. src/bytes/example_test.go

    // Copyright 2011 The Go Authors. All rights reserved.
    // Use of this source code is governed by a BSD-style
    // license that can be found in the LICENSE file.
    
    package bytes_test
    
    import (
    	"bytes"
    	"encoding/base64"
    	"fmt"
    	"io"
    	"os"
    	"sort"
    	"strconv"
    	"unicode"
    )
    
    func ExampleBuffer() {
    	var b bytes.Buffer // A Buffer needs no initialization.
    	b.Write([]byte("Hello "))
    	fmt.Fprintf(&b, "world!")
    Go
    - Registered: Tue Apr 30 11:13:12 GMT 2024
    - Last Modified: Mon Mar 04 15:54:40 GMT 2024
    - 15K bytes
    - Viewed (1)
Back to top