Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 788 for lencode (0.04 sec)

  1. docs/en/docs/tutorial/encoder.md

    # JSON Compatible Encoder { #json-compatible-encoder }
    
    There are some cases where you might need to convert a data type (like a Pydantic model) to something compatible with JSON (like a `dict`, `list`, etc).
    
    For example, if you need to store it in a database.
    
    For that, **FastAPI** provides a `jsonable_encoder()` function.
    
    ## Using the `jsonable_encoder` { #using-the-jsonable-encoder }
    
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Sun Aug 31 09:15:41 UTC 2025
    - 1.7K bytes
    - Viewed (0)
  2. src/main/java/jcifs/util/Strings.java

        /**
         *
         */
        private Strings() {
        }
    
        /**
         * Encodes a string into bytes using the specified encoding.
         *
         * @param str the string to encode
         * @param encoding the character encoding to use
         * @return encoded byte array, or empty array if str is null
         */
        public static byte[] getBytes(final String str, final Charset encoding) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 6.5K bytes
    - Viewed (0)
  3. cmd/erasure-encode.go

    	return fmt.Errorf("%w (offline-disks=%d/%d)", writeErr, countErrs(p.errs, errDiskNotFound), len(p.writers))
    }
    
    // Encode reads from the reader, erasure-encodes the data and writes to the writers.
    func (e *Erasure) Encode(ctx context.Context, src io.Reader, writers []io.Writer, buf []byte, quorum int) (total int64, err error) {
    	writer := &multiWriter{
    		writers:     writers,
    		writeQuorum: quorum,
    Registered: Sun Sep 07 19:28:11 UTC 2025
    - Last Modified: Wed May 15 00:11:04 UTC 2024
    - 2.9K bytes
    - Viewed (0)
  4. src/main/java/jcifs/smb1/util/Encdec.java

            return src[si] & 0xFF | (src[si + 1] & 0xFF) << 8 | (src[si + 2] & 0xFF) << 16 | (src[si + 3] & 0xFF) << 24;
        }
    
        /* Encode and decode 64 bit integers
         */
    
        /**
         * Encodes a 64-bit unsigned integer in big-endian byte order.
         *
         * @param l the long value to encode
         * @param dst the destination byte array
         * @param di the starting index in the destination array
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 18.5K bytes
    - Viewed (0)
  5. src/main/java/org/codelibs/core/misc/Base64Util.java

                DECODE_TABLE[ENCODE_TABLE[i]] = (byte) i;
            }
        }
    
        /**
         * Encodes data in Base64.
         *
         * @param inData
         *            The data to encode
         * @return The encoded data
         */
        public static String encode(final byte[] inData) {
            if (ArrayUtil.isEmpty(inData)) {
                return "";
            }
            final int mod = inData.length % 3;
    Registered: Fri Sep 05 20:58:11 UTC 2025
    - Last Modified: Thu Jul 31 08:16:49 UTC 2025
    - 6.2K bytes
    - Viewed (0)
  6. docs/uk/docs/tutorial/encoder.md

    # JSON Compatible Encoder
    
    Існують випадки, коли вам може знадобитися перетворити тип даних (наприклад, модель Pydantic) в щось сумісне з JSON (наприклад, `dict`, `list`, і т. д.).
    
    Наприклад, якщо вам потрібно зберегти це в базі даних.
    
    Для цього, **FastAPI** надає `jsonable_encoder()` функцію.
    
    ## Використання `jsonable_encoder`
    
    Давайте уявимо, що у вас є база даних `fake_db`, яка приймає лише дані, сумісні з JSON.
    
    Registered: Sun Sep 07 07:19:17 UTC 2025
    - Last Modified: Mon Nov 18 02:25:44 UTC 2024
    - 2.5K bytes
    - Viewed (0)
  7. src/test/java/org/codelibs/fess/util/FacetResponseTest.java

        }
    
        public void test_unicode_base64_encoding() {
            // Test that unicode strings are properly encoded/decoded
            String unicodeString = "日本語テスト";
            String encoded = BaseEncoding.base64().encode(unicodeString.getBytes(StandardCharsets.UTF_8));
            String decoded = new String(BaseEncoding.base64().decode(encoded), StandardCharsets.UTF_8);
    
            assertEquals(unicodeString, decoded);
        }
    
    Registered: Thu Sep 04 12:52:25 UTC 2025
    - Last Modified: Sat Jul 12 07:34:10 UTC 2025
    - 6.6K bytes
    - Viewed (0)
  8. src/test/java/jcifs/internal/smb2/nego/NegotiateContextRequestTest.java

                context = new PreauthIntegrityNegotiateContext(mockConfig, hashAlgos, salt);
                int encoded = context.encode(buffer, 0);
    
                assertEquals(4 + (count * 2) + 16, encoded);
                assertEquals(context.size(), encoded);
            }
    
            @Test
            @DisplayName("Should encode and decode correctly")
            void testEncodeAndDecode() throws SMBProtocolDecodingException {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 18.8K bytes
    - Viewed (0)
  9. src/main/java/jcifs/smb1/util/Base64.java

        /**
         * Base-64 encodes the supplied block of data.  Line wrapping is not
         * applied on output.
         *
         * @param bytes The block of data that is to be Base-64 encoded.
         * @return A <code>String</code> containing the encoded data.
         */
        public static String encode(final byte[] bytes) {
            int length = bytes.length;
            if (length == 0) {
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Sat Aug 16 01:32:48 UTC 2025
    - 4.1K bytes
    - Viewed (0)
  10. src/test/java/jcifs/internal/fscc/FileInformationTest.java

            when(mockFileInfo.encode(dst, 0)).thenReturn(8);
            when(mockFileInfo.size()).thenReturn(8);
    
            // Test encode
            int encoded = mockFileInfo.encode(dst, 0);
            assertEquals(8, encoded);
    
            // Test size
            int size = mockFileInfo.size();
            assertEquals(8, size);
    
            // Verify interactions
            verify(mockFileInfo).encode(dst, 0);
    Registered: Sun Sep 07 00:10:21 UTC 2025
    - Last Modified: Thu Aug 14 05:31:44 UTC 2025
    - 11.5K bytes
    - Viewed (0)
Back to top