当前位置: 首页>>代码示例>>Golang>>正文


Golang FFLexer.SkipField方法代码示例

本文整理汇总了Golang中github.com/pquerna/ffjson/fflib/v1.FFLexer.SkipField方法的典型用法代码示例。如果您正苦于以下问题:Golang FFLexer.SkipField方法的具体用法?Golang FFLexer.SkipField怎么用?Golang FFLexer.SkipField使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在github.com/pquerna/ffjson/fflib/v1.FFLexer的用法示例。


在下文中一共展示了FFLexer.SkipField方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Golang代码示例。

示例1: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
				currentKey = ffj_t_Fingerprintno_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			}

		case fflib.FFParse_want_colon:
			if tok != fflib.FFTok_colon {
				wantedTok = fflib.FFTok_colon
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_Fingerprint_Group:
					goto handle_Group

				case ffj_t_Fingerprint_Username:
					goto handle_Username

				case ffj_t_Fingerprint_Location:
					goto handle_Location

				case ffj_t_Fingerprint_Timestamp:
					goto handle_Timestamp

				case ffj_t_Fingerprint_WifiFingerprint:
					goto handle_WifiFingerprint

				case ffj_t_Fingerprintno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Group:

	/* handler: uj.Group type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.Group = string(string(outBuf))
开发者ID:schollz,项目名称:find,代码行数:66,代码来源:fingerprint_ffjson.go

示例2: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
				if fflib.SimpleLetterEqualFold(ffj_key_ServiceDefinition_Type, kn) {
					currentKey = ffj_t_ServiceDefinition_Type
					state = fflib.FFParse_want_colon
					goto mainparse
				}

				currentKey = ffj_t_ServiceDefinitionno_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			}

		case fflib.FFParse_want_colon:
			if tok != fflib.FFTok_colon {
				wantedTok = fflib.FFTok_colon
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_ServiceDefinition_Type:
					goto handle_Type

				case ffj_t_ServiceDefinition_ContainerPort:
					goto handle_ContainerPort

				case ffj_t_ServiceDefinition_NamePattern:
					goto handle_NamePattern

				case ffj_t_ServiceDefinitionno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Type:

	/* handler: uj.Type type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.Type = string(string(outBuf))
开发者ID:christian-blades-cb,项目名称:desoto,代码行数:66,代码来源:servicedef_ffjson.go

示例3: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
					goto mainparse
				}

				currentKey = ffj_t_AgentRenderno_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			}

		case fflib.FFParse_want_colon:
			if tok != fflib.FFTok_colon {
				wantedTok = fflib.FFTok_colon
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_AgentRender_Type:
					goto handle_Type

				case ffj_t_AgentRender_Pos2D:
					goto handle_Pos2D

				case ffj_t_AgentRender_Heading:
					goto handle_Heading

				case ffj_t_AgentRender_Colour:
					goto handle_Colour

				case ffj_t_AgentRenderno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Type:

	/* handler: uj.Type type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.Type = string(string(outBuf))
开发者ID:benjamin-rood,项目名称:abm-cp,代码行数:66,代码来源:render_ffjson.go

示例4: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
					goto mainparse
				}

				if fflib.EqualFoldRight(ffj_key_LocResult_Component, kn) {
					currentKey = ffj_t_LocResult_Component
					state = fflib.FFParse_want_colon
					goto mainparse
				}

				currentKey = ffj_t_LocResultno_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			}

		case fflib.FFParse_want_colon:
			if tok != fflib.FFTok_colon {
				wantedTok = fflib.FFTok_colon
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_LocResult_Component:
					goto handle_Component

				case ffj_t_LocResult_Geometry:
					goto handle_Geometry

				case ffj_t_LocResultno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Component:

	/* handler: uj.Component type=jstruct.LocComponent kind=struct quoted=false*/

	{
		if tok == fflib.FFTok_null {

			state = fflib.FFParse_after_value
			goto mainparse
		}

		err = uj.Component.UnmarshalJSONFFLexer(fs, fflib.FFParse_want_key)
		if err != nil {
			return err
		}
		state = fflib.FFParse_after_value
	}

	state = fflib.FFParse_after_value
	goto mainparse
开发者ID:pmezard,项目名称:apec,代码行数:67,代码来源:json_ffjson.go

示例5: UnmarshalJSONFFLexer

func (uj *Recaptcha) UnmarshalJSONFFLexer(fs *fflib.FFLexer, state fflib.FFParseState) error {
	var err error = nil
	currentKey := ffj_t_Recaptchabase
	_ = currentKey
	tok := fflib.FFTok_init
	wantedTok := fflib.FFTok_init

mainparse:
	for {
		tok = fs.Scan()
		//	println(fmt.Sprintf("debug: tok: %v  state: %v", tok, state))
		if tok == fflib.FFTok_error {
			goto tokerror
		}

		switch state {

		case fflib.FFParse_map_start:
			if tok != fflib.FFTok_left_bracket {
				wantedTok = fflib.FFTok_left_bracket
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_key
			continue

		case fflib.FFParse_after_value:
			if tok == fflib.FFTok_comma {
				state = fflib.FFParse_want_key
			} else if tok == fflib.FFTok_right_bracket {
				goto done
			} else {
				wantedTok = fflib.FFTok_comma
				goto wrongtokenerror
			}

		case fflib.FFParse_want_key:
			// json {} ended. goto exit. woo.
			if tok == fflib.FFTok_right_bracket {
				goto done
			}
			if tok != fflib.FFTok_string {
				wantedTok = fflib.FFTok_string
				goto wrongtokenerror
			}

			kn := fs.Output.Bytes()
			if len(kn) <= 0 {
				// "" case. hrm.
				currentKey = ffj_t_Recaptchano_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			} else {
				switch kn[0] {

				}

				currentKey = ffj_t_Recaptchano_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			}

		case fflib.FFParse_want_colon:
			if tok != fflib.FFTok_colon {
				wantedTok = fflib.FFTok_colon
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_Recaptchano_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

wantedvalue:
	return fs.WrapErr(fmt.Errorf("wanted value token, but got token: %v", tok))
wrongtokenerror:
	return fs.WrapErr(fmt.Errorf("ffjson: wanted token: %v, but got token: %v output=%s", wantedTok, tok, fs.Output.String()))
tokerror:
	if fs.BigError != nil {
		return fs.WrapErr(fs.BigError)
	}
	err = fs.Error.ToError()
	if err != nil {
		return fs.WrapErr(err)
	}
	panic("ffjson-generated: unreachable, please report bug.")
//.........这里部分代码省略.........
开发者ID:go-recaptcha,项目名称:recaptcha,代码行数:101,代码来源:recaptcha_ffjson.go

示例6: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
				currentKey = ffj_t_Eventno_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			}

		case fflib.FFParse_want_colon:
			if tok != fflib.FFTok_colon {
				wantedTok = fflib.FFTok_colon
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_Event_Host:
					goto handle_Host

				case ffj_t_Event_Service:
					goto handle_Service

				case ffj_t_Event_SubService:
					goto handle_SubService

				case ffj_t_Event_Metric:
					goto handle_Metric

				case ffj_t_Event_Tags:
					goto handle_Tags

				case ffj_t_Eventno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Host:

	/* handler: uj.Host type=string kind=string */

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			uj.Host = string(fs.Output.String())

		}
	}
开发者ID:postfix,项目名称:bangarang,代码行数:67,代码来源:event_ffjson.go

示例7: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
					goto handle_Proportion

				case ffj_t_AnyType_Transparency:
					goto handle_Transparency

				case ffj_t_AnyType_Position:
					goto handle_Position

				case ffj_t_AnyType_X:
					goto handle_X

				case ffj_t_AnyType_Y:
					goto handle_Y

				case ffj_t_AnyType_MinWidth:
					goto handle_MinWidth

				case ffj_t_AnyType_MinHeight:
					goto handle_MinHeight

				case ffj_t_AnyType_FileBytes:
					goto handle_FileBytes

				case ffj_t_AnyType_Width:
					goto handle_Width

				case ffj_t_AnyType_Height:
					goto handle_Height

				case ffj_t_AnyType_Taipe:
					goto handle_Taipe

				case ffj_t_AnyTypeno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Type:

	/* handler: uj.Type type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.Type = string(string(outBuf))
开发者ID:chenbk85,项目名称:nephele,代码行数:66,代码来源:processplan_ffjson.go

示例8: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
					goto mainparse
				}

				currentKey = ffj_t_Userno_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			}

		case fflib.FFParse_want_colon:
			if tok != fflib.FFTok_colon {
				wantedTok = fflib.FFTok_colon
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_User_Name:
					goto handle_Name

				case ffj_t_User_Color:
					goto handle_Color

				case ffj_t_User_LoggedIn:
					goto handle_LoggedIn

				case ffj_t_User_Votes:
					goto handle_Votes

				case ffj_t_Userno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Name:

	/* handler: uj.Name type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.Name = string(string(outBuf))
开发者ID:strawmang,项目名称:strawmang,代码行数:66,代码来源:ffjson_chat.go

示例9: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
					goto handle_Id

				case ffj_t_Incident_Active:
					goto handle_Active

				case ffj_t_Incident_Escalation:
					goto handle_Escalation

				case ffj_t_Incident_Description:
					goto handle_Description

				case ffj_t_Incident_Policy:
					goto handle_Policy

				case ffj_t_Incident_Status:
					goto handle_Status

				case ffj_t_Incident_Host:
					goto handle_Host

				case ffj_t_Incident_Service:
					goto handle_Service

				case ffj_t_Incident_SubService:
					goto handle_SubService

				case ffj_t_Incident_Metric:
					goto handle_Metric

				case ffj_t_Incident_Tags:
					goto handle_Tags

				case ffj_t_Incidentno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_EventName:

	/* handler: uj.EventName type=[]uint8 kind=slice */

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for ", tok))
			}
		}

		if tok == fflib.FFTok_null {
			uj.EventName = nil
		} else {
			b := make([]byte, base64.StdEncoding.DecodedLen(fs.Output.Len()))
			n, err := base64.StdEncoding.Decode(b, fs.Output.Bytes())
			if err != nil {
				return fs.WrapErr(err)
			}
开发者ID:postfix,项目名称:bangarang,代码行数:67,代码来源:incident_ffjson.go

示例10: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
				if fflib.SimpleLetterEqualFold(ffj_key_Event_Payload, kn) {
					currentKey = ffj_t_Event_Payload
					state = fflib.FFParse_want_colon
					goto mainparse
				}

				currentKey = ffj_t_Eventno_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			}

		case fflib.FFParse_want_colon:
			if tok != fflib.FFTok_colon {
				wantedTok = fflib.FFTok_colon
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_Event_Payload:
					goto handle_Payload

				case ffj_t_Event_Service:
					goto handle_Service

				case ffj_t_Event_Type:
					goto handle_Type

				case ffj_t_Eventno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Payload:

	/* handler: uj.Payload type=census.EventPayload kind=struct quoted=false*/

	{
		if tok == fflib.FFTok_null {

			state = fflib.FFParse_after_value
			goto mainparse
		}

		err = uj.Payload.UnmarshalJSONFFLexer(fs, fflib.FFParse_want_key)
		if err != nil {
			return err
		}
		state = fflib.FFParse_after_value
	}

	state = fflib.FFParse_after_value
	goto mainparse
开发者ID:THUNDERGROOVE,项目名称:census,代码行数:67,代码来源:event_stream_ffjson.go

示例11: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
					goto handle_Tussenvoegsel

				case ffj_t_Handtekening_Achternaam:
					goto handle_Achternaam

				case ffj_t_Handtekening_Geboortedatum:
					goto handle_Geboortedatum

				case ffj_t_Handtekening_Geboorteplaats:
					goto handle_Geboorteplaats

				case ffj_t_Handtekening_Straat:
					goto handle_Straat

				case ffj_t_Handtekening_Huisnummer:
					goto handle_Huisnummer

				case ffj_t_Handtekening_Postcode:
					goto handle_Postcode

				case ffj_t_Handtekening_Woonplaats:
					goto handle_Woonplaats

				case ffj_t_Handtekening_Handtekening:
					goto handle_Handtekening

				case ffj_t_Handtekening_Email:
					goto handle_Email

				case ffj_t_Handtekening_CaptchaResponse:
					goto handle_CaptchaResponse

				case ffj_t_Handtekeningno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Voornaam:

	/* handler: uj.Voornaam type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.Voornaam = string(string(outBuf))
开发者ID:GeenPeil,项目名称:teken,代码行数:66,代码来源:handtekening.pb_ffjson.go

示例12: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_Outfit_ID:
					goto handle_ID

				case ffj_t_Outfit_Name:
					goto handle_Name

				case ffj_t_Outfit_NameLower:
					goto handle_NameLower

				case ffj_t_Outfit_Alias:
					goto handle_Alias

				case ffj_t_Outfit_AliasLower:
					goto handle_AliasLower

				case ffj_t_Outfit_TimeCreated:
					goto handle_TimeCreated

				case ffj_t_Outfit_LeaderCharID:
					goto handle_LeaderCharID

				case ffj_t_Outfit_MemberCount:
					goto handle_MemberCount

				case ffj_t_Outfitno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_ID:

	/* handler: uj.ID type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.ID = string(string(outBuf))
开发者ID:THUNDERGROOVE,项目名称:census,代码行数:66,代码来源:outfit_ffjson.go

示例13: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
				currentKey = ffj_t_Httpno_such_key
				state = fflib.FFParse_want_colon
				goto mainparse
			}

		case fflib.FFParse_want_colon:
			if tok != fflib.FFTok_colon {
				wantedTok = fflib.FFTok_colon
				goto wrongtokenerror
			}
			state = fflib.FFParse_want_value
			continue
		case fflib.FFParse_want_value:

			if tok == fflib.FFTok_left_brace || tok == fflib.FFTok_left_bracket || tok == fflib.FFTok_integer || tok == fflib.FFTok_double || tok == fflib.FFTok_string || tok == fflib.FFTok_bool || tok == fflib.FFTok_null {
				switch currentKey {

				case ffj_t_Http_Host:
					goto handle_Host

				case ffj_t_Http_Method:
					goto handle_Method

				case ffj_t_Http_Uri:
					goto handle_Uri

				case ffj_t_Http_Headers:
					goto handle_Headers

				case ffj_t_Http_Tag:
					goto handle_Tag

				case ffj_t_Httpno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Host:

	/* handler: uj.Host type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.Host = string(string(outBuf))
开发者ID:yandex,项目名称:pandora,代码行数:66,代码来源:http_ffjson.go

示例14: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
					goto handle_ProfileID

				case ffj_t_Character_Outfit:
					goto handle_Outfit

				case ffj_t_Character_OnlineStatus:
					goto handle_OnlineStatus

				case ffj_t_Character_Stats:
					goto handle_Stats

				case ffj_t_Character_Faction:
					goto handle_Faction

				case ffj_t_Character_Items:
					goto handle_Items

				case ffj_t_Character_FriendsList:
					goto handle_FriendsList

				case ffj_t_Character_World:
					goto handle_World

				case ffj_t_Character_Error:
					goto handle_Error

				case ffj_t_Character_Expires:
					goto handle_Expires

				case ffj_t_Character_LastUpdated:
					goto handle_LastUpdated

				case ffj_t_Characterno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_ID:

	/* handler: uj.ID type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.ID = string(string(outBuf))
开发者ID:THUNDERGROOVE,项目名称:census,代码行数:66,代码来源:character_ffjson.go

示例15: UnmarshalJSONFFLexer


//.........这里部分代码省略.........
					goto handle_Timestamp

				case ffj_t_WorkerEvent_PID:
					goto handle_PID

				case ffj_t_WorkerEvent_Clock:
					goto handle_Clock

				case ffj_t_WorkerEvent_UTCOffset:
					goto handle_UTCOffset

				case ffj_t_WorkerEvent_SWSystem:
					goto handle_SWSystem

				case ffj_t_WorkerEvent_SWVersion:
					goto handle_SWVersion

				case ffj_t_WorkerEvent_LoadAverage:
					goto handle_LoadAverage

				case ffj_t_WorkerEvent_Freq:
					goto handle_Freq

				case ffj_t_WorkerEvent_SWIdentity:
					goto handle_SWIdentity

				case ffj_t_WorkerEvent_Processed:
					goto handle_Processed

				case ffj_t_WorkerEvent_Active:
					goto handle_Active

				case ffj_t_WorkerEventno_such_key:
					err = fs.SkipField(tok)
					if err != nil {
						return fs.WrapErr(err)
					}
					state = fflib.FFParse_after_value
					goto mainparse
				}
			} else {
				goto wantedvalue
			}
		}
	}

handle_Type:

	/* handler: uj.Type type=string kind=string quoted=false*/

	{

		{
			if tok != fflib.FFTok_string && tok != fflib.FFTok_null {
				return fs.WrapErr(fmt.Errorf("cannot unmarshal %s into Go value for string", tok))
			}
		}

		if tok == fflib.FFTok_null {

		} else {

			outBuf := fs.Output.Bytes()

			uj.Type = string(string(outBuf))
开发者ID:tugouer,项目名称:celeriac.v1,代码行数:66,代码来源:task_event_ffjson.go


注:本文中的github.com/pquerna/ffjson/fflib/v1.FFLexer.SkipField方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。