Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 40 for toBytes (0.14 sec)

  1. platforms/software/dependency-management/src/test/groovy/org/gradle/api/internal/artifacts/ivyservice/resolveengine/result/ComponentSelectorSerializerTest.groovy

                DefaultModuleIdentifier.newId('group3', 'name3'), constraint('1.0'), factory.of(attr, "val1"), [])
    
            when:
            byte[] result1 = toBytes(selector1, serializer)
            byte[] result2 = toBytes(selector2, serializer)
            byte[] result3 = toBytes(selector3, serializer)
    
            then:
            result2.length == result1.length // different attributes
            result3.length < result1.length // already seen
    
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Tue Oct 10 21:10:11 UTC 2023
    - 11.8K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apiserver/pkg/authentication/token/cache/cached_token_authenticator_test.go

    	t.Parallel()
    
    	// needs to be large to force allocations so we pick a random value between [1024, 2048]
    	size := utilrand.IntnRange(1024, 2048+1)
    
    	t.Run("toBytes semantics", func(t *testing.T) {
    		t.Parallel()
    
    		s := utilrand.String(size)
    		b := toBytes(s)
    		if len(b) != size {
    			t.Errorf("unexpected length: %d", len(b))
    		}
    		if cap(b) != size {
    			t.Errorf("unexpected capacity: %d", cap(b))
    		}
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon Jul 03 16:16:51 UTC 2023
    - 20.3K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apiserver/pkg/storage/value/encrypt/envelope/kmsv2/envelope.go

    		b.AddUint16LengthPrefixed(func(b *cryptobyte.Builder) {
    			b.AddBytes(toBytes(k))
    		})
    		b.AddUint16LengthPrefixed(func(b *cryptobyte.Builder) {
    			b.AddBytes(annotations[k])
    		})
    	}
    
    	return b.Bytes()
    }
    
    // toBytes performs unholy acts to avoid allocations
    func toBytes(s string) []byte {
    	// unsafe.StringData is unspecified for the empty string, so we provide a strict interpretation
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri Oct 27 00:23:50 UTC 2023
    - 18.7K bytes
    - Viewed (0)
  4. pkg/kubelet/stats/cri_stats_provider_windows_test.go

    						RxBytes: toP(1),
    						TxBytes: toP(10),
    					},
    					Interfaces: []statsapi.InterfaceStats{
    						{
    							Name:    "test",
    							RxBytes: toP(1),
    
    							TxBytes: toP(10),
    						},
    					},
    				},
    				"c2": {
    					Time: v1.Time{},
    					InterfaceStats: statsapi.InterfaceStats{
    						Name:    "test2",
    						RxBytes: toP(2),
    						TxBytes: toP(20),
    					},
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Sat Feb 17 00:02:10 UTC 2024
    - 13.8K bytes
    - Viewed (0)
  5. pkg/kubelet/stats/provider_test.go

    	cinfo.Stats[0].Network = &cadvisorapiv2.NetworkStats{
    		Interfaces: []cadvisorapiv1.InterfaceStats{{
    			Name:     "eth0",
    			RxBytes:  0,
    			RxErrors: 0,
    			TxBytes:  0,
    			TxErrors: 0,
    		}, {
    			Name:     "cbr0",
    			RxBytes:  0,
    			RxErrors: 0,
    			TxBytes:  0,
    			TxErrors: 0,
    		}},
    	}
    	return cinfo
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Thu Mar 07 08:12:16 UTC 2024
    - 20K bytes
    - Viewed (0)
  6. docs/fr/docs/features.md

    Inversement, dans la plupart des cas vous pourrez juste envoyer l'objet récupéré de la base de données **directement au client**
    
    Avec **FastAPI** vous aurez toutes les fonctionnalités de **Pydantic**  (comme FastAPI est basé sur Pydantic pour toutes les manipulations de données):
    
    * **Pas de prise de tête**:
        * Pas de nouveau langage de définition de schéma à apprendre.
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu Apr 18 19:53:19 UTC 2024
    - 11.1K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/MultipartBody.kt

         */
        @JvmField
        val FORM = "multipart/form-data".toMediaType()
    
        private val COLONSPACE = byteArrayOf(':'.code.toByte(), ' '.code.toByte())
        private val CRLF = byteArrayOf('\r'.code.toByte(), '\n'.code.toByte())
        private val DASHDASH = byteArrayOf('-'.code.toByte(), '-'.code.toByte())
    
        /**
         * Appends a quoted-string to a StringBuilder.
         *
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 10.9K bytes
    - Viewed (0)
  8. okhttp/src/main/kotlin/okhttp3/internal/-HostnamesCommon.kt

    private fun isMappedIpv4Address(address: ByteArray): Boolean {
      if (address.size != 16) return false
    
      for (i in 0 until 10) {
        if (address[i] != 0.toByte()) return false
      }
    
      if (address[10] != 255.toByte()) return false
      if (address[11] != 255.toByte()) return false
    
      return true
    }
    
    /** Encodes an IPv4 address in canonical form according to RFC 4001. */
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 11.2K bytes
    - Viewed (0)
  9. src/cmd/vendor/golang.org/x/sys/unix/ztypes_darwin_arm64.go

    	Snd_wnd             uint32
    	Snd_sbbytes         uint32
    	Rcv_wnd             uint32
    	Rttcur              uint32
    	Srtt                uint32
    	Rttvar              uint32
    	Txpackets           uint64
    	Txbytes             uint64
    	Txretransmitbytes   uint64
    	Rxpackets           uint64
    	Rxbytes             uint64
    	Rxoutoforderbytes   uint64
    	Txretransmitpackets uint64
    }
    
    const (
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 23:33:33 UTC 2023
    - 12.4K bytes
    - Viewed (0)
  10. src/cmd/vendor/golang.org/x/sys/unix/ztypes_darwin_amd64.go

    	Snd_wnd             uint32
    	Snd_sbbytes         uint32
    	Rcv_wnd             uint32
    	Rttcur              uint32
    	Srtt                uint32
    	Rttvar              uint32
    	Txpackets           uint64
    	Txbytes             uint64
    	Txretransmitbytes   uint64
    	Rxpackets           uint64
    	Rxbytes             uint64
    	Rxoutoforderbytes   uint64
    	Txretransmitpackets uint64
    }
    
    const (
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 23:33:33 UTC 2023
    - 12.4K bytes
    - Viewed (0)
Back to top