119 lines
4.4 KiB
Go
119 lines
4.4 KiB
Go
|
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||
|
// source: cbridge.proto
|
||
|
|
||
|
package cbridge
|
||
|
|
||
|
import (
|
||
|
fmt "fmt"
|
||
|
proto "github.com/golang/protobuf/proto"
|
||
|
math "math"
|
||
|
)
|
||
|
|
||
|
// Reference imports to suppress errors if they are not otherwise used.
|
||
|
var _ = proto.Marshal
|
||
|
var _ = fmt.Errorf
|
||
|
var _ = math.Inf
|
||
|
|
||
|
// 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.ProtoPackageIsVersion3 // please upgrade the proto package
|
||
|
|
||
|
// ========== x/cbridge kv value types
|
||
|
// for src transfer id
|
||
|
// normal status flow: after sgn applied user's Send event, status is OK_TO_RELAY. then after apply Relay event
|
||
|
// status is SUCCESS
|
||
|
// can't relay flow: after apply send, status will be BAD_xxx, and there'll be no relay. so user need to InitWithdraw, status becomes
|
||
|
// refund_requested when sgn apply withdrawDone event, status becomes REFUND_DONE
|
||
|
type XferStatus int32
|
||
|
|
||
|
const (
|
||
|
XferStatus_UNKNOWN XferStatus = 0
|
||
|
// normal flow only has ok then success
|
||
|
XferStatus_OK_TO_RELAY XferStatus = 1
|
||
|
XferStatus_SUCCESS XferStatus = 2
|
||
|
// can't relay flow status
|
||
|
XferStatus_BAD_LIQUIDITY XferStatus = 3
|
||
|
XferStatus_BAD_SLIPPAGE XferStatus = 4
|
||
|
XferStatus_BAD_TOKEN XferStatus = 5
|
||
|
// refund, using withdraw flow
|
||
|
XferStatus_REFUND_REQUESTED XferStatus = 6
|
||
|
XferStatus_REFUND_DONE XferStatus = 7
|
||
|
XferStatus_BAD_XFER_DISABLED XferStatus = 8
|
||
|
// come, we should go to refund flow.
|
||
|
XferStatus_BAD_DEST_CHAIN XferStatus = 9
|
||
|
XferStatus_EXCEED_MAX_OUT_AMOUNT XferStatus = 10
|
||
|
XferStatus_XFER_DELAYED XferStatus = 11
|
||
|
// delayThreshold
|
||
|
XferStatus_BAD_ADDRESS XferStatus = 12
|
||
|
)
|
||
|
|
||
|
var XferStatus_name = map[int32]string{
|
||
|
0: "UNKNOWN",
|
||
|
1: "OK_TO_RELAY",
|
||
|
2: "SUCCESS",
|
||
|
3: "BAD_LIQUIDITY",
|
||
|
4: "BAD_SLIPPAGE",
|
||
|
5: "BAD_TOKEN",
|
||
|
6: "REFUND_REQUESTED",
|
||
|
7: "REFUND_DONE",
|
||
|
8: "BAD_XFER_DISABLED",
|
||
|
9: "BAD_DEST_CHAIN",
|
||
|
10: "EXCEED_MAX_OUT_AMOUNT",
|
||
|
11: "XFER_DELAYED",
|
||
|
12: "BAD_ADDRESS",
|
||
|
}
|
||
|
|
||
|
var XferStatus_value = map[string]int32{
|
||
|
"UNKNOWN": 0,
|
||
|
"OK_TO_RELAY": 1,
|
||
|
"SUCCESS": 2,
|
||
|
"BAD_LIQUIDITY": 3,
|
||
|
"BAD_SLIPPAGE": 4,
|
||
|
"BAD_TOKEN": 5,
|
||
|
"REFUND_REQUESTED": 6,
|
||
|
"REFUND_DONE": 7,
|
||
|
"BAD_XFER_DISABLED": 8,
|
||
|
"BAD_DEST_CHAIN": 9,
|
||
|
"EXCEED_MAX_OUT_AMOUNT": 10,
|
||
|
"XFER_DELAYED": 11,
|
||
|
"BAD_ADDRESS": 12,
|
||
|
}
|
||
|
|
||
|
func (x XferStatus) String() string {
|
||
|
return proto.EnumName(XferStatus_name, int32(x))
|
||
|
}
|
||
|
|
||
|
func (XferStatus) EnumDescriptor() ([]byte, []int) {
|
||
|
return fileDescriptor_176f0c31123a8108, []int{0}
|
||
|
}
|
||
|
|
||
|
func init() {
|
||
|
proto.RegisterEnum("cbridge.XferStatus", XferStatus_name, XferStatus_value)
|
||
|
}
|
||
|
|
||
|
func init() {
|
||
|
proto.RegisterFile("cbridge.proto", fileDescriptor_176f0c31123a8108)
|
||
|
}
|
||
|
|
||
|
var fileDescriptor_176f0c31123a8108 = []byte{
|
||
|
// 255 bytes of a gzipped FileDescriptorProto
|
||
|
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x2c, 0x90, 0xcd, 0x52, 0xc3, 0x30,
|
||
|
0x0c, 0x84, 0x29, 0x3f, 0x0d, 0x55, 0x12, 0x50, 0x3d, 0xf4, 0xc0, 0x2b, 0x70, 0x08, 0x07, 0x9e,
|
||
|
0xc0, 0x89, 0x54, 0xf0, 0x24, 0xb5, 0xdb, 0xd8, 0x1e, 0x52, 0x2e, 0x1e, 0x0a, 0x85, 0xe1, 0x54,
|
||
|
0x26, 0x84, 0xa7, 0xe7, 0xc2, 0x18, 0x72, 0xd4, 0xa7, 0xd1, 0xee, 0x6a, 0x21, 0x7f, 0xd9, 0xf5,
|
||
|
0x1f, 0xaf, 0xef, 0xfb, 0xe2, 0xb3, 0x3f, 0x0c, 0x07, 0x91, 0x8c, 0xe3, 0xcd, 0xcf, 0x04, 0xa0,
|
||
|
0x7b, 0xdb, 0xf7, 0x76, 0x78, 0x1e, 0xbe, 0xbf, 0x44, 0x0a, 0x89, 0xd7, 0xb5, 0x36, 0x8f, 0x1a,
|
||
|
0x8f, 0xc4, 0x25, 0xa4, 0xa6, 0x0e, 0xce, 0x84, 0x96, 0x1b, 0xb9, 0xc5, 0x49, 0xdc, 0x5a, 0x5f,
|
||
|
0x55, 0x6c, 0x2d, 0x1e, 0x8b, 0x39, 0xe4, 0xa5, 0xa4, 0xd0, 0xa8, 0x8d, 0x57, 0xa4, 0xdc, 0x16,
|
||
|
0x4f, 0x04, 0x42, 0x16, 0x91, 0x6d, 0xd4, 0x7a, 0x2d, 0xef, 0x19, 0x4f, 0x45, 0x0e, 0xb3, 0x48,
|
||
|
0x9c, 0xa9, 0x59, 0xe3, 0x99, 0xb8, 0x02, 0x6c, 0x79, 0xe9, 0x35, 0x85, 0x96, 0x37, 0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