// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: provenance/metadata/v1/scope.proto

package types

import (
	fmt "fmt"
	types "github.com/cosmos/cosmos-sdk/types"
	_ "github.com/cosmos/gogoproto/gogoproto"
	proto "github.com/cosmos/gogoproto/proto"
	github_com_cosmos_gogoproto_types "github.com/cosmos/gogoproto/types"
	_ "google.golang.org/protobuf/types/descriptorpb"
	_ "google.golang.org/protobuf/types/known/timestamppb"
	io "io"
	math "math"
	math_bits "math/bits"
	reflect "reflect"
	strings "strings"
	time "time"
)

// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
var _ = time.Kitchen

// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package

// A set of types for inputs on a record (of fact)
type RecordInputStatus int32

const (
	// RECORD_INPUT_STATUS_UNSPECIFIED indicates an invalid/unknown input type
	RecordInputStatus_Unknown RecordInputStatus = 0
	// RECORD_INPUT_STATUS_PROPOSED indicates this input was an arbitrary piece of data that was hashed
	RecordInputStatus_Proposed RecordInputStatus = 1
	// RECORD_INPUT_STATUS_RECORD indicates this input is a reference to a previously recorded fact on blockchain
	RecordInputStatus_Record RecordInputStatus = 2
)

var RecordInputStatus_name = map[int32]string{
	0: "RECORD_INPUT_STATUS_UNSPECIFIED",
	1: "RECORD_INPUT_STATUS_PROPOSED",
	2: "RECORD_INPUT_STATUS_RECORD",
}

var RecordInputStatus_value = map[string]int32{
	"RECORD_INPUT_STATUS_UNSPECIFIED": 0,
	"RECORD_INPUT_STATUS_PROPOSED":    1,
	"RECORD_INPUT_STATUS_RECORD":      2,
}

func (x RecordInputStatus) String() string {
	return proto.EnumName(RecordInputStatus_name, int32(x))
}

func (RecordInputStatus) EnumDescriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{0}
}

// ResultStatus indicates the various states of execution of a record
type ResultStatus int32

const (
	// RESULT_STATUS_UNSPECIFIED indicates an unset condition
	ResultStatus_RESULT_STATUS_UNSPECIFIED ResultStatus = 0
	// RESULT_STATUS_PASS indicates the execution was successful
	ResultStatus_RESULT_STATUS_PASS ResultStatus = 1
	// RESULT_STATUS_SKIP indicates condition/consideration was skipped due to missing inputs or delayed execution
	ResultStatus_RESULT_STATUS_SKIP ResultStatus = 2
	// RESULT_STATUS_FAIL indicates the execution of the condition/consideration failed.
	ResultStatus_RESULT_STATUS_FAIL ResultStatus = 3
)

var ResultStatus_name = map[int32]string{
	0: "RESULT_STATUS_UNSPECIFIED",
	1: "RESULT_STATUS_PASS",
	2: "RESULT_STATUS_SKIP",
	3: "RESULT_STATUS_FAIL",
}

var ResultStatus_value = map[string]int32{
	"RESULT_STATUS_UNSPECIFIED": 0,
	"RESULT_STATUS_PASS":        1,
	"RESULT_STATUS_SKIP":        2,
	"RESULT_STATUS_FAIL":        3,
}

func (x ResultStatus) String() string {
	return proto.EnumName(ResultStatus_name, int32(x))
}

func (ResultStatus) EnumDescriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{1}
}

// Scope defines a root reference for a collection of records owned by one or more parties.
type Scope struct {
	// Unique ID for this scope.  Implements sdk.Address interface for use where addresses are required in Cosmos
	ScopeId MetadataAddress `protobuf:"bytes,1,opt,name=scope_id,json=scopeId,proto3,customtype=MetadataAddress" json:"scope_id"`
	// the scope specification that contains the specifications for data elements allowed within this scope
	SpecificationId MetadataAddress `protobuf:"bytes,2,opt,name=specification_id,json=specificationId,proto3,customtype=MetadataAddress" json:"specification_id"`
	// These parties represent top level owners of the records within.  These parties must sign any requests that modify
	// the data within the scope.  These addresses are in union with parties listed on the sessions.
	Owners []Party `protobuf:"bytes,3,rep,name=owners,proto3" json:"owners"`
	// Addresses in this list are authorized to receive off-chain data associated with this scope.
	DataAccess []string `protobuf:"bytes,4,rep,name=data_access,json=dataAccess,proto3" json:"data_access,omitempty"`
	// The address that controls the value associated with this scope.
	//
	// The value owner is actually tracked by the bank module using a coin with the denom "nft/<scope_id>".
	// The value owner can be changed using WriteScope or anything that transfers funds, e.g. MsgSend.
	//
	// During WriteScope:
	//  - If this field is empty, it indicates that there should not be a change to the value owner.
	//    I.e. Once a scope has a value owner, it will always have one (until it's deleted).
	//  - If this field has a value, the existing value owner will be looked up, and
	//    - If there's already an existing value owner, they must be a signer,
	//      and the coin will be transferred to the new value owner.
	//    - If there isn't yet a value owner, the coin will be minted and sent to the new value owner.
	//      If the scope already exists, the owners must be signers (just like changing other fields).
	//      If it's a new scope, there's no special signer limitations related to the value owner.
	ValueOwnerAddress string `protobuf:"bytes,5,opt,name=value_owner_address,json=valueOwnerAddress,proto3" json:"value_owner_address,omitempty"`
	// Whether all parties in this scope and its sessions must be present in this scope's owners field.
	// This also enables use of optional=true scope owners and session parties.
	RequirePartyRollup bool `protobuf:"varint,6,opt,name=require_party_rollup,json=requirePartyRollup,proto3" json:"require_party_rollup,omitempty"`
}

func (m *Scope) Reset()      { *m = Scope{} }
func (*Scope) ProtoMessage() {}
func (*Scope) Descriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{0}
}
func (m *Scope) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Scope) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Scope.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *Scope) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Scope.Merge(m, src)
}
func (m *Scope) XXX_Size() int {
	return m.Size()
}
func (m *Scope) XXX_DiscardUnknown() {
	xxx_messageInfo_Scope.DiscardUnknown(m)
}

var xxx_messageInfo_Scope proto.InternalMessageInfo

func (m *Scope) GetOwners() []Party {
	if m != nil {
		return m.Owners
	}
	return nil
}

func (m *Scope) GetDataAccess() []string {
	if m != nil {
		return m.DataAccess
	}
	return nil
}

func (m *Scope) GetValueOwnerAddress() string {
	if m != nil {
		return m.ValueOwnerAddress
	}
	return ""
}

func (m *Scope) GetRequirePartyRollup() bool {
	if m != nil {
		return m.RequirePartyRollup
	}
	return false
}

// Session defines an execution context against a specific specification instance.
// The context will have a specification and set of parties involved.
//
// NOTE: When there are no more Records within a Scope that reference a Session, the Session is removed.
type Session struct {
	SessionId MetadataAddress `protobuf:"bytes,1,opt,name=session_id,json=sessionId,proto3,customtype=MetadataAddress" json:"session_id"`
	// unique id of the contract specification that was used to create this session.
	SpecificationId MetadataAddress `protobuf:"bytes,2,opt,name=specification_id,json=specificationId,proto3,customtype=MetadataAddress" json:"specification_id"`
	// parties is the set of identities that signed this contract
	Parties []Party `protobuf:"bytes,3,rep,name=parties,proto3" json:"parties"`
	// name to associate with this session execution context, typically classname
	Name string `protobuf:"bytes,4,opt,name=name,proto3" json:"name,omitempty"`
	// context is a field for storing client specific data associated with a session.
	Context []byte `protobuf:"bytes,5,opt,name=context,proto3" json:"context,omitempty"`
	// Created by, updated by, timestamps, version number, and related info.
	Audit *AuditFields `protobuf:"bytes,99,opt,name=audit,proto3" json:"audit,omitempty"`
}

func (m *Session) Reset()      { *m = Session{} }
func (*Session) ProtoMessage() {}
func (*Session) Descriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{1}
}
func (m *Session) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Session) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Session.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *Session) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Session.Merge(m, src)
}
func (m *Session) XXX_Size() int {
	return m.Size()
}
func (m *Session) XXX_DiscardUnknown() {
	xxx_messageInfo_Session.DiscardUnknown(m)
}

var xxx_messageInfo_Session proto.InternalMessageInfo

func (m *Session) GetParties() []Party {
	if m != nil {
		return m.Parties
	}
	return nil
}

func (m *Session) GetName() string {
	if m != nil {
		return m.Name
	}
	return ""
}

func (m *Session) GetContext() []byte {
	if m != nil {
		return m.Context
	}
	return nil
}

func (m *Session) GetAudit() *AuditFields {
	if m != nil {
		return m.Audit
	}
	return nil
}

// A record (of fact) is attached to a session or each consideration output from a contract
type Record struct {
	// name/identifier for this record.  Value must be unique within the scope.  Also known as a Fact name
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// id of the session context that was used to create this record (use with filtered kvprefix iterator)
	SessionId MetadataAddress `protobuf:"bytes,2,opt,name=session_id,json=sessionId,proto3,customtype=MetadataAddress" json:"session_id"`
	// process contain information used to uniquely identify an execution on or off chain that generated this record
	Process Process `protobuf:"bytes,3,opt,name=process,proto3" json:"process"`
	// inputs used with the process to achieve the output on this record
	Inputs []RecordInput `protobuf:"bytes,4,rep,name=inputs,proto3" json:"inputs"`
	// output(s) is the results of executing the process on the given process indicated in this record
	Outputs []RecordOutput `protobuf:"bytes,5,rep,name=outputs,proto3" json:"outputs"`
	// specification_id is the id of the record specification that was used to create this record.
	SpecificationId MetadataAddress `protobuf:"bytes,6,opt,name=specification_id,json=specificationId,proto3,customtype=MetadataAddress" json:"specification_id"`
}

func (m *Record) Reset()      { *m = Record{} }
func (*Record) ProtoMessage() {}
func (*Record) Descriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{2}
}
func (m *Record) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Record) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Record.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *Record) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Record.Merge(m, src)
}
func (m *Record) XXX_Size() int {
	return m.Size()
}
func (m *Record) XXX_DiscardUnknown() {
	xxx_messageInfo_Record.DiscardUnknown(m)
}

var xxx_messageInfo_Record proto.InternalMessageInfo

func (m *Record) GetName() string {
	if m != nil {
		return m.Name
	}
	return ""
}

func (m *Record) GetProcess() Process {
	if m != nil {
		return m.Process
	}
	return Process{}
}

func (m *Record) GetInputs() []RecordInput {
	if m != nil {
		return m.Inputs
	}
	return nil
}

func (m *Record) GetOutputs() []RecordOutput {
	if m != nil {
		return m.Outputs
	}
	return nil
}

// Process contains information used to uniquely identify what was used to generate this record
type Process struct {
	// unique identifier for this process
	//
	// Types that are valid to be assigned to ProcessId:
	//	*Process_Address
	//	*Process_Hash
	ProcessId isProcess_ProcessId `protobuf_oneof:"process_id"`
	// a name associated with the process (type_name, classname or smart contract common name)
	Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
	// method is a name or reference to a specific operation (method) within a class/contract that was invoked
	Method string `protobuf:"bytes,4,opt,name=method,proto3" json:"method,omitempty"`
}

func (m *Process) Reset()      { *m = Process{} }
func (*Process) ProtoMessage() {}
func (*Process) Descriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{3}
}
func (m *Process) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Process) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Process.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *Process) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Process.Merge(m, src)
}
func (m *Process) XXX_Size() int {
	return m.Size()
}
func (m *Process) XXX_DiscardUnknown() {
	xxx_messageInfo_Process.DiscardUnknown(m)
}

var xxx_messageInfo_Process proto.InternalMessageInfo

type isProcess_ProcessId interface {
	isProcess_ProcessId()
	MarshalTo([]byte) (int, error)
	Size() int
}

type Process_Address struct {
	Address string `protobuf:"bytes,1,opt,name=address,proto3,oneof" json:"address,omitempty"`
}
type Process_Hash struct {
	Hash string `protobuf:"bytes,2,opt,name=hash,proto3,oneof" json:"hash,omitempty"`
}

func (*Process_Address) isProcess_ProcessId() {}
func (*Process_Hash) isProcess_ProcessId()    {}

func (m *Process) GetProcessId() isProcess_ProcessId {
	if m != nil {
		return m.ProcessId
	}
	return nil
}

func (m *Process) GetAddress() string {
	if x, ok := m.GetProcessId().(*Process_Address); ok {
		return x.Address
	}
	return ""
}

func (m *Process) GetHash() string {
	if x, ok := m.GetProcessId().(*Process_Hash); ok {
		return x.Hash
	}
	return ""
}

func (m *Process) GetName() string {
	if m != nil {
		return m.Name
	}
	return ""
}

func (m *Process) GetMethod() string {
	if m != nil {
		return m.Method
	}
	return ""
}

// XXX_OneofWrappers is for the internal use of the proto package.
func (*Process) XXX_OneofWrappers() []interface{} {
	return []interface{}{
		(*Process_Address)(nil),
		(*Process_Hash)(nil),
	}
}

// Tracks the inputs used to establish this record
type RecordInput struct {
	// Name value included to link back to the definition spec.
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// data source
	//
	// Types that are valid to be assigned to Source:
	//	*RecordInput_RecordId
	//	*RecordInput_Hash
	Source isRecordInput_Source `protobuf_oneof:"source"`
	// from proposed fact structure to unmarshal
	TypeName string `protobuf:"bytes,4,opt,name=type_name,json=typeName,proto3" json:"type_name,omitempty"`
	// Indicates if this input was a recorded fact on chain or just a given hashed input
	Status RecordInputStatus `protobuf:"varint,5,opt,name=status,proto3,enum=provenance.metadata.v1.RecordInputStatus" json:"status,omitempty"`
}

func (m *RecordInput) Reset()      { *m = RecordInput{} }
func (*RecordInput) ProtoMessage() {}
func (*RecordInput) Descriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{4}
}
func (m *RecordInput) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *RecordInput) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_RecordInput.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *RecordInput) XXX_Merge(src proto.Message) {
	xxx_messageInfo_RecordInput.Merge(m, src)
}
func (m *RecordInput) XXX_Size() int {
	return m.Size()
}
func (m *RecordInput) XXX_DiscardUnknown() {
	xxx_messageInfo_RecordInput.DiscardUnknown(m)
}

var xxx_messageInfo_RecordInput proto.InternalMessageInfo

type isRecordInput_Source interface {
	isRecordInput_Source()
	MarshalTo([]byte) (int, error)
	Size() int
}

type RecordInput_RecordId struct {
	RecordId MetadataAddress `protobuf:"bytes,2,opt,name=record_id,json=recordId,proto3,oneof,customtype=MetadataAddress" json:"record_id,omitempty"`
}
type RecordInput_Hash struct {
	Hash string `protobuf:"bytes,3,opt,name=hash,proto3,oneof" json:"hash,omitempty"`
}

func (*RecordInput_RecordId) isRecordInput_Source() {}
func (*RecordInput_Hash) isRecordInput_Source()     {}

func (m *RecordInput) GetSource() isRecordInput_Source {
	if m != nil {
		return m.Source
	}
	return nil
}

func (m *RecordInput) GetName() string {
	if m != nil {
		return m.Name
	}
	return ""
}

func (m *RecordInput) GetHash() string {
	if x, ok := m.GetSource().(*RecordInput_Hash); ok {
		return x.Hash
	}
	return ""
}

func (m *RecordInput) GetTypeName() string {
	if m != nil {
		return m.TypeName
	}
	return ""
}

func (m *RecordInput) GetStatus() RecordInputStatus {
	if m != nil {
		return m.Status
	}
	return RecordInputStatus_Unknown
}

// XXX_OneofWrappers is for the internal use of the proto package.
func (*RecordInput) XXX_OneofWrappers() []interface{} {
	return []interface{}{
		(*RecordInput_RecordId)(nil),
		(*RecordInput_Hash)(nil),
	}
}

// RecordOutput encapsulates the output of a process recorded on chain
type RecordOutput struct {
	// Hash of the data output that was output/generated for this record
	Hash string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
	// Status of the process execution associated with this output indicating success,failure, or pending
	Status ResultStatus `protobuf:"varint,2,opt,name=status,proto3,enum=provenance.metadata.v1.ResultStatus" json:"status,omitempty"`
}

func (m *RecordOutput) Reset()      { *m = RecordOutput{} }
func (*RecordOutput) ProtoMessage() {}
func (*RecordOutput) Descriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{5}
}
func (m *RecordOutput) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *RecordOutput) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_RecordOutput.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *RecordOutput) XXX_Merge(src proto.Message) {
	xxx_messageInfo_RecordOutput.Merge(m, src)
}
func (m *RecordOutput) XXX_Size() int {
	return m.Size()
}
func (m *RecordOutput) XXX_DiscardUnknown() {
	xxx_messageInfo_RecordOutput.DiscardUnknown(m)
}

var xxx_messageInfo_RecordOutput proto.InternalMessageInfo

func (m *RecordOutput) GetHash() string {
	if m != nil {
		return m.Hash
	}
	return ""
}

func (m *RecordOutput) GetStatus() ResultStatus {
	if m != nil {
		return m.Status
	}
	return ResultStatus_RESULT_STATUS_UNSPECIFIED
}

// A Party is an address with/in a given role associated with a contract
type Party struct {
	// address of the account (on chain)
	Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	// a role for this account within the context of the processes used
	Role PartyType `protobuf:"varint,2,opt,name=role,proto3,enum=provenance.metadata.v1.PartyType" json:"role,omitempty"`
	// whether this party's signature is optional
	Optional bool `protobuf:"varint,3,opt,name=optional,proto3" json:"optional,omitempty"`
}

func (m *Party) Reset()      { *m = Party{} }
func (*Party) ProtoMessage() {}
func (*Party) Descriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{6}
}
func (m *Party) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *Party) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_Party.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *Party) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Party.Merge(m, src)
}
func (m *Party) XXX_Size() int {
	return m.Size()
}
func (m *Party) XXX_DiscardUnknown() {
	xxx_messageInfo_Party.DiscardUnknown(m)
}

var xxx_messageInfo_Party proto.InternalMessageInfo

func (m *Party) GetAddress() string {
	if m != nil {
		return m.Address
	}
	return ""
}

func (m *Party) GetRole() PartyType {
	if m != nil {
		return m.Role
	}
	return PartyType_PARTY_TYPE_UNSPECIFIED
}

func (m *Party) GetOptional() bool {
	if m != nil {
		return m.Optional
	}
	return false
}

// AuditFields capture information about the last account to make modifications and when they were made
type AuditFields struct {
	// the date/time when this entry was created
	CreatedDate time.Time `protobuf:"bytes,1,opt,name=created_date,json=createdDate,proto3,stdtime" json:"created_date"`
	// the address of the account that created this record
	CreatedBy string `protobuf:"bytes,2,opt,name=created_by,json=createdBy,proto3" json:"created_by,omitempty"`
	// the date/time when this entry was last updated
	UpdatedDate time.Time `protobuf:"bytes,3,opt,name=updated_date,json=updatedDate,proto3,stdtime" json:"updated_date"`
	// the address of the account that modified this record
	UpdatedBy string `protobuf:"bytes,4,opt,name=updated_by,json=updatedBy,proto3" json:"updated_by,omitempty"`
	// an optional version number that is incremented with each update
	Version uint32 `protobuf:"varint,5,opt,name=version,proto3" json:"version,omitempty"`
	// an optional message associated with the creation/update event
	Message string `protobuf:"bytes,6,opt,name=message,proto3" json:"message,omitempty"`
}

func (m *AuditFields) Reset()         { *m = AuditFields{} }
func (m *AuditFields) String() string { return proto.CompactTextString(m) }
func (*AuditFields) ProtoMessage()    {}
func (*AuditFields) Descriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{7}
}
func (m *AuditFields) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *AuditFields) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_AuditFields.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *AuditFields) XXX_Merge(src proto.Message) {
	xxx_messageInfo_AuditFields.Merge(m, src)
}
func (m *AuditFields) XXX_Size() int {
	return m.Size()
}
func (m *AuditFields) XXX_DiscardUnknown() {
	xxx_messageInfo_AuditFields.DiscardUnknown(m)
}

var xxx_messageInfo_AuditFields proto.InternalMessageInfo

func (m *AuditFields) GetCreatedDate() time.Time {
	if m != nil {
		return m.CreatedDate
	}
	return time.Time{}
}

func (m *AuditFields) GetCreatedBy() string {
	if m != nil {
		return m.CreatedBy
	}
	return ""
}

func (m *AuditFields) GetUpdatedDate() time.Time {
	if m != nil {
		return m.UpdatedDate
	}
	return time.Time{}
}

func (m *AuditFields) GetUpdatedBy() string {
	if m != nil {
		return m.UpdatedBy
	}
	return ""
}

func (m *AuditFields) GetVersion() uint32 {
	if m != nil {
		return m.Version
	}
	return 0
}

func (m *AuditFields) GetMessage() string {
	if m != nil {
		return m.Message
	}
	return ""
}

// NetAssetValue defines a scope's net asset value
type NetAssetValue struct {
	// price is the complete value of the asset's volume
	Price types.Coin `protobuf:"bytes,1,opt,name=price,proto3" json:"price"`
	// updated_block_height is the block height of last update
	UpdatedBlockHeight uint64 `protobuf:"varint,2,opt,name=updated_block_height,json=updatedBlockHeight,proto3" json:"updated_block_height,omitempty"`
	// volume is the number of scope instances that were purchased for the price
	// Typically this will be null (equivalent to one) or one.  The only reason this would be more than
	// one is for cases where the precision of the price denom is insufficient to represent the actual price
	Volume uint64 `protobuf:"varint,3,opt,name=volume,proto3" json:"volume,omitempty"`
}

func (m *NetAssetValue) Reset()         { *m = NetAssetValue{} }
func (m *NetAssetValue) String() string { return proto.CompactTextString(m) }
func (*NetAssetValue) ProtoMessage()    {}
func (*NetAssetValue) Descriptor() ([]byte, []int) {
	return fileDescriptor_edeea634bfb18aba, []int{8}
}
func (m *NetAssetValue) XXX_Unmarshal(b []byte) error {
	return m.Unmarshal(b)
}
func (m *NetAssetValue) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	if deterministic {
		return xxx_messageInfo_NetAssetValue.Marshal(b, m, deterministic)
	} else {
		b = b[:cap(b)]
		n, err := m.MarshalToSizedBuffer(b)
		if err != nil {
			return nil, err
		}
		return b[:n], nil
	}
}
func (m *NetAssetValue) XXX_Merge(src proto.Message) {
	xxx_messageInfo_NetAssetValue.Merge(m, src)
}
func (m *NetAssetValue) XXX_Size() int {
	return m.Size()
}
func (m *NetAssetValue) XXX_DiscardUnknown() {
	xxx_messageInfo_NetAssetValue.DiscardUnknown(m)
}

var xxx_messageInfo_NetAssetValue proto.InternalMessageInfo

func (m *NetAssetValue) GetPrice() types.Coin {
	if m != nil {
		return m.Price
	}
	return types.Coin{}
}

func (m *NetAssetValue) GetUpdatedBlockHeight() uint64 {
	if m != nil {
		return m.UpdatedBlockHeight
	}
	return 0
}

func (m *NetAssetValue) GetVolume() uint64 {
	if m != nil {
		return m.Volume
	}
	return 0
}

func init() {
	proto.RegisterEnum("provenance.metadata.v1.RecordInputStatus", RecordInputStatus_name, RecordInputStatus_value)
	proto.RegisterEnum("provenance.metadata.v1.ResultStatus", ResultStatus_name, ResultStatus_value)
	proto.RegisterType((*Scope)(nil), "provenance.metadata.v1.Scope")
	proto.RegisterType((*Session)(nil), "provenance.metadata.v1.Session")
	proto.RegisterType((*Record)(nil), "provenance.metadata.v1.Record")
	proto.RegisterType((*Process)(nil), "provenance.metadata.v1.Process")
	proto.RegisterType((*RecordInput)(nil), "provenance.metadata.v1.RecordInput")
	proto.RegisterType((*RecordOutput)(nil), "provenance.metadata.v1.RecordOutput")
	proto.RegisterType((*Party)(nil), "provenance.metadata.v1.Party")
	proto.RegisterType((*AuditFields)(nil), "provenance.metadata.v1.AuditFields")
	proto.RegisterType((*NetAssetValue)(nil), "provenance.metadata.v1.NetAssetValue")
}

func init() {
	proto.RegisterFile("provenance/metadata/v1/scope.proto", fileDescriptor_edeea634bfb18aba)
}

var fileDescriptor_edeea634bfb18aba = []byte{
	// 1138 bytes of a gzipped FileDescriptorProto
	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x56, 0x4f, 0x6f, 0x1b, 0x45,
	0x14, 0xf7, 0xfa, 0xbf, 0x9f, 0x5d, 0xea, 0x4e, 0xab, 0xe2, 0x1a, 0x6a, 0x1b, 0xc3, 0xc1, 0x44,
	0x62, 0xdd, 0x18, 0x8a, 0x44, 0x01, 0x21, 0xbb, 0x49, 0xa9, 0x45, 0x49, 0xac, 0x71, 0xc2, 0x81,
	0xcb, 0x6a, 0xbd, 0x3b, 0xb5, 0x57, 0xb1, 0x77, 0x96, 0x9d, 0x59, 0xb7, 0x86, 0x0b, 0xe7, 0x9c,
	0xc2, 0x8d, 0x4b, 0x24, 0xf8, 0x14, 0x7c, 0x85, 0x72, 0xeb, 0x11, 0x01, 0x2a, 0x28, 0xb9, 0xf2,
	0x21, 0xd0, 0xcc, 0xce, 0xfa, 0x0f, 0x71, 0xa2, 0x44, 0xe2, 0xb6, 0xef, 0xbd, 0xdf, 0x9b, 0xf7,
	0xde, 0xef, 0xbd, 0x37, 0xb3, 0x50, 0xf7, 0x7c, 0x3a, 0x25, 0xae, 0xe9, 0x5a, 0xa4, 0x39, 0x21,
	0xdc, 0xb4, 0x4d, 0x6e, 0x36, 0xa7, 0x9b, 0x4d, 0x66, 0x51, 0x8f, 0xe8, 0x9e, 0x4f, 0x39, 0x45,
	0xb7, 0x17, 0x18, 0x3d, 0xc2, 0xe8, 0xd3, 0xcd, 0x72, 0xc5, 0xa2, 0x6c,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d, 0x62, 0xfc, 0xac, 0xfe,
	0x51, 0xbb, 0xfb, 0xa4, 0x98, 0xe8, 0x1c, 0xbc, 0x38, 0xa9, 0x68, 0x2f, 0x4f, 0x2a, 0xda, 0xdf,
	0x27, 0x15, 0xed, 0xe8, 0xb4, 0x12, 0x7b, 0x79, 0x5a, 0x89, 0xfd, 0x76, 0x5a, 0x89, 0xc1, 0x1d,
	0x87, 0x9e, 0xb3, 0x28, 0x3d, 0xed, 0xeb, 0x0f, 0x86, 0x0e, 0x1f, 0x05, 0x03, 0xdd, 0xa2, 0x93,
	0xe6, 0x02, 0xf4, 0x9e, 0x43, 0x97, 0xa4, 0xe6, 0xf3, 0xc5, 0x3f, 0x97, 0xb8, 0x68, 0xd8, 0x20,
	0x2d, 0x07, 0xf3, 0xfd, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x7d, 0x50, 0x80, 0x91, 0x4c, 0x0a,
	0x00, 0x00,
}

func (m *Scope) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Scope) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Scope) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.RequirePartyRollup {
		i--
		if m.RequirePartyRollup {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i--
		dAtA[i] = 0x30
	}
	if len(m.ValueOwnerAddress) > 0 {
		i -= len(m.ValueOwnerAddress)
		copy(dAtA[i:], m.ValueOwnerAddress)
		i = encodeVarintScope(dAtA, i, uint64(len(m.ValueOwnerAddress)))
		i--
		dAtA[i] = 0x2a
	}
	if len(m.DataAccess) > 0 {
		for iNdEx := len(m.DataAccess) - 1; iNdEx >= 0; iNdEx-- {
			i -= len(m.DataAccess[iNdEx])
			copy(dAtA[i:], m.DataAccess[iNdEx])
			i = encodeVarintScope(dAtA, i, uint64(len(m.DataAccess[iNdEx])))
			i--
			dAtA[i] = 0x22
		}
	}
	if len(m.Owners) > 0 {
		for iNdEx := len(m.Owners) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Owners[iNdEx].MarshalToSizedBuffer(dAtA[:i])
				if err != nil {
					return 0, err
				}
				i -= size
				i = encodeVarintScope(dAtA, i, uint64(size))
			}
			i--
			dAtA[i] = 0x1a
		}
	}
	{
		size := m.SpecificationId.Size()
		i -= size
		if _, err := m.SpecificationId.MarshalTo(dAtA[i:]); err != nil {
			return 0, err
		}
		i = encodeVarintScope(dAtA, i, uint64(size))
	}
	i--
	dAtA[i] = 0x12
	{
		size := m.ScopeId.Size()
		i -= size
		if _, err := m.ScopeId.MarshalTo(dAtA[i:]); err != nil {
			return 0, err
		}
		i = encodeVarintScope(dAtA, i, uint64(size))
	}
	i--
	dAtA[i] = 0xa
	return len(dAtA) - i, nil
}

func (m *Session) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Session) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Session) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Audit != nil {
		{
			size, err := m.Audit.MarshalToSizedBuffer(dAtA[:i])
			if err != nil {
				return 0, err
			}
			i -= size
			i = encodeVarintScope(dAtA, i, uint64(size))
		}
		i--
		dAtA[i] = 0x6
		i--
		dAtA[i] = 0x9a
	}
	if len(m.Context) > 0 {
		i -= len(m.Context)
		copy(dAtA[i:], m.Context)
		i = encodeVarintScope(dAtA, i, uint64(len(m.Context)))
		i--
		dAtA[i] = 0x2a
	}
	if len(m.Name) > 0 {
		i -= len(m.Name)
		copy(dAtA[i:], m.Name)
		i = encodeVarintScope(dAtA, i, uint64(len(m.Name)))
		i--
		dAtA[i] = 0x22
	}
	if len(m.Parties) > 0 {
		for iNdEx := len(m.Parties) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Parties[iNdEx].MarshalToSizedBuffer(dAtA[:i])
				if err != nil {
					return 0, err
				}
				i -= size
				i = encodeVarintScope(dAtA, i, uint64(size))
			}
			i--
			dAtA[i] = 0x1a
		}
	}
	{
		size := m.SpecificationId.Size()
		i -= size
		if _, err := m.SpecificationId.MarshalTo(dAtA[i:]); err != nil {
			return 0, err
		}
		i = encodeVarintScope(dAtA, i, uint64(size))
	}
	i--
	dAtA[i] = 0x12
	{
		size := m.SessionId.Size()
		i -= size
		if _, err := m.SessionId.MarshalTo(dAtA[i:]); err != nil {
			return 0, err
		}
		i = encodeVarintScope(dAtA, i, uint64(size))
	}
	i--
	dAtA[i] = 0xa
	return len(dAtA) - i, nil
}

func (m *Record) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Record) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Record) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	{
		size := m.SpecificationId.Size()
		i -= size
		if _, err := m.SpecificationId.MarshalTo(dAtA[i:]); err != nil {
			return 0, err
		}
		i = encodeVarintScope(dAtA, i, uint64(size))
	}
	i--
	dAtA[i] = 0x32
	if len(m.Outputs) > 0 {
		for iNdEx := len(m.Outputs) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Outputs[iNdEx].MarshalToSizedBuffer(dAtA[:i])
				if err != nil {
					return 0, err
				}
				i -= size
				i = encodeVarintScope(dAtA, i, uint64(size))
			}
			i--
			dAtA[i] = 0x2a
		}
	}
	if len(m.Inputs) > 0 {
		for iNdEx := len(m.Inputs) - 1; iNdEx >= 0; iNdEx-- {
			{
				size, err := m.Inputs[iNdEx].MarshalToSizedBuffer(dAtA[:i])
				if err != nil {
					return 0, err
				}
				i -= size
				i = encodeVarintScope(dAtA, i, uint64(size))
			}
			i--
			dAtA[i] = 0x22
		}
	}
	{
		size, err := m.Process.MarshalToSizedBuffer(dAtA[:i])
		if err != nil {
			return 0, err
		}
		i -= size
		i = encodeVarintScope(dAtA, i, uint64(size))
	}
	i--
	dAtA[i] = 0x1a
	{
		size := m.SessionId.Size()
		i -= size
		if _, err := m.SessionId.MarshalTo(dAtA[i:]); err != nil {
			return 0, err
		}
		i = encodeVarintScope(dAtA, i, uint64(size))
	}
	i--
	dAtA[i] = 0x12
	if len(m.Name) > 0 {
		i -= len(m.Name)
		copy(dAtA[i:], m.Name)
		i = encodeVarintScope(dAtA, i, uint64(len(m.Name)))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *Process) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Process) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Process) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.Method) > 0 {
		i -= len(m.Method)
		copy(dAtA[i:], m.Method)
		i = encodeVarintScope(dAtA, i, uint64(len(m.Method)))
		i--
		dAtA[i] = 0x22
	}
	if len(m.Name) > 0 {
		i -= len(m.Name)
		copy(dAtA[i:], m.Name)
		i = encodeVarintScope(dAtA, i, uint64(len(m.Name)))
		i--
		dAtA[i] = 0x1a
	}
	if m.ProcessId != nil {
		{
			size := m.ProcessId.Size()
			i -= size
			if _, err := m.ProcessId.MarshalTo(dAtA[i:]); err != nil {
				return 0, err
			}
		}
	}
	return len(dAtA) - i, nil
}

func (m *Process_Address) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Process_Address) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	i -= len(m.Address)
	copy(dAtA[i:], m.Address)
	i = encodeVarintScope(dAtA, i, uint64(len(m.Address)))
	i--
	dAtA[i] = 0xa
	return len(dAtA) - i, nil
}
func (m *Process_Hash) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Process_Hash) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	i -= len(m.Hash)
	copy(dAtA[i:], m.Hash)
	i = encodeVarintScope(dAtA, i, uint64(len(m.Hash)))
	i--
	dAtA[i] = 0x12
	return len(dAtA) - i, nil
}
func (m *RecordInput) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *RecordInput) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *RecordInput) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Status != 0 {
		i = encodeVarintScope(dAtA, i, uint64(m.Status))
		i--
		dAtA[i] = 0x28
	}
	if len(m.TypeName) > 0 {
		i -= len(m.TypeName)
		copy(dAtA[i:], m.TypeName)
		i = encodeVarintScope(dAtA, i, uint64(len(m.TypeName)))
		i--
		dAtA[i] = 0x22
	}
	if m.Source != nil {
		{
			size := m.Source.Size()
			i -= size
			if _, err := m.Source.MarshalTo(dAtA[i:]); err != nil {
				return 0, err
			}
		}
	}
	if len(m.Name) > 0 {
		i -= len(m.Name)
		copy(dAtA[i:], m.Name)
		i = encodeVarintScope(dAtA, i, uint64(len(m.Name)))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *RecordInput_RecordId) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *RecordInput_RecordId) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	{
		size := m.RecordId.Size()
		i -= size
		if _, err := m.RecordId.MarshalTo(dAtA[i:]); err != nil {
			return 0, err
		}
		i = encodeVarintScope(dAtA, i, uint64(size))
	}
	i--
	dAtA[i] = 0x12
	return len(dAtA) - i, nil
}
func (m *RecordInput_Hash) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *RecordInput_Hash) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	i -= len(m.Hash)
	copy(dAtA[i:], m.Hash)
	i = encodeVarintScope(dAtA, i, uint64(len(m.Hash)))
	i--
	dAtA[i] = 0x1a
	return len(dAtA) - i, nil
}
func (m *RecordOutput) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *RecordOutput) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *RecordOutput) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Status != 0 {
		i = encodeVarintScope(dAtA, i, uint64(m.Status))
		i--
		dAtA[i] = 0x10
	}
	if len(m.Hash) > 0 {
		i -= len(m.Hash)
		copy(dAtA[i:], m.Hash)
		i = encodeVarintScope(dAtA, i, uint64(len(m.Hash)))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *Party) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *Party) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *Party) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Optional {
		i--
		if m.Optional {
			dAtA[i] = 1
		} else {
			dAtA[i] = 0
		}
		i--
		dAtA[i] = 0x18
	}
	if m.Role != 0 {
		i = encodeVarintScope(dAtA, i, uint64(m.Role))
		i--
		dAtA[i] = 0x10
	}
	if len(m.Address) > 0 {
		i -= len(m.Address)
		copy(dAtA[i:], m.Address)
		i = encodeVarintScope(dAtA, i, uint64(len(m.Address)))
		i--
		dAtA[i] = 0xa
	}
	return len(dAtA) - i, nil
}

func (m *AuditFields) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *AuditFields) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *AuditFields) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if len(m.Message) > 0 {
		i -= len(m.Message)
		copy(dAtA[i:], m.Message)
		i = encodeVarintScope(dAtA, i, uint64(len(m.Message)))
		i--
		dAtA[i] = 0x32
	}
	if m.Version != 0 {
		i = encodeVarintScope(dAtA, i, uint64(m.Version))
		i--
		dAtA[i] = 0x28
	}
	if len(m.UpdatedBy) > 0 {
		i -= len(m.UpdatedBy)
		copy(dAtA[i:], m.UpdatedBy)
		i = encodeVarintScope(dAtA, i, uint64(len(m.UpdatedBy)))
		i--
		dAtA[i] = 0x22
	}
	n3, err3 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.UpdatedDate, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.UpdatedDate):])
	if err3 != nil {
		return 0, err3
	}
	i -= n3
	i = encodeVarintScope(dAtA, i, uint64(n3))
	i--
	dAtA[i] = 0x1a
	if len(m.CreatedBy) > 0 {
		i -= len(m.CreatedBy)
		copy(dAtA[i:], m.CreatedBy)
		i = encodeVarintScope(dAtA, i, uint64(len(m.CreatedBy)))
		i--
		dAtA[i] = 0x12
	}
	n4, err4 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.CreatedDate, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.CreatedDate):])
	if err4 != nil {
		return 0, err4
	}
	i -= n4
	i = encodeVarintScope(dAtA, i, uint64(n4))
	i--
	dAtA[i] = 0xa
	return len(dAtA) - i, nil
}

func (m *NetAssetValue) Marshal() (dAtA []byte, err error) {
	size := m.Size()
	dAtA = make([]byte, size)
	n, err := m.MarshalToSizedBuffer(dAtA[:size])
	if err != nil {
		return nil, err
	}
	return dAtA[:n], nil
}

func (m *NetAssetValue) MarshalTo(dAtA []byte) (int, error) {
	size := m.Size()
	return m.MarshalToSizedBuffer(dAtA[:size])
}

func (m *NetAssetValue) MarshalToSizedBuffer(dAtA []byte) (int, error) {
	i := len(dAtA)
	_ = i
	var l int
	_ = l
	if m.Volume != 0 {
		i = encodeVarintScope(dAtA, i, uint64(m.Volume))
		i--
		dAtA[i] = 0x18
	}
	if m.UpdatedBlockHeight != 0 {
		i = encodeVarintScope(dAtA, i, uint64(m.UpdatedBlockHeight))
		i--
		dAtA[i] = 0x10
	}
	{
		size, err := m.Price.MarshalToSizedBuffer(dAtA[:i])
		if err != nil {
			return 0, err
		}
		i -= size
		i = encodeVarintScope(dAtA, i, uint64(size))
	}
	i--
	dAtA[i] = 0xa
	return len(dAtA) - i, nil
}

func encodeVarintScope(dAtA []byte, offset int, v uint64) int {
	offset -= sovScope(v)
	base := offset
	for v >= 1<<7 {
		dAtA[offset] = uint8(v&0x7f | 0x80)
		v >>= 7
		offset++
	}
	dAtA[offset] = uint8(v)
	return base
}
func (m *Scope) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = m.ScopeId.Size()
	n += 1 + l + sovScope(uint64(l))
	l = m.SpecificationId.Size()
	n += 1 + l + sovScope(uint64(l))
	if len(m.Owners) > 0 {
		for _, e := range m.Owners {
			l = e.Size()
			n += 1 + l + sovScope(uint64(l))
		}
	}
	if len(m.DataAccess) > 0 {
		for _, s := range m.DataAccess {
			l = len(s)
			n += 1 + l + sovScope(uint64(l))
		}
	}
	l = len(m.ValueOwnerAddress)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	if m.RequirePartyRollup {
		n += 2
	}
	return n
}

func (m *Session) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = m.SessionId.Size()
	n += 1 + l + sovScope(uint64(l))
	l = m.SpecificationId.Size()
	n += 1 + l + sovScope(uint64(l))
	if len(m.Parties) > 0 {
		for _, e := range m.Parties {
			l = e.Size()
			n += 1 + l + sovScope(uint64(l))
		}
	}
	l = len(m.Name)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	l = len(m.Context)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	if m.Audit != nil {
		l = m.Audit.Size()
		n += 2 + l + sovScope(uint64(l))
	}
	return n
}

func (m *Record) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Name)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	l = m.SessionId.Size()
	n += 1 + l + sovScope(uint64(l))
	l = m.Process.Size()
	n += 1 + l + sovScope(uint64(l))
	if len(m.Inputs) > 0 {
		for _, e := range m.Inputs {
			l = e.Size()
			n += 1 + l + sovScope(uint64(l))
		}
	}
	if len(m.Outputs) > 0 {
		for _, e := range m.Outputs {
			l = e.Size()
			n += 1 + l + sovScope(uint64(l))
		}
	}
	l = m.SpecificationId.Size()
	n += 1 + l + sovScope(uint64(l))
	return n
}

func (m *Process) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	if m.ProcessId != nil {
		n += m.ProcessId.Size()
	}
	l = len(m.Name)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	l = len(m.Method)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	return n
}

func (m *Process_Address) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Address)
	n += 1 + l + sovScope(uint64(l))
	return n
}
func (m *Process_Hash) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Hash)
	n += 1 + l + sovScope(uint64(l))
	return n
}
func (m *RecordInput) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Name)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	if m.Source != nil {
		n += m.Source.Size()
	}
	l = len(m.TypeName)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	if m.Status != 0 {
		n += 1 + sovScope(uint64(m.Status))
	}
	return n
}

func (m *RecordInput_RecordId) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = m.RecordId.Size()
	n += 1 + l + sovScope(uint64(l))
	return n
}
func (m *RecordInput_Hash) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Hash)
	n += 1 + l + sovScope(uint64(l))
	return n
}
func (m *RecordOutput) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Hash)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	if m.Status != 0 {
		n += 1 + sovScope(uint64(m.Status))
	}
	return n
}

func (m *Party) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = len(m.Address)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	if m.Role != 0 {
		n += 1 + sovScope(uint64(m.Role))
	}
	if m.Optional {
		n += 2
	}
	return n
}

func (m *AuditFields) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = github_com_cosmos_gogoproto_types.SizeOfStdTime(m.CreatedDate)
	n += 1 + l + sovScope(uint64(l))
	l = len(m.CreatedBy)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	l = github_com_cosmos_gogoproto_types.SizeOfStdTime(m.UpdatedDate)
	n += 1 + l + sovScope(uint64(l))
	l = len(m.UpdatedBy)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	if m.Version != 0 {
		n += 1 + sovScope(uint64(m.Version))
	}
	l = len(m.Message)
	if l > 0 {
		n += 1 + l + sovScope(uint64(l))
	}
	return n
}

func (m *NetAssetValue) Size() (n int) {
	if m == nil {
		return 0
	}
	var l int
	_ = l
	l = m.Price.Size()
	n += 1 + l + sovScope(uint64(l))
	if m.UpdatedBlockHeight != 0 {
		n += 1 + sovScope(uint64(m.UpdatedBlockHeight))
	}
	if m.Volume != 0 {
		n += 1 + sovScope(uint64(m.Volume))
	}
	return n
}

func sovScope(x uint64) (n int) {
	return (math_bits.Len64(x|1) + 6) / 7
}
func sozScope(x uint64) (n int) {
	return sovScope(uint64((x << 1) ^ uint64((int64(x) >> 63))))
}
func (this *Scope) String() string {
	if this == nil {
		return "nil"
	}
	repeatedStringForOwners := "[]Party{"
	for _, f := range this.Owners {
		repeatedStringForOwners += fmt.Sprintf("%v", f) + ","
	}
	repeatedStringForOwners += "}"
	s := strings.Join([]string{`&Scope{`,
		`ScopeId:` + fmt.Sprintf("%v", this.ScopeId) + `,`,
		`SpecificationId:` + fmt.Sprintf("%v", this.SpecificationId) + `,`,
		`Owners:` + repeatedStringForOwners + `,`,
		`DataAccess:` + fmt.Sprintf("%v", this.DataAccess) + `,`,
		`ValueOwnerAddress:` + fmt.Sprintf("%v", this.ValueOwnerAddress) + `,`,
		`RequirePartyRollup:` + fmt.Sprintf("%v", this.RequirePartyRollup) + `,`,
		`}`,
	}, "")
	return s
}
func (this *Session) String() string {
	if this == nil {
		return "nil"
	}
	repeatedStringForParties := "[]Party{"
	for _, f := range this.Parties {
		repeatedStringForParties += fmt.Sprintf("%v", f) + ","
	}
	repeatedStringForParties += "}"
	s := strings.Join([]string{`&Session{`,
		`SessionId:` + fmt.Sprintf("%v", this.SessionId) + `,`,
		`SpecificationId:` + fmt.Sprintf("%v", this.SpecificationId) + `,`,
		`Parties:` + repeatedStringForParties + `,`,
		`Name:` + fmt.Sprintf("%v", this.Name) + `,`,
		`Context:` + fmt.Sprintf("%v", this.Context) + `,`,
		`Audit:` + strings.Replace(fmt.Sprintf("%v", this.Audit), "AuditFields", "AuditFields", 1) + `,`,
		`}`,
	}, "")
	return s
}
func (this *Record) String() string {
	if this == nil {
		return "nil"
	}
	repeatedStringForInputs := "[]RecordInput{"
	for _, f := range this.Inputs {
		repeatedStringForInputs += fmt.Sprintf("%v", f) + ","
	}
	repeatedStringForInputs += "}"
	repeatedStringForOutputs := "[]RecordOutput{"
	for _, f := range this.Outputs {
		repeatedStringForOutputs += fmt.Sprintf("%v", f) + ","
	}
	repeatedStringForOutputs += "}"
	s := strings.Join([]string{`&Record{`,
		`Name:` + fmt.Sprintf("%v", this.Name) + `,`,
		`SessionId:` + fmt.Sprintf("%v", this.SessionId) + `,`,
		`Process:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Process), "Process", "Process", 1), `&`, ``, 1) + `,`,
		`Inputs:` + repeatedStringForInputs + `,`,
		`Outputs:` + repeatedStringForOutputs + `,`,
		`SpecificationId:` + fmt.Sprintf("%v", this.SpecificationId) + `,`,
		`}`,
	}, "")
	return s
}
func valueToStringScope(v interface{}) string {
	rv := reflect.ValueOf(v)
	if rv.IsNil() {
		return "nil"
	}
	pv := reflect.Indirect(rv).Interface()
	return fmt.Sprintf("*%v", pv)
}
func (m *Scope) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowScope
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Scope: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Scope: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ScopeId", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := m.ScopeId.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field SpecificationId", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := m.SpecificationId.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Owners", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Owners = append(m.Owners, Party{})
			if err := m.Owners[len(m.Owners)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field DataAccess", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.DataAccess = append(m.DataAccess, string(dAtA[iNdEx:postIndex]))
			iNdEx = postIndex
		case 5:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field ValueOwnerAddress", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ValueOwnerAddress = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 6:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field RequirePartyRollup", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				v |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			m.RequirePartyRollup = bool(v != 0)
		default:
			iNdEx = preIndex
			skippy, err := skipScope(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthScope
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Session) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowScope
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Session: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Session: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field SessionId", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := m.SessionId.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field SpecificationId", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := m.SpecificationId.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Parties", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Parties = append(m.Parties, Party{})
			if err := m.Parties[len(m.Parties)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Name = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Context", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Context = append(m.Context[:0], dAtA[iNdEx:postIndex]...)
			if m.Context == nil {
				m.Context = []byte{}
			}
			iNdEx = postIndex
		case 99:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Audit", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if m.Audit == nil {
				m.Audit = &AuditFields{}
			}
			if err := m.Audit.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipScope(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthScope
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Record) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowScope
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Record: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Record: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Name = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field SessionId", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := m.SessionId.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Process", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := m.Process.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Inputs", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Inputs = append(m.Inputs, RecordInput{})
			if err := m.Inputs[len(m.Inputs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 5:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Outputs", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Outputs = append(m.Outputs, RecordOutput{})
			if err := m.Outputs[len(m.Outputs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 6:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field SpecificationId", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := m.SpecificationId.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipScope(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthScope
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Process) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowScope
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Process: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Process: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ProcessId = &Process_Address{string(dAtA[iNdEx:postIndex])}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Hash", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.ProcessId = &Process_Hash{string(dAtA[iNdEx:postIndex])}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Name = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Method", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Method = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipScope(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthScope
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *RecordInput) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowScope
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: RecordInput: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: RecordInput: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Name = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field RecordId", wireType)
			}
			var byteLen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				byteLen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if byteLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + byteLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			var vv MetadataAddress
			v := &vv
			if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			m.Source = &RecordInput_RecordId{*v}
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Hash", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Source = &RecordInput_Hash{string(dAtA[iNdEx:postIndex])}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field TypeName", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.TypeName = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
			}
			m.Status = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Status |= RecordInputStatus(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipScope(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthScope
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *RecordOutput) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowScope
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: RecordOutput: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: RecordOutput: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Hash", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Hash = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
			}
			m.Status = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Status |= ResultStatus(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipScope(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthScope
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *Party) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowScope
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: Party: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: Party: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Address = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Role", wireType)
			}
			m.Role = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Role |= PartyType(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType)
			}
			var v int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				v |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			m.Optional = bool(v != 0)
		default:
			iNdEx = preIndex
			skippy, err := skipScope(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthScope
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *AuditFields) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowScope
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: AuditFields: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: AuditFields: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field CreatedDate", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(&m.CreatedDate, dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 2:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field CreatedBy", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.CreatedBy = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 3:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field UpdatedDate", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(&m.UpdatedDate, dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 4:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field UpdatedBy", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.UpdatedBy = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		case 5:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType)
			}
			m.Version = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Version |= uint32(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 6:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
			}
			var stringLen uint64
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				stringLen |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			intStringLen := int(stringLen)
			if intStringLen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + intStringLen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			m.Message = string(dAtA[iNdEx:postIndex])
			iNdEx = postIndex
		default:
			iNdEx = preIndex
			skippy, err := skipScope(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthScope
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func (m *NetAssetValue) Unmarshal(dAtA []byte) error {
	l := len(dAtA)
	iNdEx := 0
	for iNdEx < l {
		preIndex := iNdEx
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return ErrIntOverflowScope
			}
			if iNdEx >= l {
				return io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= uint64(b&0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		fieldNum := int32(wire >> 3)
		wireType := int(wire & 0x7)
		if wireType == 4 {
			return fmt.Errorf("proto: NetAssetValue: wiretype end group for non-group")
		}
		if fieldNum <= 0 {
			return fmt.Errorf("proto: NetAssetValue: illegal tag %d (wire type %d)", fieldNum, wire)
		}
		switch fieldNum {
		case 1:
			if wireType != 2 {
				return fmt.Errorf("proto: wrong wireType = %d for field Price", wireType)
			}
			var msglen int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				msglen |= int(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if msglen < 0 {
				return ErrInvalidLengthScope
			}
			postIndex := iNdEx + msglen
			if postIndex < 0 {
				return ErrInvalidLengthScope
			}
			if postIndex > l {
				return io.ErrUnexpectedEOF
			}
			if err := m.Price.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
				return err
			}
			iNdEx = postIndex
		case 2:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field UpdatedBlockHeight", wireType)
			}
			m.UpdatedBlockHeight = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.UpdatedBlockHeight |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		case 3:
			if wireType != 0 {
				return fmt.Errorf("proto: wrong wireType = %d for field Volume", wireType)
			}
			m.Volume = 0
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return ErrIntOverflowScope
				}
				if iNdEx >= l {
					return io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				m.Volume |= uint64(b&0x7F) << shift
				if b < 0x80 {
					break
				}
			}
		default:
			iNdEx = preIndex
			skippy, err := skipScope(dAtA[iNdEx:])
			if err != nil {
				return err
			}
			if (skippy < 0) || (iNdEx+skippy) < 0 {
				return ErrInvalidLengthScope
			}
			if (iNdEx + skippy) > l {
				return io.ErrUnexpectedEOF
			}
			iNdEx += skippy
		}
	}

	if iNdEx > l {
		return io.ErrUnexpectedEOF
	}
	return nil
}
func skipScope(dAtA []byte) (n int, err error) {
	l := len(dAtA)
	iNdEx := 0
	depth := 0
	for iNdEx < l {
		var wire uint64
		for shift := uint(0); ; shift += 7 {
			if shift >= 64 {
				return 0, ErrIntOverflowScope
			}
			if iNdEx >= l {
				return 0, io.ErrUnexpectedEOF
			}
			b := dAtA[iNdEx]
			iNdEx++
			wire |= (uint64(b) & 0x7F) << shift
			if b < 0x80 {
				break
			}
		}
		wireType := int(wire & 0x7)
		switch wireType {
		case 0:
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowScope
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				iNdEx++
				if dAtA[iNdEx-1] < 0x80 {
					break
				}
			}
		case 1:
			iNdEx += 8
		case 2:
			var length int
			for shift := uint(0); ; shift += 7 {
				if shift >= 64 {
					return 0, ErrIntOverflowScope
				}
				if iNdEx >= l {
					return 0, io.ErrUnexpectedEOF
				}
				b := dAtA[iNdEx]
				iNdEx++
				length |= (int(b) & 0x7F) << shift
				if b < 0x80 {
					break
				}
			}
			if length < 0 {
				return 0, ErrInvalidLengthScope
			}
			iNdEx += length
		case 3:
			depth++
		case 4:
			if depth == 0 {
				return 0, ErrUnexpectedEndOfGroupScope
			}
			depth--
		case 5:
			iNdEx += 4
		default:
			return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
		}
		if iNdEx < 0 {
			return 0, ErrInvalidLengthScope
		}
		if depth == 0 {
			return iNdEx, nil
		}
	}
	return 0, io.ErrUnexpectedEOF
}

var (
	ErrInvalidLengthScope        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowScope          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupScope = fmt.Errorf("proto: unexpected end of group")
)
