// Code generated by protoc-gen-go. DO NOT EDIT.
// source: bits_use/create.proto

package bits_use

import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import 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.ProtoPackageIsVersion2 // please upgrade the proto package

// BitsUseCreate triggers when a user successfully uses Bits, except for cheering, at a broadcaster.
type BitsUseCreate struct {
	// The unique bits transaction associated with this cheer
	BitsTransactionId string `protobuf:"bytes,1,opt,name=bits_transaction_id,json=bitsTransactionId,proto3" json:"bits_transaction_id,omitempty"`
	// The recipient of the bits, as a unique user identifier (not display name)
	ToUserId string `protobuf:"bytes,2,opt,name=to_user_id,json=toUserId,proto3" json:"to_user_id,omitempty"`
	// The initiator of the bits use, as a unique user identifier (not display name)
	FromUserId string `protobuf:"bytes,3,opt,name=from_user_id,json=fromUserId,proto3" json:"from_user_id,omitempty"`
	// The number of bits used to the broadcaster
	BitsAmount int64 `protobuf:"varint,4,opt,name=bits_amount,json=bitsAmount,proto3" json:"bits_amount,omitempty"`
	// The type of bits use that was processed, can come in 1 of 2 forms:
	// - Bits on Extensions Use, in which case some additional information is provided
	// - Bits on Poll Use, in which case no additional information is available
	//
	// Types that are valid to be assigned to From:
	//	*BitsUseCreate_Extension
	//	*BitsUseCreate_Poll
	From                 isBitsUseCreate_From `protobuf_oneof:"from"`
	XXX_NoUnkeyedLiteral struct{}             `json:"-"`
	XXX_unrecognized     []byte               `json:"-"`
	XXX_sizecache        int32                `json:"-"`
}

func (m *BitsUseCreate) Reset()         { *m = BitsUseCreate{} }
func (m *BitsUseCreate) String() string { return proto.CompactTextString(m) }
func (*BitsUseCreate) ProtoMessage()    {}
func (*BitsUseCreate) Descriptor() ([]byte, []int) {
	return fileDescriptor_create_0c261aeed4c49aed, []int{0}
}
func (m *BitsUseCreate) XXX_Unmarshal(b []byte) error {
	return xxx_messageInfo_BitsUseCreate.Unmarshal(m, b)
}
func (m *BitsUseCreate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	return xxx_messageInfo_BitsUseCreate.Marshal(b, m, deterministic)
}
func (dst *BitsUseCreate) XXX_Merge(src proto.Message) {
	xxx_messageInfo_BitsUseCreate.Merge(dst, src)
}
func (m *BitsUseCreate) XXX_Size() int {
	return xxx_messageInfo_BitsUseCreate.Size(m)
}
func (m *BitsUseCreate) XXX_DiscardUnknown() {
	xxx_messageInfo_BitsUseCreate.DiscardUnknown(m)
}

var xxx_messageInfo_BitsUseCreate proto.InternalMessageInfo

func (m *BitsUseCreate) GetBitsTransactionId() string {
	if m != nil {
		return m.BitsTransactionId
	}
	return ""
}

func (m *BitsUseCreate) GetToUserId() string {
	if m != nil {
		return m.ToUserId
	}
	return ""
}

func (m *BitsUseCreate) GetFromUserId() string {
	if m != nil {
		return m.FromUserId
	}
	return ""
}

func (m *BitsUseCreate) GetBitsAmount() int64 {
	if m != nil {
		return m.BitsAmount
	}
	return 0
}

type isBitsUseCreate_From interface {
	isBitsUseCreate_From()
}

type BitsUseCreate_Extension struct {
	Extension *Extension `protobuf:"bytes,5,opt,name=extension,proto3,oneof"`
}

type BitsUseCreate_Poll struct {
	Poll *Poll `protobuf:"bytes,6,opt,name=poll,proto3,oneof"`
}

func (*BitsUseCreate_Extension) isBitsUseCreate_From() {}

func (*BitsUseCreate_Poll) isBitsUseCreate_From() {}

func (m *BitsUseCreate) GetFrom() isBitsUseCreate_From {
	if m != nil {
		return m.From
	}
	return nil
}

func (m *BitsUseCreate) GetExtension() *Extension {
	if x, ok := m.GetFrom().(*BitsUseCreate_Extension); ok {
		return x.Extension
	}
	return nil
}

func (m *BitsUseCreate) GetPoll() *Poll {
	if x, ok := m.GetFrom().(*BitsUseCreate_Poll); ok {
		return x.Poll
	}
	return nil
}

// XXX_OneofFuncs is for the internal use of the proto package.
func (*BitsUseCreate) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
	return _BitsUseCreate_OneofMarshaler, _BitsUseCreate_OneofUnmarshaler, _BitsUseCreate_OneofSizer, []interface{}{
		(*BitsUseCreate_Extension)(nil),
		(*BitsUseCreate_Poll)(nil),
	}
}

func _BitsUseCreate_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
	m := msg.(*BitsUseCreate)
	// from
	switch x := m.From.(type) {
	case *BitsUseCreate_Extension:
		b.EncodeVarint(5<<3 | proto.WireBytes)
		if err := b.EncodeMessage(x.Extension); err != nil {
			return err
		}
	case *BitsUseCreate_Poll:
		b.EncodeVarint(6<<3 | proto.WireBytes)
		if err := b.EncodeMessage(x.Poll); err != nil {
			return err
		}
	case nil:
	default:
		return fmt.Errorf("BitsUseCreate.From has unexpected type %T", x)
	}
	return nil
}

func _BitsUseCreate_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
	m := msg.(*BitsUseCreate)
	switch tag {
	case 5: // from.extension
		if wire != proto.WireBytes {
			return true, proto.ErrInternalBadWireType
		}
		msg := new(Extension)
		err := b.DecodeMessage(msg)
		m.From = &BitsUseCreate_Extension{msg}
		return true, err
	case 6: // from.poll
		if wire != proto.WireBytes {
			return true, proto.ErrInternalBadWireType
		}
		msg := new(Poll)
		err := b.DecodeMessage(msg)
		m.From = &BitsUseCreate_Poll{msg}
		return true, err
	default:
		return false, nil
	}
}

func _BitsUseCreate_OneofSizer(msg proto.Message) (n int) {
	m := msg.(*BitsUseCreate)
	// from
	switch x := m.From.(type) {
	case *BitsUseCreate_Extension:
		s := proto.Size(x.Extension)
		n += 1 // tag and wire
		n += proto.SizeVarint(uint64(s))
		n += s
	case *BitsUseCreate_Poll:
		s := proto.Size(x.Poll)
		n += 1 // tag and wire
		n += proto.SizeVarint(uint64(s))
		n += s
	case nil:
	default:
		panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
	}
	return n
}

// Extension is information about Bits use in an extension.
type Extension struct {
	// The ID of the extension, defined by the extensions team.
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// The ID of the product SKU that was used in the extension that was fulfilled.
	ProductId            string   `protobuf:"bytes,2,opt,name=product_id,json=productId,proto3" json:"product_id,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (m *Extension) Reset()         { *m = Extension{} }
func (m *Extension) String() string { return proto.CompactTextString(m) }
func (*Extension) ProtoMessage()    {}
func (*Extension) Descriptor() ([]byte, []int) {
	return fileDescriptor_create_0c261aeed4c49aed, []int{1}
}
func (m *Extension) XXX_Unmarshal(b []byte) error {
	return xxx_messageInfo_Extension.Unmarshal(m, b)
}
func (m *Extension) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	return xxx_messageInfo_Extension.Marshal(b, m, deterministic)
}
func (dst *Extension) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Extension.Merge(dst, src)
}
func (m *Extension) XXX_Size() int {
	return xxx_messageInfo_Extension.Size(m)
}
func (m *Extension) XXX_DiscardUnknown() {
	xxx_messageInfo_Extension.DiscardUnknown(m)
}

var xxx_messageInfo_Extension proto.InternalMessageInfo

func (m *Extension) GetId() string {
	if m != nil {
		return m.Id
	}
	return ""
}

func (m *Extension) GetProductId() string {
	if m != nil {
		return m.ProductId
	}
	return ""
}

// Poll is information about Bits use in a poll.
type Poll struct {
	// The ID of the poll where the Bits were used
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// The choice in the poll that the Bits were used to vote with
	ChoiceId             string   `protobuf:"bytes,2,opt,name=choice_id,json=choiceId,proto3" json:"choice_id,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (m *Poll) Reset()         { *m = Poll{} }
func (m *Poll) String() string { return proto.CompactTextString(m) }
func (*Poll) ProtoMessage()    {}
func (*Poll) Descriptor() ([]byte, []int) {
	return fileDescriptor_create_0c261aeed4c49aed, []int{2}
}
func (m *Poll) XXX_Unmarshal(b []byte) error {
	return xxx_messageInfo_Poll.Unmarshal(m, b)
}
func (m *Poll) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
	return xxx_messageInfo_Poll.Marshal(b, m, deterministic)
}
func (dst *Poll) XXX_Merge(src proto.Message) {
	xxx_messageInfo_Poll.Merge(dst, src)
}
func (m *Poll) XXX_Size() int {
	return xxx_messageInfo_Poll.Size(m)
}
func (m *Poll) XXX_DiscardUnknown() {
	xxx_messageInfo_Poll.DiscardUnknown(m)
}

var xxx_messageInfo_Poll proto.InternalMessageInfo

func (m *Poll) GetId() string {
	if m != nil {
		return m.Id
	}
	return ""
}

func (m *Poll) GetChoiceId() string {
	if m != nil {
		return m.ChoiceId
	}
	return ""
}

func init() {
	proto.RegisterType((*BitsUseCreate)(nil), "bits_use.BitsUseCreate")
	proto.RegisterType((*Extension)(nil), "bits_use.Extension")
	proto.RegisterType((*Poll)(nil), "bits_use.Poll")
}

func init() { proto.RegisterFile("bits_use/create.proto", fileDescriptor_create_0c261aeed4c49aed) }

var fileDescriptor_create_0c261aeed4c49aed = []byte{
	// 279 bytes of a gzipped FileDescriptorProto
	0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x64, 0x91, 0xc1, 0x4b, 0xc3, 0x30,
	0x14, 0xc6, 0xd7, 0xae, 0x96, 0xf5, 0x4d, 0x07, 0x66, 0x08, 0x05, 0x15, 0x4b, 0xf1, 0xd0, 0x53,
	0x05, 0x7b, 0xf3, 0x66, 0x45, 0x58, 0x6f, 0x52, 0xdc, 0xc5, 0xcb, 0xe8, 0x9a, 0x88, 0x81, 0xae,
	0xaf, 0x24, 0xaf, 0xe0, 0xdd, 0x7f, 0x5c, 0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