當前位置: 首頁>>代碼示例>>Golang>>正文


Golang TProtocol.ReadI32方法代碼示例

本文整理匯總了Golang中git/apache/org/thrift/git/lib/go/thrift.TProtocol.ReadI32方法的典型用法代碼示例。如果您正苦於以下問題:Golang TProtocol.ReadI32方法的具體用法?Golang TProtocol.ReadI32怎麽用?Golang TProtocol.ReadI32使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在git/apache/org/thrift/git/lib/go/thrift.TProtocol的用法示例。


在下文中一共展示了TProtocol.ReadI32方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Golang代碼示例。

示例1: readField9

func (p *Types) readField9(iprot thrift.TProtocol) error {
	_, _, size, err := iprot.ReadMapBegin()
	if err != nil {
		return thrift.PrependError("error reading map begin: ", err)
	}
	tMap := make(map[string]int32, size)
	p.MapValue = tMap
	for i := 0; i < size; i++ {
		var _key2 string
		if v, err := iprot.ReadString(); err != nil {
			return thrift.PrependError("error reading field 0: ", err)
		} else {
			_key2 = v
		}
		var _val3 int32
		if v, err := iprot.ReadI32(); err != nil {
			return thrift.PrependError("error reading field 0: ", err)
		} else {
			_val3 = v
		}
		p.MapValue[_key2] = _val3
	}
	if err := iprot.ReadMapEnd(); err != nil {
		return thrift.PrependError("error reading map end: ", err)
	}
	return nil
}
開發者ID:y-okubo,項目名稱:thrift-test,代碼行數:27,代碼來源:ttypes.go

示例2: readField3

func (p *Request) readField3(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 3: %s")
	} else {
		p.Scope = v
	}
	return nil
}
開發者ID:tuhao,項目名稱:Thrift4AsyncMsg,代碼行數:8,代碼來源:ttypes.go

示例3: readField0

func (p *RpcServiceAddResult) readField0(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return thrift.PrependError("error reading field 0: ", err)
	} else {
		p.Success = &v
	}
	return nil
}
開發者ID:playnb,項目名稱:grasslands,代碼行數:8,代碼來源:rpcservice.go

示例4: ReadField1

func (p *RpcException) ReadField1(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return thrift.PrependError("error reading field 1: ", err)
	} else {
		p.Code = v
	}
	return nil
}
開發者ID:jinhy,項目名稱:rpc_proxy,代碼行數:8,代碼來源:ttypes.go

示例5: readField1

func (p *Work) readField1(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return thrift.PrependError("error reading field 1: ", err)
	} else {
		p.Num1 = v
	}
	return nil
}
開發者ID:sktzwhj,項目名稱:thrift-0.9.3,代碼行數:8,代碼來源:ttypes.go

示例6: ReadField6

func (p *GetResourceViewHistoryArgs) ReadField6(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 6: %s", err)
	} else {
		p.RowCount = v
	}
	return nil
}
開發者ID:lei-yu,項目名稱:GOPATH,代碼行數:8,代碼來源:resourcehistorymanager.go

示例7: ReadField2

func (p *FichaVisitaDomiciliarMasterThrift) ReadField2(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 2: %s", err)
	} else {
		p.TpCdsOrigem = &v
	}
	return nil
}
開發者ID:esusab,項目名稱:integracao,代碼行數:8,代碼來源:ttypes.go

示例8: readField1

func (p *UException) readField1(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 1: %s")
	} else {
		p.ErrorCode = v
	}
	return nil
}
開發者ID:NotBadPad,項目名稱:hbase-thrift-go,代碼行數:8,代碼來源:ttypes.go

示例9: ReadField2

func (p *AddArgs) ReadField2(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 2: %s", err)
	} else {
		p.Num2 = v
	}
	return nil
}
開發者ID:Workiva,項目名稱:thrift-nats,代碼行數:8,代碼來源:calculator.go

示例10: readField1

func (p *CalculatorCalculateArgs) readField1(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return thrift.PrependError("error reading field 1: ", err)
	} else {
		p.Logid = v
	}
	return nil
}
開發者ID:glycerine,項目名稱:golang-thrift-minimal-example,代碼行數:8,代碼來源:calculator.go

示例11: readField1

func (p *RequestInfo) readField1(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return thrift.PrependError("error reading field 1: ", err)
	} else {
		p.Type = v
	}
	return nil
}
開發者ID:rocflyhi,項目名稱:glow,代碼行數:8,代碼來源:ttypes.go

示例12: ReadField3

func (p *Item) ReadField3(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 3: %s", err)
	} else {
		p.Confidence = v
	}
	return nil
}
開發者ID:qqliu,項目名稱:kibitz,代碼行數:8,代碼來源:ttypes.go

示例13: ReadField3

func (p *GetTagsByUidArgs) ReadField3(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 3: %s", err)
	} else {
		p.RowCount = v
	}
	return nil
}
開發者ID:lei-yu,項目名稱:GOPATH,代碼行數:8,代碼來源:tagmanager.go

示例14: readField2

func (p *Ban) readField2(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return thrift.PrependError("error reading field 2: ", err)
	} else {
		p.Int32Field = &v
	}
	return nil
}
開發者ID:peter-edge,項目名稱:lion-go,代碼行數:8,代碼來源:ttypes.go

示例15: readField2

func (p *Data) readField2(iprot thrift.TProtocol) error {
	if v, err := iprot.ReadI32(); err != nil {
		return fmt.Errorf("error reading field 2: %s")
	} else {
		p.TypeA1 = Type(v)
	}
	return nil
}
開發者ID:tuhao,項目名稱:Thrift4AsyncMsg,代碼行數:8,代碼來源:ttypes.go


注:本文中的git/apache/org/thrift/git/lib/go/thrift.TProtocol.ReadI32方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。