Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 1,132 for Len (0.16 sec)

  1. cmd/bucket-replication-utils_gen_test.go

    		t.Fatal(err)
    	}
    	left, err := v.UnmarshalMsg(bts)
    	if err != nil {
    		t.Fatal(err)
    	}
    	if len(left) > 0 {
    		t.Errorf("%d bytes left over after UnmarshalMsg(): %q", len(left), left)
    	}
    
    	left, err = msgp.Skip(bts)
    	if err != nil {
    		t.Fatal(err)
    	}
    	if len(left) > 0 {
    		t.Errorf("%d bytes left over after Skip(): %q", len(left), left)
    	}
    }
    
    func BenchmarkMarshalMsgBucketReplicationResyncStatus(b *testing.B) {
    Go
    - Registered: Sun Apr 14 19:28:10 GMT 2024
    - Last Modified: Mon Aug 22 23:53:06 GMT 2022
    - 23K bytes
    - Viewed (0)
  2. src/bytes/bytes.go

    func Join(s [][]byte, sep []byte) []byte {
    	if len(s) == 0 {
    		return []byte{}
    	}
    	if len(s) == 1 {
    		// Just return a copy.
    		return append([]byte(nil), s[0]...)
    	}
    
    	var n int
    	if len(sep) > 0 {
    		if len(sep) >= maxInt/(len(s)-1) {
    			panic("bytes: Join output length overflow")
    		}
    		n += len(sep) * (len(s) - 1)
    	}
    	for _, v := range s {
    		if len(v) > maxInt-n {
    Go
    - Registered: Tue Apr 16 11:13:10 GMT 2024
    - Last Modified: Mon Feb 19 19:51:15 GMT 2024
    - 33.8K bytes
    - Viewed (0)
  3. cmd/batch-rotate_gen_test.go

    		t.Fatal(err)
    	}
    	left, err := v.UnmarshalMsg(bts)
    	if err != nil {
    		t.Fatal(err)
    	}
    	if len(left) > 0 {
    		t.Errorf("%d bytes left over after UnmarshalMsg(): %q", len(left), left)
    	}
    
    	left, err = msgp.Skip(bts)
    	if err != nil {
    		t.Fatal(err)
    	}
    	if len(left) > 0 {
    		t.Errorf("%d bytes left over after Skip(): %q", len(left), left)
    	}
    }
    
    func BenchmarkMarshalMsgBatchJobKeyRotateEncryption(b *testing.B) {
    Go
    - Registered: Sun Apr 14 19:28:10 GMT 2024
    - Last Modified: Tue Aug 29 18:27:23 GMT 2023
    - 11.8K bytes
    - Viewed (0)
  4. src/main/java/jcifs/util/Strings.java

         */
        public static int findUNITermination ( byte[] buffer, int bufferIndex, int maxLen ) {
            int len = 0;
            while ( buffer[ bufferIndex + len ] != (byte) 0x00 || buffer[ bufferIndex + len + 1 ] != (byte) 0x00 ) {
                len += 2;
                if ( len > maxLen ) {
                    if ( log.isDebugEnabled() ) {
                        log.warn("Failed to find string termination with max length " + maxLen);
    Java
    - Registered: Sun Apr 14 00:10:09 GMT 2024
    - Last Modified: Mon Mar 13 12:00:57 GMT 2023
    - 4.9K bytes
    - Viewed (0)
  5. cmd/xl-storage-meta-inline.go

    func (x *xlMetaInlineData) serialize(plSize int, keys [][]byte, vals [][]byte) {
    	if len(keys) != len(vals) {
    		panic(fmt.Errorf("xlMetaInlineData.serialize: keys/value number mismatch"))
    	}
    	if len(keys) == 0 {
    		*x = nil
    		return
    	}
    	if plSize <= 0 {
    		plSize = 1 + msgp.MapHeaderSize
    		for i := range keys {
    			plSize += len(keys[i]) + len(vals[i]) + msgp.StringPrefixSize + msgp.ArrayHeaderSize
    		}
    	}
    Go
    - Registered: Sun Apr 14 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 9.5K bytes
    - Viewed (0)
  6. src/archive/zip/zip_test.go

    				rp.n += int64(len(p))
    				return len(p), nil
    			}
    		}
    	}
    
    	for _, b := range p {
    		if rp == nil || rp.b != b {
    			r.buf = append(r.buf, repeatedByte{r.Size(), b, 1})
    			rp = &r.buf[len(r.buf)-1]
    		} else {
    			rp.n++
    		}
    	}
    	return len(p), nil
    }
    
    func memset(a []byte, b byte) {
    	if len(a) == 0 {
    		return
    	}
    Go
    - Registered: Tue Apr 16 11:13:10 GMT 2024
    - Last Modified: Wed Mar 27 18:23:49 GMT 2024
    - 19.5K bytes
    - Viewed (0)
  7. android/guava-tests/benchmark/com/google/common/base/StringsRepeatBenchmark.java

          }
        }
      }
    
      private static String mikeRepeat(String string, int count) {
        final int len = string.length();
        char[] strCopy = new char[len * Integer.highestOneBit(count)];
        string.getChars(0, len, strCopy, 0);
    
        char[] array = new char[len * count];
    
        int strCopyLen = len;
        int pos = 0;
        while (count != 0) {
          if ((count & 1) != 0) {
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Fri Sep 17 20:24:24 GMT 2021
    - 3.3K bytes
    - Viewed (0)
  8. cmd/local-locker_test.go

    	if len(l.lockMap) != len(rResources)+len(wResources) {
    		t.Fatalf("lockmap len, got %d, want %d + %d", len(l.lockMap), len(rResources), len(wResources))
    	}
    	if len(l.lockUID) != len(rResources)+len(wResources) {
    		t.Fatalf("lockUID len, got %d, want %d + %d", len(l.lockUID), len(rResources), len(wResources))
    	}
    
    	// Expire a minute ago.
    	l.expireOldLocks(-time.Minute)
    	if len(l.lockMap) != 0 {
    Go
    - Registered: Sun Apr 14 19:28:10 GMT 2024
    - Last Modified: Sun Mar 05 04:57:35 GMT 2023
    - 11.8K bytes
    - Viewed (0)
  9. src/bytes/reader.go

    type Reader struct {
    	s        []byte
    	i        int64 // current reading index
    	prevRune int   // index of previous rune; or < 0
    }
    
    // Len returns the number of bytes of the unread portion of the
    // slice.
    func (r *Reader) Len() int {
    	if r.i >= int64(len(r.s)) {
    		return 0
    	}
    	return int(int64(len(r.s)) - r.i)
    }
    
    // Size returns the original length of the underlying byte slice.
    Go
    - Registered: Tue Apr 16 11:13:10 GMT 2024
    - Last Modified: Fri Oct 13 17:10:31 GMT 2023
    - 3.9K bytes
    - Viewed (0)
  10. cmd/storage-datatypes_gen_test.go

    		t.Fatal(err)
    	}
    	left, err := v.UnmarshalMsg(bts)
    	if err != nil {
    		t.Fatal(err)
    	}
    	if len(left) > 0 {
    		t.Errorf("%d bytes left over after UnmarshalMsg(): %q", len(left), left)
    	}
    
    	left, err = msgp.Skip(bts)
    	if err != nil {
    		t.Fatal(err)
    	}
    	if len(left) > 0 {
    		t.Errorf("%d bytes left over after Skip(): %q", len(left), left)
    	}
    }
    
    func BenchmarkMarshalMsgBaseOptions(b *testing.B) {
    	v := BaseOptions{}
    Go
    - Registered: Sun Apr 14 19:28:10 GMT 2024
    - Last Modified: Mon Apr 01 23:42:09 GMT 2024
    - 60.4K bytes
    - Viewed (0)
Back to top