add language to channels

This commit is contained in:
Alex Grintsvayg 2019-03-04 10:46:08 -05:00
parent 076e2ccdae
commit a6f2fd6d5f
No known key found for this signature in database
GPG key ID: AEB3F089F86A22B5
6 changed files with 259 additions and 73 deletions

View file

@ -171,6 +171,7 @@ const ::google::protobuf::uint32 TableStruct_claim_2eproto::offsets[] PROTOBUF_S
PROTOBUF_FIELD_OFFSET(::pb::Channel, tags_),
PROTOBUF_FIELD_OFFSET(::pb::Channel, thumbnail_url_),
PROTOBUF_FIELD_OFFSET(::pb::Channel, cover_url_),
PROTOBUF_FIELD_OFFSET(::pb::Channel, language_),
~0u, // no _has_bits_
PROTOBUF_FIELD_OFFSET(::pb::Stream, _internal_metadata_),
~0u, // no _extensions_
@ -217,10 +218,10 @@ const ::google::protobuf::uint32 TableStruct_claim_2eproto::offsets[] PROTOBUF_S
static const ::google::protobuf::internal::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
{ 0, -1, sizeof(::pb::Claim)},
{ 8, -1, sizeof(::pb::Channel)},
{ 21, -1, sizeof(::pb::Stream)},
{ 41, -1, sizeof(::pb::Fee)},
{ 49, -1, sizeof(::pb::File)},
{ 56, -1, sizeof(::pb::Video)},
{ 22, -1, sizeof(::pb::Stream)},
{ 42, -1, sizeof(::pb::Fee)},
{ 50, -1, sizeof(::pb::File)},
{ 57, -1, sizeof(::pb::Video)},
};
static ::google::protobuf::Message const * const file_default_instances[] = {
@ -242,29 +243,29 @@ const char descriptor_table_protodef_claim_2eproto[] =
"\n\013claim.proto\022\002pb\"\200\001\n\005Claim\022\034\n\004type\030\001 \001("
"\0162\016.pb.Claim.Type\022\032\n\006stream\030\002 \001(\0132\n.pb.S"
"tream\022\034\n\007channel\030\003 \001(\0132\013.pb.Channel\"\037\n\004T"
"ype\022\n\n\006STREAM\020\000\022\013\n\007CHANNEL\020\001\"\246\001\n\007Channel"
"ype\022\n\n\006STREAM\020\000\022\013\n\007CHANNEL\020\001\"\270\001\n\007Channel"
"\022\022\n\npublic_key\030\001 \001(\014\022\r\n\005title\030\002 \001(\t\022\023\n\013d"
"escription\030\003 \001(\t\022\025\n\rcontact_email\030\004 \001(\t\022"
"\024\n\014homepage_url\030\005 \001(\t\022\014\n\004tags\030\006 \003(\t\022\025\n\rt"
"humbnail_url\030\020 \001(\t\022\021\n\tcover_url\030\021 \001(\t\"\253\002"
"\n\006Stream\022\014\n\004hash\030\001 \001(\014\022\020\n\010language\030\002 \001(\t"
"\022\r\n\005title\030\003 \001(\t\022\016\n\006author\030\004 \001(\t\022\023\n\013descr"
"iption\030\005 \001(\t\022\022\n\nmedia_type\030\006 \001(\t\022\017\n\007lice"
"nse\030\007 \001(\t\022\026\n\004file\030\010 \001(\0132\010.pb.File\022\024\n\003fee"
"\030\020 \001(\0132\007.pb.Fee\022\023\n\013license_url\030\021 \001(\t\022\025\n\r"
"thumbnail_url\030\022 \001(\t\022\020\n\010duration\030\023 \001(\r\022\014\n"
"\004tags\030\024 \003(\t\022\024\n\014release_time\030\025 \001(\003\022\030\n\005vid"
"eo\030\026 \001(\0132\t.pb.Video\"h\n\003Fee\022\"\n\010currency\030\001"
" \001(\0162\020.pb.Fee.Currency\022\017\n\007address\030\002 \001(\014\022"
"\016\n\006amount\030\003 \001(\004\"\034\n\010Currency\022\007\n\003LBC\020\000\022\007\n\003"
"USD\020\001\"\"\n\004File\022\014\n\004name\030\001 \001(\t\022\014\n\004size\030\002 \001("
"\004\"&\n\005Video\022\r\n\005width\030\001 \001(\r\022\016\n\006height\030\002 \001("
"\rb\006proto3"
"humbnail_url\030\020 \001(\t\022\021\n\tcover_url\030\021 \001(\t\022\020\n"
"\010language\030\022 \001(\t\"\253\002\n\006Stream\022\014\n\004hash\030\001 \001(\014"
"\022\020\n\010language\030\002 \001(\t\022\r\n\005title\030\003 \001(\t\022\016\n\006aut"
"hor\030\004 \001(\t\022\023\n\013description\030\005 \001(\t\022\022\n\nmedia_"
"type\030\006 \001(\t\022\017\n\007license\030\007 \001(\t\022\026\n\004file\030\010 \001("
"\0132\010.pb.File\022\024\n\003fee\030\020 \001(\0132\007.pb.Fee\022\023\n\013lic"
"ense_url\030\021 \001(\t\022\025\n\rthumbnail_url\030\022 \001(\t\022\020\n"
"\010duration\030\023 \001(\r\022\014\n\004tags\030\024 \003(\t\022\024\n\014release"
"_time\030\025 \001(\003\022\030\n\005video\030\026 \001(\0132\t.pb.Video\"h\n"
"\003Fee\022\"\n\010currency\030\001 \001(\0162\020.pb.Fee.Currency"
"\022\017\n\007address\030\002 \001(\014\022\016\n\006amount\030\003 \001(\004\"\034\n\010Cur"
"rency\022\007\n\003LBC\020\000\022\007\n\003USD\020\001\"\"\n\004File\022\014\n\004name\030"
"\001 \001(\t\022\014\n\004size\030\002 \001(\004\"&\n\005Video\022\r\n\005width\030\001 "
"\001(\r\022\016\n\006height\030\002 \001(\rb\006proto3"
;
::google::protobuf::internal::DescriptorTable descriptor_table_claim_2eproto = {
false, InitDefaults_claim_2eproto,
descriptor_table_protodef_claim_2eproto,
"claim.proto", &assign_descriptors_table_claim_2eproto, 809,
"claim.proto", &assign_descriptors_table_claim_2eproto, 827,
};
void AddDescriptors_claim_2eproto() {
@ -739,6 +740,7 @@ const int Channel::kHomepageUrlFieldNumber;
const int Channel::kTagsFieldNumber;
const int Channel::kThumbnailUrlFieldNumber;
const int Channel::kCoverUrlFieldNumber;
const int Channel::kLanguageFieldNumber;
#endif // !defined(_MSC_VER) || _MSC_VER >= 1900
Channel::Channel()
@ -779,6 +781,10 @@ Channel::Channel(const Channel& from)
if (from.cover_url().size() > 0) {
cover_url_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.cover_url_);
}
language_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
if (from.language().size() > 0) {
language_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.language_);
}
// @@protoc_insertion_point(copy_constructor:pb.Channel)
}
@ -792,6 +798,7 @@ void Channel::SharedCtor() {
homepage_url_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
thumbnail_url_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
cover_url_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
language_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
Channel::~Channel() {
@ -807,6 +814,7 @@ void Channel::SharedDtor() {
homepage_url_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
thumbnail_url_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
cover_url_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
language_.DestroyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
void Channel::SetCachedSize(int size) const {
@ -832,6 +840,7 @@ void Channel::Clear() {
homepage_url_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
thumbnail_url_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
cover_url_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
language_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
_internal_metadata_.Clear();
}
@ -978,6 +987,22 @@ const char* Channel::_InternalParse(const char* begin, const char* end, void* ob
ptr += size;
break;
}
// string language = 18;
case 18: {
if (static_cast<::google::protobuf::uint8>(tag) != 146) goto handle_unusual;
ptr = ::google::protobuf::io::ReadSize(ptr, &size);
GOOGLE_PROTOBUF_PARSER_ASSERT(ptr);
ctx->extra_parse_data().SetFieldName("pb.Channel.language");
object = msg->mutable_language();
if (size > end - ptr + ::google::protobuf::internal::ParseContext::kSlopBytes) {
parser_till_end = ::google::protobuf::internal::GreedyStringParserUTF8;
goto string_till_end;
}
GOOGLE_PROTOBUF_PARSER_ASSERT(::google::protobuf::internal::StringCheckUTF8(ptr, size, ctx));
::google::protobuf::internal::InlineGreedyStringParser(object, ptr, size, ctx);
ptr += size;
break;
}
default: {
handle_unusual:
if ((tag & 7) == 4 || tag == 0) {
@ -1129,6 +1154,21 @@ bool Channel::MergePartialFromCodedStream(
break;
}
// string language = 18;
case 18: {
if (static_cast< ::google::protobuf::uint8>(tag) == (146 & 0xFF)) {
DO_(::google::protobuf::internal::WireFormatLite::ReadString(
input, this->mutable_language()));
DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
this->language().data(), static_cast<int>(this->language().length()),
::google::protobuf::internal::WireFormatLite::PARSE,
"pb.Channel.language"));
} else {
goto handle_unusual;
}
break;
}
default: {
handle_unusual:
if (tag == 0) {
@ -1232,6 +1272,16 @@ void Channel::SerializeWithCachedSizes(
17, this->cover_url(), output);
}
// string language = 18;
if (this->language().size() > 0) {
::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
this->language().data(), static_cast<int>(this->language().length()),
::google::protobuf::internal::WireFormatLite::SERIALIZE,
"pb.Channel.language");
::google::protobuf::internal::WireFormatLite::WriteStringMaybeAliased(
18, this->language(), output);
}
if (_internal_metadata_.have_unknown_fields()) {
::google::protobuf::internal::WireFormat::SerializeUnknownFields(
_internal_metadata_.unknown_fields(), output);
@ -1328,6 +1378,17 @@ void Channel::SerializeWithCachedSizes(
17, this->cover_url(), target);
}
// string language = 18;
if (this->language().size() > 0) {
::google::protobuf::internal::WireFormatLite::VerifyUtf8String(
this->language().data(), static_cast<int>(this->language().length()),
::google::protobuf::internal::WireFormatLite::SERIALIZE,
"pb.Channel.language");
target =
::google::protobuf::internal::WireFormatLite::WriteStringToArray(
18, this->language(), target);
}
if (_internal_metadata_.have_unknown_fields()) {
target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray(
_internal_metadata_.unknown_fields(), target);
@ -1406,6 +1467,13 @@ size_t Channel::ByteSizeLong() const {
this->cover_url());
}
// string language = 18;
if (this->language().size() > 0) {
total_size += 2 +
::google::protobuf::internal::WireFormatLite::StringSize(
this->language());
}
int cached_size = ::google::protobuf::internal::ToCachedSize(total_size);
SetCachedSize(cached_size);
return total_size;
@ -1462,6 +1530,10 @@ void Channel::MergeFrom(const Channel& from) {
cover_url_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.cover_url_);
}
if (from.language().size() > 0) {
language_.AssignWithDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), from.language_);
}
}
void Channel::CopyFrom(const ::google::protobuf::Message& from) {
@ -1504,6 +1576,8 @@ void Channel::InternalSwap(Channel* other) {
GetArenaNoVirtual());
cover_url_.Swap(&other->cover_url_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
GetArenaNoVirtual());
language_.Swap(&other->language_, &::google::protobuf::internal::GetEmptyStringAlreadyInited(),
GetArenaNoVirtual());
}
::google::protobuf::Metadata Channel::GetMetadata() const {

View file

@ -498,6 +498,20 @@ class Channel final :
::std::string* release_cover_url();
void set_allocated_cover_url(::std::string* cover_url);
// string language = 18;
void clear_language();
static const int kLanguageFieldNumber = 18;
const ::std::string& language() const;
void set_language(const ::std::string& value);
#if LANG_CXX11
void set_language(::std::string&& value);
#endif
void set_language(const char* value);
void set_language(const char* value, size_t size);
::std::string* mutable_language();
::std::string* release_language();
void set_allocated_language(::std::string* language);
// @@protoc_insertion_point(class_scope:pb.Channel)
private:
class HasBitSetters;
@ -511,6 +525,7 @@ class Channel final :
::google::protobuf::internal::ArenaStringPtr homepage_url_;
::google::protobuf::internal::ArenaStringPtr thumbnail_url_;
::google::protobuf::internal::ArenaStringPtr cover_url_;
::google::protobuf::internal::ArenaStringPtr language_;
mutable ::google::protobuf::internal::CachedSize _cached_size_;
friend struct ::TableStruct_claim_2eproto;
};
@ -1798,6 +1813,59 @@ inline void Channel::set_allocated_cover_url(::std::string* cover_url) {
// @@protoc_insertion_point(field_set_allocated:pb.Channel.cover_url)
}
// string language = 18;
inline void Channel::clear_language() {
language_.ClearToEmptyNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
inline const ::std::string& Channel::language() const {
// @@protoc_insertion_point(field_get:pb.Channel.language)
return language_.GetNoArena();
}
inline void Channel::set_language(const ::std::string& value) {
language_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), value);
// @@protoc_insertion_point(field_set:pb.Channel.language)
}
#if LANG_CXX11
inline void Channel::set_language(::std::string&& value) {
language_.SetNoArena(
&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value));
// @@protoc_insertion_point(field_set_rvalue:pb.Channel.language)
}
#endif
inline void Channel::set_language(const char* value) {
GOOGLE_DCHECK(value != nullptr);
language_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::string(value));
// @@protoc_insertion_point(field_set_char:pb.Channel.language)
}
inline void Channel::set_language(const char* value, size_t size) {
language_.SetNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(),
::std::string(reinterpret_cast<const char*>(value), size));
// @@protoc_insertion_point(field_set_pointer:pb.Channel.language)
}
inline ::std::string* Channel::mutable_language() {
// @@protoc_insertion_point(field_mutable:pb.Channel.language)
return language_.MutableNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
inline ::std::string* Channel::release_language() {
// @@protoc_insertion_point(field_release:pb.Channel.language)
return language_.ReleaseNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited());
}
inline void Channel::set_allocated_language(::std::string* language) {
if (language != nullptr) {
} else {
}
language_.SetAllocatedNoArena(&::google::protobuf::internal::GetEmptyStringAlreadyInited(), language);
// @@protoc_insertion_point(field_set_allocated:pb.Channel.language)
}
// -------------------------------------------------------------------
// Stream

View file

@ -134,6 +134,7 @@ type Channel struct {
Tags []string `protobuf:"bytes,6,rep,name=tags,proto3" json:"tags,omitempty"`
ThumbnailUrl string `protobuf:"bytes,16,opt,name=thumbnail_url,json=thumbnailUrl,proto3" json:"thumbnail_url,omitempty"`
CoverUrl string `protobuf:"bytes,17,opt,name=cover_url,json=coverUrl,proto3" json:"cover_url,omitempty"`
Language string `protobuf:"bytes,18,opt,name=language,proto3" json:"language,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
@ -220,6 +221,13 @@ func (m *Channel) GetCoverUrl() string {
return ""
}
func (m *Channel) GetLanguage() string {
if m != nil {
return m.Language
}
return ""
}
type Stream struct {
Hash []byte `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
Language string `protobuf:"bytes,2,opt,name=language,proto3" json:"language,omitempty"`
@ -534,44 +542,45 @@ func init() {
func init() { proto.RegisterFile("claim.proto", fileDescriptor_bae86789b513b1db) }
var fileDescriptor_bae86789b513b1db = []byte{
// 624 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x94, 0xcd, 0x6e, 0xdb, 0x48,
0x0c, 0xc7, 0xa3, 0x48, 0xb6, 0x25, 0xca, 0x0e, 0xbc, 0xb3, 0xd9, 0x40, 0x9b, 0x4d, 0x10, 0x47,
0x8b, 0x02, 0x3e, 0x14, 0x3e, 0xa4, 0xe8, 0x03, 0xa4, 0x6e, 0x82, 0x02, 0x4d, 0x73, 0x98, 0x24,
0xbd, 0x1a, 0x63, 0x89, 0xb1, 0x06, 0x1d, 0x7d, 0x40, 0x1a, 0xa5, 0x70, 0xaf, 0x7d, 0x88, 0xbe,
0x48, 0x9f, 0xaf, 0x28, 0x86, 0x1a, 0xbb, 0x46, 0xd3, 0x1b, 0xf9, 0x23, 0x87, 0x26, 0xff, 0xa4,
0x0c, 0x61, 0xa2, 0x84, 0xcc, 0x67, 0x55, 0x5d, 0xea, 0x92, 0xed, 0x57, 0xcb, 0xf8, 0x9b, 0x03,
0xbd, 0xb9, 0x61, 0x2c, 0x06, 0x4f, 0xaf, 0x2b, 0x8c, 0x9c, 0x89, 0x33, 0x3d, 0xb8, 0x38, 0x98,
0x55, 0xcb, 0x19, 0x05, 0x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1a, 0xc0, 0x3b, 0x1e, 0x7f, 0x75, 0xc0, 0xbd, 0x46,
0x64, 0x2f, 0xc1, 0x4f, 0xda, 0xba, 0xc6, 0x22, 0x59, 0xdb, 0x6f, 0x6a, 0x6c, 0x27, 0x9c, 0xcd,
0x2d, 0xe7, 0xdb, 0x0c, 0x23, 0xa1, 0x48, 0xd3, 0x1a, 0x9b, 0x86, 0x96, 0x39, 0xe4, 0x1b, 0x97,
0xb6, 0x96, 0x97, 0x6d, 0xa1, 0x69, 0x99, 0x1e, 0xb7, 0x5e, 0x7c, 0x02, 0xfe, 0xa6, 0x0e, 0x1b,
0x80, 0x7b, 0xf3, 0x66, 0x3e, 0xde, 0x33, 0xc6, 0xc3, 0xdd, 0xdb, 0xb1, 0x13, 0xcf, 0xc0, 0x33,
0x42, 0x9b, 0x29, 0x0b, 0x91, 0x77, 0x5f, 0x75, 0xc0, 0xc9, 0x36, 0xac, 0x91, 0x5f, 0xba, 0xab,
0xf1, 0x38, 0xd9, 0xf1, 0x6b, 0xe8, 0xd1, 0x14, 0xe6, 0x74, 0x3e, 0xcb, 0x54, 0x77, 0xb7, 0x36,
0xe2, 0x9d, 0x63, 0x9a, 0xc8, 0x50, 0xae, 0x32, 0x4d, 0x8f, 0x46, 0xdc, 0x7a, 0xcb, 0x3e, 0xfd,
0x93, 0xbc, 0xfa, 0x19, 0x00, 0x00, 0xff, 0xff, 0xcb, 0xd7, 0xcb, 0x38, 0x58, 0x04, 0x00, 0x00,
// 630 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x94, 0xdd, 0x4e, 0xdb, 0x4a,
0x10, 0xc7, 0x71, 0xec, 0xc4, 0xf6, 0x38, 0x41, 0x39, 0x7b, 0x38, 0xc8, 0x87, 0x03, 0x22, 0xf8,
0xa8, 0x52, 0x2e, 0xaa, 0x5c, 0x50, 0xf5, 0x01, 0x68, 0x0a, 0xaa, 0x54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aa, 0xbb, 0xb5, 0x11, 0xef, 0x1c, 0x3d, 0x44, 0x8a, 0x72, 0x95, 0x2a, 0x2a, 0x1a,
0x71, 0xe3, 0x2d, 0x07, 0xf4, 0x2f, 0xf3, 0xea, 0x67, 0x00, 0x00, 0x00, 0xff, 0xff, 0x84, 0x9a,
0x34, 0x65, 0x74, 0x04, 0x00, 0x00,
}

View file

@ -416,7 +416,8 @@ proto.pb.Channel.toObject = function(includeInstance, msg) {
homepageUrl: jspb.Message.getFieldWithDefault(msg, 5, ""),
tagsList: jspb.Message.getRepeatedField(msg, 6),
thumbnailUrl: jspb.Message.getFieldWithDefault(msg, 16, ""),
coverUrl: jspb.Message.getFieldWithDefault(msg, 17, "")
coverUrl: jspb.Message.getFieldWithDefault(msg, 17, ""),
language: jspb.Message.getFieldWithDefault(msg, 18, "")
};
if (includeInstance) {
@ -485,6 +486,10 @@ proto.pb.Channel.deserializeBinaryFromReader = function(msg, reader) {
var value = /** @type {string} */ (reader.readString());
msg.setCoverUrl(value);
break;
case 18:
var value = /** @type {string} */ (reader.readString());
msg.setLanguage(value);
break;
default:
reader.skipField();
break;
@ -570,6 +575,13 @@ proto.pb.Channel.serializeBinaryToWriter = function(message, writer) {
f
);
}
f = message.getLanguage();
if (f.length > 0) {
writer.writeString(
18,
f
);
}
};
@ -734,6 +746,21 @@ proto.pb.Channel.prototype.setCoverUrl = function(value) {
};
/**
* optional string language = 18;
* @return {string}
*/
proto.pb.Channel.prototype.getLanguage = function() {
return /** @type {string} */ (jspb.Message.getFieldWithDefault(this, 18, ""));
};
/** @param {string} value */
proto.pb.Channel.prototype.setLanguage = function(value) {
jspb.Message.setProto3StringField(this, 18, value);
};
/**
* List of repeated fields within this message type.

View file

@ -23,6 +23,7 @@ message Channel {
string thumbnail_url = 16;
string cover_url = 17;
string language = 18;
}
message Stream {

View file

@ -20,7 +20,7 @@ DESCRIPTOR = _descriptor.FileDescriptor(
package='pb',
syntax='proto3',
serialized_options=None,
serialized_pb=_b('\n\x0b\x63laim.proto\x12\x02pb\"\x80\x01\n\x05\x43laim\x12\x1c\n\x04type\x18\x01 \x01(\x0e\x32\x0e.pb.Claim.Type\x12\x1a\n\x06stream\x18\x02 \x01(\x0b\x32\n.pb.Stream\x12\x1c\n\x07\x63hannel\x18\x03 \x01(\x0b\x32\x0b.pb.Channel\"\x1f\n\x04Type\x12\n\n\x06STREAM\x10\x00\x12\x0b\n\x07\x43HANNEL\x10\x01\"\xa6\x01\n\x07\x43hannel\x12\x12\n\npublic_key\x18\x01 \x01(\x0c\x12\r\n\x05title\x18\x02 \x01(\t\x12\x13\n\x0b\x64\x65scription\x18\x03 \x01(\t\x12\x15\n\rcontact_email\x18\x04 \x01(\t\x12\x14\n\x0chomepage_url\x18\x05 \x01(\t\x12\x0c\n\x04tags\x18\x06 \x03(\t\x12\x15\n\rthumbnail_url\x18\x10 \x01(\t\x12\x11\n\tcover_url\x18\x11 \x01(\t\"\xab\x02\n\x06Stream\x12\x0c\n\x04hash\x18\x01 \x01(\x0c\x12\x10\n\x08language\x18\x02 \x01(\t\x12\r\n\x05title\x18\x03 \x01(\t\x12\x0e\n\x06\x61uthor\x18\x04 \x01(\t\x12\x13\n\x0b\x64\x65scription\x18\x05 \x01(\t\x12\x12\n\nmedia_type\x18\x06 \x01(\t\x12\x0f\n\x07license\x18\x07 \x01(\t\x12\x16\n\x04\x66ile\x18\x08 \x01(\x0b\x32\x08.pb.File\x12\x14\n\x03\x66\x65\x65\x18\x10 \x01(\x0b\x32\x07.pb.Fee\x12\x13\n\x0blicense_url\x18\x11 \x01(\t\x12\x15\n\rthumbnail_url\x18\x12 \x01(\t\x12\x10\n\x08\x64uration\x18\x13 \x01(\r\x12\x0c\n\x04tags\x18\x14 \x03(\t\x12\x14\n\x0crelease_time\x18\x15 \x01(\x03\x12\x18\n\x05video\x18\x16 \x01(\x0b\x32\t.pb.Video\"h\n\x03\x46\x65\x65\x12\"\n\x08\x63urrency\x18\x01 \x01(\x0e\x32\x10.pb.Fee.Currency\x12\x0f\n\x07\x61\x64\x64ress\x18\x02 \x01(\x0c\x12\x0e\n\x06\x61mount\x18\x03 \x01(\x04\"\x1c\n\x08\x43urrency\x12\x07\n\x03LBC\x10\x00\x12\x07\n\x03USD\x10\x01\"\"\n\x04\x46ile\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x0c\n\x04size\x18\x02 \x01(\x04\"&\n\x05Video\x12\r\n\x05width\x18\x01 \x01(\r\x12\x0e\n\x06height\x18\x02 \x01(\rb\x06proto3')
serialized_pb=_b('\n\x0b\x63laim.proto\x12\x02pb\"\x80\x01\n\x05\x43laim\x12\x1c\n\x04type\x18\x01 \x01(\x0e\x32\x0e.pb.Claim.Type\x12\x1a\n\x06stream\x18\x02 \x01(\x0b\x32\n.pb.Stream\x12\x1c\n\x07\x63hannel\x18\x03 \x01(\x0b\x32\x0b.pb.Channel\"\x1f\n\x04Type\x12\n\n\x06STREAM\x10\x00\x12\x0b\n\x07\x43HANNEL\x10\x01\"\xb8\x01\n\x07\x43hannel\x12\x12\n\npublic_key\x18\x01 \x01(\x0c\x12\r\n\x05title\x18\x02 \x01(\t\x12\x13\n\x0b\x64\x65scription\x18\x03 \x01(\t\x12\x15\n\rcontact_email\x18\x04 \x01(\t\x12\x14\n\x0chomepage_url\x18\x05 \x01(\t\x12\x0c\n\x04tags\x18\x06 \x03(\t\x12\x15\n\rthumbnail_url\x18\x10 \x01(\t\x12\x11\n\tcover_url\x18\x11 \x01(\t\x12\x10\n\x08language\x18\x12 \x01(\t\"\xab\x02\n\x06Stream\x12\x0c\n\x04hash\x18\x01 \x01(\x0c\x12\x10\n\x08language\x18\x02 \x01(\t\x12\r\n\x05title\x18\x03 \x01(\t\x12\x0e\n\x06\x61uthor\x18\x04 \x01(\t\x12\x13\n\x0b\x64\x65scription\x18\x05 \x01(\t\x12\x12\n\nmedia_type\x18\x06 \x01(\t\x12\x0f\n\x07license\x18\x07 \x01(\t\x12\x16\n\x04\x66ile\x18\x08 \x01(\x0b\x32\x08.pb.File\x12\x14\n\x03\x66\x65\x65\x18\x10 \x01(\x0b\x32\x07.pb.Fee\x12\x13\n\x0blicense_url\x18\x11 \x01(\t\x12\x15\n\rthumbnail_url\x18\x12 \x01(\t\x12\x10\n\x08\x64uration\x18\x13 \x01(\r\x12\x0c\n\x04tags\x18\x14 \x03(\t\x12\x14\n\x0crelease_time\x18\x15 \x01(\x03\x12\x18\n\x05video\x18\x16 \x01(\x0b\x32\t.pb.Video\"h\n\x03\x46\x65\x65\x12\"\n\x08\x63urrency\x18\x01 \x01(\x0e\x32\x10.pb.Fee.Currency\x12\x0f\n\x07\x61\x64\x64ress\x18\x02 \x01(\x0c\x12\x0e\n\x06\x61mount\x18\x03 \x01(\x04\"\x1c\n\x08\x43urrency\x12\x07\n\x03LBC\x10\x00\x12\x07\n\x03USD\x10\x01\"\"\n\x04\x46ile\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x0c\n\x04size\x18\x02 \x01(\x04\"&\n\x05Video\x12\r\n\x05width\x18\x01 \x01(\r\x12\x0e\n\x06height\x18\x02 \x01(\rb\x06proto3')
)
@ -64,8 +64,8 @@ _FEE_CURRENCY = _descriptor.EnumDescriptor(
],
containing_type=None,
serialized_options=None,
serialized_start=697,
serialized_end=725,
serialized_start=715,
serialized_end=743,
)
_sym_db.RegisterEnumDescriptor(_FEE_CURRENCY)
@ -179,6 +179,13 @@ _CHANNEL = _descriptor.Descriptor(
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR),
_descriptor.FieldDescriptor(
name='language', full_name='pb.Channel.language', index=8,
number=18, type=9, cpp_type=9, label=1,
has_default_value=False, default_value=_b("").decode('utf-8'),
message_type=None, enum_type=None, containing_type=None,
is_extension=False, extension_scope=None,
serialized_options=None, file=DESCRIPTOR),
],
extensions=[
],
@ -192,7 +199,7 @@ _CHANNEL = _descriptor.Descriptor(
oneofs=[
],
serialized_start=151,
serialized_end=317,
serialized_end=335,
)
@ -320,8 +327,8 @@ _STREAM = _descriptor.Descriptor(
extension_ranges=[],
oneofs=[
],
serialized_start=320,
serialized_end=619,
serialized_start=338,
serialized_end=637,
)
@ -366,8 +373,8 @@ _FEE = _descriptor.Descriptor(
extension_ranges=[],
oneofs=[
],
serialized_start=621,
serialized_end=725,
serialized_start=639,
serialized_end=743,
)
@ -404,8 +411,8 @@ _FILE = _descriptor.Descriptor(
extension_ranges=[],
oneofs=[
],
serialized_start=727,
serialized_end=761,
serialized_start=745,
serialized_end=779,
)
@ -442,8 +449,8 @@ _VIDEO = _descriptor.Descriptor(
extension_ranges=[],
oneofs=[
],
serialized_start=763,
serialized_end=801,
serialized_start=781,
serialized_end=819,
)
_CLAIM.fields_by_name['type'].enum_type = _CLAIM_TYPE