- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 310 for Decoder (0.27 sec)
-
internal/s3select/jstream/decoder.go
func (d *Decoder) Pos() int { return int(d.pos) } // Err returns the most recent decoder error if any, or nil func (d *Decoder) Err() error { return d.err } // MaxDepth will set the maximum recursion depth. // If the maximum depth is exceeded, ErrMaxDepth is returned. // Less than or 0 means no limit (default). func (d *Decoder) MaxDepth(n int) *Decoder { d.maxDepth = n return d }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Sep 23 19:35:41 UTC 2024 - 13.5K bytes - Viewed (0) -
internal/store/queuestore.go
return } var decoder *jsoniter.Decoder if key.Compress { decodedBytes, err := s2.Decode(nil, raw) if err != nil { return nil, err } decoder = jsoniter.ConfigCompatibleWithStandardLibrary.NewDecoder(bytes.NewReader(decodedBytes)) } else { decoder = jsoniter.ConfigCompatibleWithStandardLibrary.NewDecoder(bytes.NewReader(raw)) } for decoder.More() { var item I
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Sep 06 23:06:30 UTC 2024 - 8.6K bytes - Viewed (0) -
internal/s3select/jstream/decoder_test.go
body = `[{"bio":"bada bing bada boom","id":1,"name":"Charles","falseVal":false}]` ) decoder := NewDecoder(mkReader(body), 1) for mv = range decoder.Stream() { counter++ t.Logf("depth=%d offset=%d len=%d (%v)", mv.Depth, mv.Offset, mv.Length, mv.Value) } if err := decoder.Err(); err != nil { t.Fatalf("decoder error: %s", err) } } func TestDecoderNested(t *testing.T) { var ( counter int
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Sep 23 19:35:41 UTC 2024 - 6.6K bytes - Viewed (0) -
schema/serializer.go
case []byte: bytesValue = v default: return fmt.Errorf("failed to unmarshal gob value: %#v", dbValue) } if len(bytesValue) > 0 { decoder := gob.NewDecoder(bytes.NewBuffer(bytesValue)) err = decoder.Decode(fieldValue.Interface()) } } field.ReflectValueOf(ctx, dst).Set(fieldValue.Elem()) return } // Value implements serializer interface
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Thu Jun 20 08:45:38 UTC 2024 - 4.6K bytes - Viewed (0) -
internal/bucket/lifecycle/expiration.go
// MarshalXML encodes delete marker boolean into an XML form. func (b Boolean) MarshalXML(e *xml.Encoder, startElement xml.StartElement) error { if !b.set { return nil } return e.EncodeElement(b.val, startElement) } // UnmarshalXML decodes delete marker boolean from the XML form. func (b *Boolean) UnmarshalXML(d *xml.Decoder, startElement xml.StartElement) error { var exp bool err := d.DecodeElement(&exp, &startElement)
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Feb 21 20:28:34 UTC 2024 - 6.6K bytes - Viewed (0) -
internal/s3select/json/reader.go
// Reader - JSON record reader for S3Select. type Reader struct { args *ReaderArgs decoder *jstream.Decoder valueCh chan *jstream.MetaValue readCloser io.ReadCloser } // Read - reads single record. func (r *Reader) Read(dst sql.Record) (sql.Record, error) { v, ok := <-r.valueCh if !ok { if err := r.decoder.Err(); err != nil { return nil, errJSONParsingError(err) } return nil, io.EOF }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Sep 23 19:35:41 UTC 2024 - 3.2K bytes - Viewed (0) -
internal/s3select/jstream/README.md
we can choose to extract and act only the objects within the top-level array: ```go f, _ := os.Open("input.json") decoder := jstream.NewDecoder(f, 1) // extract JSON values at a depth level of 1 for mv := range decoder.Stream() { fmt.Printf("%v\n ", mv.Value) } ``` output: ``` map[desc:RGB colors:[red green blue]] map[desc:CMYK colors:[cyan magenta yellow black]] ```
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Sep 23 19:35:41 UTC 2024 - 3.2K bytes - Viewed (0) -
okhttp-hpacktests/src/test/java/okhttp3/internal/http2/HpackRoundTripTest.kt
import org.junit.jupiter.params.provider.ArgumentsSource /** * Tests for round-tripping headers through hpack. * * TODO: update hpack-test-case with the output of our encoder. * This test will hide complementary bugs in the encoder and decoder, * We should test that the encoder is producing responses that are */ class HpackRoundTripTest : HpackDecodeTestBase() { internal class StoriesTestProvider : SimpleProvider() {
Registered: Fri Nov 01 11:42:11 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 2K bytes - Viewed (0) -
internal/bucket/object/lock/lock.go
const ( // This tested by using `mc lock` command maximumRetentionDays = 36500 maximumRetentionYears = 100 ) // UnmarshalXML - decodes XML data. func (dr *DefaultRetention) UnmarshalXML(d *xml.Decoder, start xml.StartElement) error { // Make subtype to avoid recursive UnmarshalXML(). type defaultRetention DefaultRetention retention := defaultRetention{}
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sat Jun 29 01:20:27 UTC 2024 - 17.1K bytes - Viewed (0) -
internal/bucket/lifecycle/delmarker-expiration.go
// Used to detect if lifecycle.Rule contained a DelMarkerExpiration element. func (de DelMarkerExpiration) Empty() bool { return de.Days == 0 } // UnmarshalXML decodes a single XML element into a DelMarkerExpiration value func (de *DelMarkerExpiration) UnmarshalXML(dec *xml.Decoder, start xml.StartElement) error { type delMarkerExpiration DelMarkerExpiration var dexp delMarkerExpiration err := dec.DecodeElement(&dexp, &start) if err != nil {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed May 01 01:11:10 UTC 2024 - 2.3K bytes - Viewed (0)