- Sort Score
- Result 10 results
- Languages All
Results 81 - 90 of 1,060 for doDecode (0.41 sec)
-
src/encoding/base64/example_test.go
} func ExampleEncoding_Decode() { str := "SGVsbG8sIHdvcmxkIQ==" dst := make([]byte, base64.StdEncoding.DecodedLen(len(str))) n, err := base64.StdEncoding.Decode(dst, []byte(str)) if err != nil { fmt.Println("decode error:", err) return } dst = dst[:n] fmt.Printf("%q\n", dst) // Output: // "Hello, world!" } func ExampleNewEncoder() { input := []byte("foo\x00bar")
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Oct 19 08:44:22 UTC 2021 - 1.9K bytes - Viewed (0) -
src/main/java/jcifs/dcerpc/msrpc/srvsvc.java
if ( this.netname != null ) { _dst = _dst.deferred; _dst.enc_ndr_string(this.netname); } } @Override public void decode ( NdrBuffer _src ) throws NdrException { _src.align(4); int _netnamep = _src.dec_ndr_long(); if ( _netnamep != 0 ) { _src = _src.deferred;
Registered: Wed Jun 12 15:45:55 UTC 2024 - Last Modified: Fri Mar 22 20:40:13 UTC 2019 - 19.9K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/primitives/UnsignedLongsTest.java
assertThat(UnsignedLongs.decode("0xffffffffffffffff")).isEqualTo(0xffffffffffffffffL); assertThat(UnsignedLongs.decode("01234567")).isEqualTo(01234567); // octal assertThat(UnsignedLongs.decode("#1234567890abcdef")).isEqualTo(0x1234567890abcdefL); assertThat(UnsignedLongs.decode("987654321012345678")).isEqualTo(987654321012345678L); assertThat(UnsignedLongs.decode("0x135791357913579")).isEqualTo(0x135791357913579L);
Registered: Wed Jun 12 16:38:11 UTC 2024 - Last Modified: Fri Feb 09 15:36:17 UTC 2024 - 13.2K bytes - Viewed (0) -
src/encoding/ascii85/ascii85_test.go
dbuf := make([]byte, 4*len(p.encoded)) ndst, nsrc, err := Decode(dbuf, []byte(p.encoded), true) testEqual(t, "Decode(%q) = error %v, want %v", p.encoded, err, error(nil)) testEqual(t, "Decode(%q) = nsrc %v, want %v", p.encoded, nsrc, len(p.encoded)) testEqual(t, "Decode(%q) = ndst %v, want %v", p.encoded, ndst, len(p.decoded)) testEqual(t, "Decode(%q) = %q, want %q", p.encoded, string(dbuf[0:ndst]), p.decoded) } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Sep 06 15:46:20 UTC 2022 - 5.8K bytes - Viewed (0) -
src/unicode/utf16/utf16_test.go
out := Decode(tt.in) if out == nil { t.Errorf("Decode(%x) = nil", tt.in) } }) if allocs > 0 { t.Errorf("Decode allocated %v times", allocs) } } } func TestDecode(t *testing.T) { for _, tt := range decodeTests { out := Decode(tt.in) if !reflect.DeepEqual(out, tt.out) { t.Errorf("Decode(%x) = %x; want %x", tt.in, out, tt.out) } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 07 19:08:48 UTC 2024 - 6.5K bytes - Viewed (0) -
security/pkg/pki/util/crypto.go
// trailing newline characters removed func PemCertBytestoString(caCerts []byte) []string { certs := []string{} var cert string pemBlock := caCerts for block, rest := pem.Decode(pemBlock); block != nil && len(block.Bytes) != 0; block, rest = pem.Decode(pemBlock) { if len(rest) == 0 { cert = strings.TrimPrefix(strings.TrimSuffix(string(pemBlock), "\n"), "\n") certs = append(certs, cert) break }
Registered: Fri Jun 14 15:00:06 UTC 2024 - Last Modified: Tue Jun 04 13:00:07 UTC 2024 - 5.3K bytes - Viewed (0) -
pkg/api/testing/serialization_test.go
apiVersion: v1 kind: Pod metadata: creationTimestamp: 2018-08-30T14:10:58Z name: test spec: containers: null status: {}`) if obj, err := runtime.Decode(legacyscheme.Codecs.LegacyCodec(v1.SchemeGroupVersion), testYAML); err != nil { t.Fatalf("unable to decode yaml: %v", err) } else { if obj2, ok := obj.(*api.Pod); !ok { t.Fatalf("Got wrong type") } else {
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Mon Sep 25 11:04:08 UTC 2023 - 19.3K bytes - Viewed (0) -
platforms/core-runtime/messaging/src/test/groovy/org/gradle/internal/stream/EncodedStreamTest.groovy
* limitations under the License. */ package org.gradle.internal.stream import spock.lang.Specification class EncodedStreamTest extends Specification { def "can encode and decode an empty stream"() { def outputStream = new ByteArrayOutputStream() def encoder = new EncodedStream.EncodedOutput(outputStream) when: encoder.flush() then:
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Fri Sep 22 08:59:22 UTC 2023 - 2.2K bytes - Viewed (0) -
android/guava-tests/benchmark/com/google/common/hash/HashStringBenchmark.java
/** * Convert the input string to a code point. Accepts regular decimal numerals, hex strings, and * some symbolic names meaningful to humans. */ private static int decode(String userFriendly) { try { return Integer.decode(userFriendly); } catch (NumberFormatException ignored) { if (userFriendly.matches("(?i)(?:American|English|ASCII)")) { // 1-byte UTF-8 sequences - "American" ASCII text
Registered: Wed Jun 12 16:38:11 UTC 2024 - Last Modified: Mon Dec 04 17:37:03 UTC 2017 - 5.3K bytes - Viewed (0) -
okhttp-tls/src/main/kotlin/okhttp3/tls/Certificates.kt
} catch (nsee: NoSuchElementException) { throw IllegalArgumentException("failed to decode certificate", nsee) } catch (iae: IllegalArgumentException) { throw IllegalArgumentException("failed to decode certificate", iae) } catch (e: GeneralSecurityException) { throw IllegalArgumentException("failed to decode certificate", e) } } /** * Returns the certificate encoded in [PEM format][rfc_7468]. *
Registered: Sun Jun 16 04:42:17 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 2.8K bytes - Viewed (0)