MCPcopy Create free account

hub / github.com/pquerna/ffjson / functions

Functions575 in github.com/pquerna/ffjson

↓ 2 callersFunctionadjustLastDigit
adjustLastDigit modifies d = x-currentDiff*ε, to get closest to d = x-targetDiff*ε, without becoming smaller than x-maxDiff*ε. It assumes that a decim
fflib/v1/extfloat.go:645
↓ 2 callersFunctionadjustLastDigit
adjustLastDigit modifies d = x-currentDiff*ε, to get closest to d = x-targetDiff*ε, without becoming smaller than x-maxDiff*ε. It assumes that a decim
fflib/v1/internal/extfloat.go:645
↓ 2 callersFunctiondigitZero
(dst []byte)
fflib/v1/decimal.go:61
↓ 2 callersFunctiondigitZero
(dst []byte)
fflib/v1/internal/atof.go:619
↓ 2 callersFunctionemptyInterface
emptyInterface creates a new instance of the object sent It the returned interface is writable and contains the zero value.
tests/ff_test.go:252
↓ 2 callersFunctionextractFields
extractFields returns a list of fields that JSON should recognize for the given type. The algorithm is breadth-first search over the set of structs to
inception/reflect.go:130
↓ 2 callersFunctionfmtE
%e: -d.ddddde±dd
fflib/v1/ftoa.go:333
↓ 2 callersFunctionfmtE
%e: -d.ddddde±dd
fflib/v1/internal/ftoa.go:334
↓ 2 callersFunctionfmtF
%f: -ddddddd.ddddd
fflib/v1/ftoa.go:393
↓ 2 callersFunctionfmtF
%f: -ddddddd.ddddd
fflib/v1/internal/ftoa.go:401
↓ 2 callersFunctionformatBits
formatBits computes the string representation of u in the given base. If neg is set, u is treated as negative int64 value.
fflib/v1/ftoa.go:464
↓ 2 callersFunctionformatDigits
(dst EncodingBuffer, shortest bool, neg bool, digs decimalSlice, prec int, fmt byte)
fflib/v1/ftoa.go:185
↓ 2 callersFunctionformatDigits
(dst []byte, shortest bool, neg bool, digs decimalSlice, prec int, fmt byte)
fflib/v1/internal/ftoa.go:191
↓ 2 callersMethodfrexp10
Frexp10 is an analogue of math.Frexp for decimal powers. It scales f by an approximate power of ten 10^-exp, and returns exp10, so that f*10^exp10 has
fflib/v1/extfloat.go:336
↓ 2 callersMethodfrexp10
Frexp10 is an analogue of math.Frexp for decimal powers. It scales f by an approximate power of ten 10^-exp, and returns exp10, so that f*10^exp10 has
fflib/v1/internal/extfloat.go:336
↓ 2 callersFunctiongenericFtoa
(dst []byte, val float64, fmt byte, prec, bitSize int)
fflib/v1/internal/ftoa.go:54
↓ 2 callersFunctiongetBaseData
(b fatalF)
tests/go.stripe/stripe_test.go:83
↓ 2 callersFunctiongetField
(ic *Inception, f *StructField, prefix string)
inception/encoder.go:434
↓ 2 callersFunctiongetGetInnerValue
(ic *Inception, name string, typ reflect.Type, ptr bool, forceString bool)
inception/encoder.go:133
↓ 2 callersFunctiongetXValue
(thing interface{})
tests/ff_test.go:407
↓ 2 callersFunctiongetu4
getu4 decodes \uXXXX from the beginning of s, returning the hex value, or it returns -1.
fflib/v1/jsonstring.go:243
↓ 2 callersFunctionlastConditional
We check if the last field is conditional.
inception/encoder.go:475
↓ 2 callersFunctionleftShift
Binary shift left (/ 2) by k bits. k <= maxShift to avoid overflow.
fflib/v1/decimal.go:232
↓ 2 callersFunctionleftShift
Binary shift left (/ 2) by k bits. k <= maxShift to avoid overflow.
fflib/v1/internal/atof.go:790
↓ 2 callersFunctionmin
(a, b int)
fflib/v1/ftoa.go:448
↓ 2 callersFunctionreadFloat
readFloat reads a decimal mantissa and exponent from a float string representation. It sets ok to false if the number could not fit return types or is
fflib/v1/internal/atof.go:176
↓ 2 callersMethodreadSlice
readSlice is like ReadBytes but returns a reference to internal buffer data.
fflib/v1/buffer.go:381
↓ 2 callersMethodreadU4
(j int)
fflib/v1/reader.go:132
↓ 2 callersMethodrenderTpl
(f *os.File, t *template.Template, tc *templateCtx)
generator/inceptionmain.go:153
↓ 2 callersFunctionreseed
()
generator/tempfile.go:22
↓ 2 callersFunctionrightShift
Binary shift right (* 2) by k bits. k <= maxShift to avoid overflow.
fflib/v1/decimal.go:109
↓ 2 callersFunctionrightShift
Binary shift right (* 2) by k bits. k <= maxShift to avoid overflow.
fflib/v1/internal/atof.go:667
↓ 2 callersMethodscanField
(start FFTok, capture bool)
fflib/v1/lexer.go:482
↓ 2 callersFunctionscanToTokCount
(ffl *FFLexer, targetTok FFTok)
fflib/v1/lexer_test.go:61
↓ 2 callersMethodset
(s []byte)
fflib/v1/internal/atof.go:83
↓ 2 callersFunctionshouldRoundUp
If we chop a at nd digits, should we round up?
fflib/v1/decimal.go:298
↓ 2 callersFunctionshouldRoundUp
If we chop a at nd digits, should we round up?
fflib/v1/internal/atof.go:856
↓ 2 callersFunctionspecial
(s []byte)
fflib/v1/internal/atof.go:56
↓ 2 callersFunctiontError
(t *testing.T, input string, targetCount int, targetError FFErr)
fflib/v1/lexer_test.go:271
↓ 1 callersMethodAdd
(obj shared.InceptionType)
inception/inception.go:60
↓ 1 callersMethodAssignComputeBounds
AssignComputeBounds sets f to the floating point value defined by mant, exp and precision given by flt. It returns lower, upper such that any number i
fflib/v1/extfloat.go:176
↓ 1 callersMethodAssignComputeBounds
AssignComputeBounds sets f to the floating point value defined by mant, exp and precision given by flt. It returns lower, upper such that any number i
fflib/v1/internal/extfloat.go:176
↓ 1 callersMethodCaptureField
Captures an entire field value, including recursive objects, and converts them to a []byte suitable to pass to a sub-object's UnmarshalJSON
fflib/v1/lexer.go:564
↓ 1 callersFunctionCreateMarshalJSON
(ic *Inception, si *StructInfo)
inception/encoder.go:483
↓ 1 callersFunctionCreateUnmarshalJSON
(ic *Inception, si *StructInfo)
inception/decoder.go:38
↓ 1 callersFunctionExtractStructs
(inputPath string)
generator/parser.go:85
↓ 1 callersMethodFixedDecimal
FixedDecimal stores in d the first n significant digits of the decimal representation of f. It returns false if it cannot be sure of the answer.
fflib/v1/extfloat.go:378
↓ 1 callersMethodFixedDecimal
FixedDecimal stores in d the first n significant digits of the decimal representation of f. It returns false if it cannot be sure of the answer.
fflib/v1/internal/extfloat.go:378
↓ 1 callersFunctionFormatBits2
FormatBits2 computes the string representation of u in the given base. If neg is set, u is treated as negative int64 value. If append_ is set, the str
fflib/v1/iota.go:83
↓ 1 callersMethodGenerate
(packageName string, si []*StructInfo, importName string)
generator/inceptionmain.go:167
↓ 1 callersFunctionMarshal
Marshal will act the same way as json.Marshal, except it will choose the ffjson marshal function before falling back to using json.Marshal. Using this
ffjson/marshal.go:42
↓ 1 callersFunctionNewInceptionMain
(goCmd string, inputPath string, outputPath string, resetFields bool)
generator/inceptionmain.go:101
↓ 1 callersFunctionNewStructInfo
(name string)
generator/parser.go:44
↓ 1 callersFunctionNewStructInfo
(obj shared.InceptionType)
inception/reflect.go:57
↓ 1 callersFunctionParseUint
ParseUint is like ParseInt but for unsigned numbers, and oeprating on []byte
fflib/v1/bytenum.go:34
↓ 1 callersFunctionParseUint
ParseUint is like ParseInt but for unsigned numbers, and oeprating on []byte
fflib/v1/internal/atoi.go:69
↓ 1 callersFunctionPool
Send a buffer to the Pool to reuse for other instances. On servers where you have a lot of concurrent encoding going on, you can hand back the byte b
ffjson/pool.go:31
↓ 1 callersMethodRead
Read reads the next len(p) bytes from the buffer or until the buffer is drained. The return value n is the number of bytes read. If the buffer has n
fflib/v1/buffer.go:304
↓ 1 callersMethodReadByteNoWS
()
fflib/v1/reader.go:78
↓ 1 callersFunctionRenderTemplate
(ic *Inception)
inception/template.go:43
↓ 1 callersMethodRoundedInteger
Extract integer part, rounded appropriately. No guarantees about overflow.
fflib/v1/internal/atof.go:920
↓ 1 callersMethodRun
()
generator/inceptionmain.go:226
↓ 1 callersMethodShortestDecimal
ShortestDecimal stores in d the shortest decimal representation of f which belongs to the open interval (lower, upper), where f is supposed to lie. It
fflib/v1/extfloat.go:532
↓ 1 callersMethodShortestDecimal
ShortestDecimal stores in d the shortest decimal representation of f which belongs to the open interval (lower, upper), where f is supposed to lie. It
fflib/v1/internal/extfloat.go:532
↓ 1 callersMethodSort
()
inception/inception.go:98
↓ 1 callersFunctionTempFileWithPostfix
TempFile creates a new temporary file in the directory dir with a name beginning with prefix, opens the file for reading and writing, and returns the
generator/tempfile.go:47
↓ 1 callersFunctionUnmarshal
Unmarshal will act the same way as json.Unmarshal, except it will choose the ffjson unmarshal function before falling back to using json.Unmarshal. Th
ffjson/marshal.go:84
↓ 1 callersMethodUnreadByte
()
fflib/v1/reader.go:124
↓ 1 callersMethodWrapErr
(err error)
fflib/v1/lexer.go:145
↓ 1 callersFunctionadjustLastDigitFixed
adjustLastDigitFixed assumes d contains the representation of the integral part of some number, whose fractional part is num / (den << shift). The num
fflib/v1/extfloat.go:496
↓ 1 callersFunctionadjustLastDigitFixed
adjustLastDigitFixed assumes d contains the representation of the integral part of some number, whose fractional part is num / (den << shift). The num
fflib/v1/internal/extfloat.go:496
↓ 1 callersFunctionatof32
(s []byte)
fflib/v1/internal/atof.go:455
↓ 1 callersFunctionatof32exact
If possible to compute mantissa*10^exp to 32-bit float f exactly, entirely in floating-point math, do so, avoiding the machinery above.
fflib/v1/internal/atof.go:422
↓ 1 callersFunctionatof64
(s []byte)
fflib/v1/internal/atof.go:494
↓ 1 callersFunctionatof64exact
If possible to convert decimal representation to 64-bit float f exactly, entirely in floating-point math, do so, avoiding the expense of decimalToFloa
fflib/v1/internal/atof.go:388
↓ 1 callersFunctioncutoff64
Return the first number n such that n*base >= 1<<64.
fflib/v1/internal/atoi.go:61
↓ 1 callersFunctiondominantField
dominantField looks through the fields, all of which are known to have the same name, to find the single field that dominates the others using Go's em
inception/reflect.go:268
↓ 1 callersFunctionfmtB
%b: -ddddddddp±ddd
fflib/v1/ftoa.go:426
↓ 1 callersFunctionfmtB
%b: -ddddddddp+ddd
fflib/v1/internal/ftoa.go:436
↓ 1 callersFunctionfoldFunc
(key []byte)
inception/reflect.go:90
↓ 1 callersFunctionfrexp10Many
frexp10Many applies a common shift by a power of ten to a, b, c.
fflib/v1/extfloat.go:368
↓ 1 callersFunctionfrexp10Many
frexp10Many applies a common shift by a power of ten to a, b, c.
fflib/v1/internal/extfloat.go:368
↓ 1 callersFunctionfuzzTime
Return a time no later than 5000 years from unix datum. JSON cannot handle dates after year 9999.
tests/fuzz_test.go:122
↓ 1 callersMethodgenerateCode
()
inception/inception.go:100
↓ 1 callersFunctiongetArrayHandler
(ic *Inception, name string, typ reflect.Type, ptr bool)
inception/decoder.go:193
↓ 1 callersFunctiongetExposePath
(inputPath string)
generator/inceptionmain.go:149
↓ 1 callersFunctiongetImportName
(goCmd, inputPath string)
generator/inceptionmain.go:112
↓ 1 callersFunctiongetMapValue
(ic *Inception, name string, typ reflect.Type, ptr bool, forceString bool)
inception/encoder.go:80
↓ 1 callersFunctiongetOmitEmpty
(ic *Inception, sf *StructField)
inception/encoder.go:42
↓ 1 callersFunctiongetTotalSize
(si *StructInfo)
inception/encoder.go:404
↓ 1 callersFunctiongetTypeSize
(t reflect.Type)
inception/encoder.go:371
↓ 1 callersFunctiongetValue
(ic *Inception, sf *StructField, prefix string)
inception/encoder.go:326
↓ 1 callersMethodhandleEscaped
(c byte, j int, out DecodingBuffer)
fflib/v1/reader.go:158
↓ 1 callersFunctionhandleFieldAddr
(ic *Inception, name string, takeAddr bool, typ reflect.Type, ptr bool, quoted bool)
inception/decoder.go:67
↓ 1 callersFunctionisValidTag
(s string)
inception/tags.go:62
↓ 1 callersMethodlexComment
()
fflib/v1/lexer.go:213
↓ 1 callersMethodlexNumber
()
fflib/v1/lexer.go:285
↓ 1 callersMethodlexString
()
fflib/v1/lexer.go:260
↓ 1 callersFunctionnextSuffix
()
generator/tempfile.go:26
↓ 1 callersFunctionp2
(v uint32)
inception/encoder.go:360
← previousnext →101–200 of 575, ranked by callers