playlist4changes.rs 119 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565
  1. // This file is generated by rust-protobuf 2.7.0. Do not edit
  2. // @generated
  3. // https://github.com/Manishearth/rust-clippy/issues/702
  4. #![allow(unknown_lints)]
  5. #![allow(clippy::all)]
  6. #![cfg_attr(rustfmt, rustfmt_skip)]
  7. #![allow(box_pointers)]
  8. #![allow(dead_code)]
  9. #![allow(missing_docs)]
  10. #![allow(non_camel_case_types)]
  11. #![allow(non_snake_case)]
  12. #![allow(non_upper_case_globals)]
  13. #![allow(trivial_casts)]
  14. #![allow(unsafe_code)]
  15. #![allow(unused_imports)]
  16. #![allow(unused_results)]
  17. //! Generated file from `playlist4changes.proto`
  18. use protobuf::Message as Message_imported_for_functions;
  19. use protobuf::ProtobufEnum as ProtobufEnum_imported_for_functions;
  20. /// Generated files are compatible only with the same version
  21. /// of protobuf runtime.
  22. const _PROTOBUF_VERSION_CHECK: () = ::protobuf::VERSION_2_7_0;
  23. #[derive(PartialEq,Clone,Default)]
  24. pub struct ChangeInfo {
  25. // message fields
  26. user: ::protobuf::SingularField<::std::string::String>,
  27. timestamp: ::std::option::Option<i32>,
  28. admin: ::std::option::Option<bool>,
  29. undo: ::std::option::Option<bool>,
  30. redo: ::std::option::Option<bool>,
  31. merge: ::std::option::Option<bool>,
  32. compressed: ::std::option::Option<bool>,
  33. migration: ::std::option::Option<bool>,
  34. // special fields
  35. pub unknown_fields: ::protobuf::UnknownFields,
  36. pub cached_size: ::protobuf::CachedSize,
  37. }
  38. impl<'a> ::std::default::Default for &'a ChangeInfo {
  39. fn default() -> &'a ChangeInfo {
  40. <ChangeInfo as ::protobuf::Message>::default_instance()
  41. }
  42. }
  43. impl ChangeInfo {
  44. pub fn new() -> ChangeInfo {
  45. ::std::default::Default::default()
  46. }
  47. // optional string user = 1;
  48. pub fn get_user(&self) -> &str {
  49. match self.user.as_ref() {
  50. Some(v) => &v,
  51. None => "",
  52. }
  53. }
  54. pub fn clear_user(&mut self) {
  55. self.user.clear();
  56. }
  57. pub fn has_user(&self) -> bool {
  58. self.user.is_some()
  59. }
  60. // Param is passed by value, moved
  61. pub fn set_user(&mut self, v: ::std::string::String) {
  62. self.user = ::protobuf::SingularField::some(v);
  63. }
  64. // Mutable pointer to the field.
  65. // If field is not initialized, it is initialized with default value first.
  66. pub fn mut_user(&mut self) -> &mut ::std::string::String {
  67. if self.user.is_none() {
  68. self.user.set_default();
  69. }
  70. self.user.as_mut().unwrap()
  71. }
  72. // Take field
  73. pub fn take_user(&mut self) -> ::std::string::String {
  74. self.user.take().unwrap_or_else(|| ::std::string::String::new())
  75. }
  76. // optional int32 timestamp = 2;
  77. pub fn get_timestamp(&self) -> i32 {
  78. self.timestamp.unwrap_or(0)
  79. }
  80. pub fn clear_timestamp(&mut self) {
  81. self.timestamp = ::std::option::Option::None;
  82. }
  83. pub fn has_timestamp(&self) -> bool {
  84. self.timestamp.is_some()
  85. }
  86. // Param is passed by value, moved
  87. pub fn set_timestamp(&mut self, v: i32) {
  88. self.timestamp = ::std::option::Option::Some(v);
  89. }
  90. // optional bool admin = 3;
  91. pub fn get_admin(&self) -> bool {
  92. self.admin.unwrap_or(false)
  93. }
  94. pub fn clear_admin(&mut self) {
  95. self.admin = ::std::option::Option::None;
  96. }
  97. pub fn has_admin(&self) -> bool {
  98. self.admin.is_some()
  99. }
  100. // Param is passed by value, moved
  101. pub fn set_admin(&mut self, v: bool) {
  102. self.admin = ::std::option::Option::Some(v);
  103. }
  104. // optional bool undo = 4;
  105. pub fn get_undo(&self) -> bool {
  106. self.undo.unwrap_or(false)
  107. }
  108. pub fn clear_undo(&mut self) {
  109. self.undo = ::std::option::Option::None;
  110. }
  111. pub fn has_undo(&self) -> bool {
  112. self.undo.is_some()
  113. }
  114. // Param is passed by value, moved
  115. pub fn set_undo(&mut self, v: bool) {
  116. self.undo = ::std::option::Option::Some(v);
  117. }
  118. // optional bool redo = 5;
  119. pub fn get_redo(&self) -> bool {
  120. self.redo.unwrap_or(false)
  121. }
  122. pub fn clear_redo(&mut self) {
  123. self.redo = ::std::option::Option::None;
  124. }
  125. pub fn has_redo(&self) -> bool {
  126. self.redo.is_some()
  127. }
  128. // Param is passed by value, moved
  129. pub fn set_redo(&mut self, v: bool) {
  130. self.redo = ::std::option::Option::Some(v);
  131. }
  132. // optional bool merge = 6;
  133. pub fn get_merge(&self) -> bool {
  134. self.merge.unwrap_or(false)
  135. }
  136. pub fn clear_merge(&mut self) {
  137. self.merge = ::std::option::Option::None;
  138. }
  139. pub fn has_merge(&self) -> bool {
  140. self.merge.is_some()
  141. }
  142. // Param is passed by value, moved
  143. pub fn set_merge(&mut self, v: bool) {
  144. self.merge = ::std::option::Option::Some(v);
  145. }
  146. // optional bool compressed = 7;
  147. pub fn get_compressed(&self) -> bool {
  148. self.compressed.unwrap_or(false)
  149. }
  150. pub fn clear_compressed(&mut self) {
  151. self.compressed = ::std::option::Option::None;
  152. }
  153. pub fn has_compressed(&self) -> bool {
  154. self.compressed.is_some()
  155. }
  156. // Param is passed by value, moved
  157. pub fn set_compressed(&mut self, v: bool) {
  158. self.compressed = ::std::option::Option::Some(v);
  159. }
  160. // optional bool migration = 8;
  161. pub fn get_migration(&self) -> bool {
  162. self.migration.unwrap_or(false)
  163. }
  164. pub fn clear_migration(&mut self) {
  165. self.migration = ::std::option::Option::None;
  166. }
  167. pub fn has_migration(&self) -> bool {
  168. self.migration.is_some()
  169. }
  170. // Param is passed by value, moved
  171. pub fn set_migration(&mut self, v: bool) {
  172. self.migration = ::std::option::Option::Some(v);
  173. }
  174. }
  175. impl ::protobuf::Message for ChangeInfo {
  176. fn is_initialized(&self) -> bool {
  177. true
  178. }
  179. fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream) -> ::protobuf::ProtobufResult<()> {
  180. while !is.eof()? {
  181. let (field_number, wire_type) = is.read_tag_unpack()?;
  182. match field_number {
  183. 1 => {
  184. ::protobuf::rt::read_singular_string_into(wire_type, is, &mut self.user)?;
  185. },
  186. 2 => {
  187. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  188. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  189. }
  190. let tmp = is.read_int32()?;
  191. self.timestamp = ::std::option::Option::Some(tmp);
  192. },
  193. 3 => {
  194. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  195. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  196. }
  197. let tmp = is.read_bool()?;
  198. self.admin = ::std::option::Option::Some(tmp);
  199. },
  200. 4 => {
  201. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  202. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  203. }
  204. let tmp = is.read_bool()?;
  205. self.undo = ::std::option::Option::Some(tmp);
  206. },
  207. 5 => {
  208. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  209. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  210. }
  211. let tmp = is.read_bool()?;
  212. self.redo = ::std::option::Option::Some(tmp);
  213. },
  214. 6 => {
  215. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  216. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  217. }
  218. let tmp = is.read_bool()?;
  219. self.merge = ::std::option::Option::Some(tmp);
  220. },
  221. 7 => {
  222. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  223. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  224. }
  225. let tmp = is.read_bool()?;
  226. self.compressed = ::std::option::Option::Some(tmp);
  227. },
  228. 8 => {
  229. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  230. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  231. }
  232. let tmp = is.read_bool()?;
  233. self.migration = ::std::option::Option::Some(tmp);
  234. },
  235. _ => {
  236. ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
  237. },
  238. };
  239. }
  240. ::std::result::Result::Ok(())
  241. }
  242. // Compute sizes of nested messages
  243. #[allow(unused_variables)]
  244. fn compute_size(&self) -> u32 {
  245. let mut my_size = 0;
  246. if let Some(ref v) = self.user.as_ref() {
  247. my_size += ::protobuf::rt::string_size(1, &v);
  248. }
  249. if let Some(v) = self.timestamp {
  250. my_size += ::protobuf::rt::value_size(2, v, ::protobuf::wire_format::WireTypeVarint);
  251. }
  252. if let Some(v) = self.admin {
  253. my_size += 2;
  254. }
  255. if let Some(v) = self.undo {
  256. my_size += 2;
  257. }
  258. if let Some(v) = self.redo {
  259. my_size += 2;
  260. }
  261. if let Some(v) = self.merge {
  262. my_size += 2;
  263. }
  264. if let Some(v) = self.compressed {
  265. my_size += 2;
  266. }
  267. if let Some(v) = self.migration {
  268. my_size += 2;
  269. }
  270. my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
  271. self.cached_size.set(my_size);
  272. my_size
  273. }
  274. fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream) -> ::protobuf::ProtobufResult<()> {
  275. if let Some(ref v) = self.user.as_ref() {
  276. os.write_string(1, &v)?;
  277. }
  278. if let Some(v) = self.timestamp {
  279. os.write_int32(2, v)?;
  280. }
  281. if let Some(v) = self.admin {
  282. os.write_bool(3, v)?;
  283. }
  284. if let Some(v) = self.undo {
  285. os.write_bool(4, v)?;
  286. }
  287. if let Some(v) = self.redo {
  288. os.write_bool(5, v)?;
  289. }
  290. if let Some(v) = self.merge {
  291. os.write_bool(6, v)?;
  292. }
  293. if let Some(v) = self.compressed {
  294. os.write_bool(7, v)?;
  295. }
  296. if let Some(v) = self.migration {
  297. os.write_bool(8, v)?;
  298. }
  299. os.write_unknown_fields(self.get_unknown_fields())?;
  300. ::std::result::Result::Ok(())
  301. }
  302. fn get_cached_size(&self) -> u32 {
  303. self.cached_size.get()
  304. }
  305. fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
  306. &self.unknown_fields
  307. }
  308. fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
  309. &mut self.unknown_fields
  310. }
  311. fn as_any(&self) -> &::std::any::Any {
  312. self as &::std::any::Any
  313. }
  314. fn as_any_mut(&mut self) -> &mut ::std::any::Any {
  315. self as &mut ::std::any::Any
  316. }
  317. fn into_any(self: Box<Self>) -> ::std::boxed::Box<::std::any::Any> {
  318. self
  319. }
  320. fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
  321. Self::descriptor_static()
  322. }
  323. fn new() -> ChangeInfo {
  324. ChangeInfo::new()
  325. }
  326. fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
  327. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
  328. lock: ::protobuf::lazy::ONCE_INIT,
  329. ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
  330. };
  331. unsafe {
  332. descriptor.get(|| {
  333. let mut fields = ::std::vec::Vec::new();
  334. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeString>(
  335. "user",
  336. |m: &ChangeInfo| { &m.user },
  337. |m: &mut ChangeInfo| { &mut m.user },
  338. ));
  339. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeInt32>(
  340. "timestamp",
  341. |m: &ChangeInfo| { &m.timestamp },
  342. |m: &mut ChangeInfo| { &mut m.timestamp },
  343. ));
  344. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  345. "admin",
  346. |m: &ChangeInfo| { &m.admin },
  347. |m: &mut ChangeInfo| { &mut m.admin },
  348. ));
  349. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  350. "undo",
  351. |m: &ChangeInfo| { &m.undo },
  352. |m: &mut ChangeInfo| { &mut m.undo },
  353. ));
  354. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  355. "redo",
  356. |m: &ChangeInfo| { &m.redo },
  357. |m: &mut ChangeInfo| { &mut m.redo },
  358. ));
  359. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  360. "merge",
  361. |m: &ChangeInfo| { &m.merge },
  362. |m: &mut ChangeInfo| { &mut m.merge },
  363. ));
  364. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  365. "compressed",
  366. |m: &ChangeInfo| { &m.compressed },
  367. |m: &mut ChangeInfo| { &mut m.compressed },
  368. ));
  369. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  370. "migration",
  371. |m: &ChangeInfo| { &m.migration },
  372. |m: &mut ChangeInfo| { &mut m.migration },
  373. ));
  374. ::protobuf::reflect::MessageDescriptor::new::<ChangeInfo>(
  375. "ChangeInfo",
  376. fields,
  377. file_descriptor_proto()
  378. )
  379. })
  380. }
  381. }
  382. fn default_instance() -> &'static ChangeInfo {
  383. static mut instance: ::protobuf::lazy::Lazy<ChangeInfo> = ::protobuf::lazy::Lazy {
  384. lock: ::protobuf::lazy::ONCE_INIT,
  385. ptr: 0 as *const ChangeInfo,
  386. };
  387. unsafe {
  388. instance.get(ChangeInfo::new)
  389. }
  390. }
  391. }
  392. impl ::protobuf::Clear for ChangeInfo {
  393. fn clear(&mut self) {
  394. self.user.clear();
  395. self.timestamp = ::std::option::Option::None;
  396. self.admin = ::std::option::Option::None;
  397. self.undo = ::std::option::Option::None;
  398. self.redo = ::std::option::Option::None;
  399. self.merge = ::std::option::Option::None;
  400. self.compressed = ::std::option::Option::None;
  401. self.migration = ::std::option::Option::None;
  402. self.unknown_fields.clear();
  403. }
  404. }
  405. impl ::std::fmt::Debug for ChangeInfo {
  406. fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
  407. ::protobuf::text_format::fmt(self, f)
  408. }
  409. }
  410. impl ::protobuf::reflect::ProtobufValue for ChangeInfo {
  411. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  412. ::protobuf::reflect::ProtobufValueRef::Message(self)
  413. }
  414. }
  415. #[derive(PartialEq,Clone,Default)]
  416. pub struct Delta {
  417. // message fields
  418. base_version: ::protobuf::SingularField<::std::vec::Vec<u8>>,
  419. ops: ::protobuf::RepeatedField<super::playlist4ops::Op>,
  420. info: ::protobuf::SingularPtrField<ChangeInfo>,
  421. // special fields
  422. pub unknown_fields: ::protobuf::UnknownFields,
  423. pub cached_size: ::protobuf::CachedSize,
  424. }
  425. impl<'a> ::std::default::Default for &'a Delta {
  426. fn default() -> &'a Delta {
  427. <Delta as ::protobuf::Message>::default_instance()
  428. }
  429. }
  430. impl Delta {
  431. pub fn new() -> Delta {
  432. ::std::default::Default::default()
  433. }
  434. // optional bytes base_version = 1;
  435. pub fn get_base_version(&self) -> &[u8] {
  436. match self.base_version.as_ref() {
  437. Some(v) => &v,
  438. None => &[],
  439. }
  440. }
  441. pub fn clear_base_version(&mut self) {
  442. self.base_version.clear();
  443. }
  444. pub fn has_base_version(&self) -> bool {
  445. self.base_version.is_some()
  446. }
  447. // Param is passed by value, moved
  448. pub fn set_base_version(&mut self, v: ::std::vec::Vec<u8>) {
  449. self.base_version = ::protobuf::SingularField::some(v);
  450. }
  451. // Mutable pointer to the field.
  452. // If field is not initialized, it is initialized with default value first.
  453. pub fn mut_base_version(&mut self) -> &mut ::std::vec::Vec<u8> {
  454. if self.base_version.is_none() {
  455. self.base_version.set_default();
  456. }
  457. self.base_version.as_mut().unwrap()
  458. }
  459. // Take field
  460. pub fn take_base_version(&mut self) -> ::std::vec::Vec<u8> {
  461. self.base_version.take().unwrap_or_else(|| ::std::vec::Vec::new())
  462. }
  463. // repeated .Op ops = 2;
  464. pub fn get_ops(&self) -> &[super::playlist4ops::Op] {
  465. &self.ops
  466. }
  467. pub fn clear_ops(&mut self) {
  468. self.ops.clear();
  469. }
  470. // Param is passed by value, moved
  471. pub fn set_ops(&mut self, v: ::protobuf::RepeatedField<super::playlist4ops::Op>) {
  472. self.ops = v;
  473. }
  474. // Mutable pointer to the field.
  475. pub fn mut_ops(&mut self) -> &mut ::protobuf::RepeatedField<super::playlist4ops::Op> {
  476. &mut self.ops
  477. }
  478. // Take field
  479. pub fn take_ops(&mut self) -> ::protobuf::RepeatedField<super::playlist4ops::Op> {
  480. ::std::mem::replace(&mut self.ops, ::protobuf::RepeatedField::new())
  481. }
  482. // optional .ChangeInfo info = 4;
  483. pub fn get_info(&self) -> &ChangeInfo {
  484. self.info.as_ref().unwrap_or_else(|| ChangeInfo::default_instance())
  485. }
  486. pub fn clear_info(&mut self) {
  487. self.info.clear();
  488. }
  489. pub fn has_info(&self) -> bool {
  490. self.info.is_some()
  491. }
  492. // Param is passed by value, moved
  493. pub fn set_info(&mut self, v: ChangeInfo) {
  494. self.info = ::protobuf::SingularPtrField::some(v);
  495. }
  496. // Mutable pointer to the field.
  497. // If field is not initialized, it is initialized with default value first.
  498. pub fn mut_info(&mut self) -> &mut ChangeInfo {
  499. if self.info.is_none() {
  500. self.info.set_default();
  501. }
  502. self.info.as_mut().unwrap()
  503. }
  504. // Take field
  505. pub fn take_info(&mut self) -> ChangeInfo {
  506. self.info.take().unwrap_or_else(|| ChangeInfo::new())
  507. }
  508. }
  509. impl ::protobuf::Message for Delta {
  510. fn is_initialized(&self) -> bool {
  511. for v in &self.ops {
  512. if !v.is_initialized() {
  513. return false;
  514. }
  515. };
  516. for v in &self.info {
  517. if !v.is_initialized() {
  518. return false;
  519. }
  520. };
  521. true
  522. }
  523. fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream) -> ::protobuf::ProtobufResult<()> {
  524. while !is.eof()? {
  525. let (field_number, wire_type) = is.read_tag_unpack()?;
  526. match field_number {
  527. 1 => {
  528. ::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.base_version)?;
  529. },
  530. 2 => {
  531. ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.ops)?;
  532. },
  533. 4 => {
  534. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.info)?;
  535. },
  536. _ => {
  537. ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
  538. },
  539. };
  540. }
  541. ::std::result::Result::Ok(())
  542. }
  543. // Compute sizes of nested messages
  544. #[allow(unused_variables)]
  545. fn compute_size(&self) -> u32 {
  546. let mut my_size = 0;
  547. if let Some(ref v) = self.base_version.as_ref() {
  548. my_size += ::protobuf::rt::bytes_size(1, &v);
  549. }
  550. for value in &self.ops {
  551. let len = value.compute_size();
  552. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  553. };
  554. if let Some(ref v) = self.info.as_ref() {
  555. let len = v.compute_size();
  556. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  557. }
  558. my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
  559. self.cached_size.set(my_size);
  560. my_size
  561. }
  562. fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream) -> ::protobuf::ProtobufResult<()> {
  563. if let Some(ref v) = self.base_version.as_ref() {
  564. os.write_bytes(1, &v)?;
  565. }
  566. for v in &self.ops {
  567. os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  568. os.write_raw_varint32(v.get_cached_size())?;
  569. v.write_to_with_cached_sizes(os)?;
  570. };
  571. if let Some(ref v) = self.info.as_ref() {
  572. os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  573. os.write_raw_varint32(v.get_cached_size())?;
  574. v.write_to_with_cached_sizes(os)?;
  575. }
  576. os.write_unknown_fields(self.get_unknown_fields())?;
  577. ::std::result::Result::Ok(())
  578. }
  579. fn get_cached_size(&self) -> u32 {
  580. self.cached_size.get()
  581. }
  582. fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
  583. &self.unknown_fields
  584. }
  585. fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
  586. &mut self.unknown_fields
  587. }
  588. fn as_any(&self) -> &::std::any::Any {
  589. self as &::std::any::Any
  590. }
  591. fn as_any_mut(&mut self) -> &mut ::std::any::Any {
  592. self as &mut ::std::any::Any
  593. }
  594. fn into_any(self: Box<Self>) -> ::std::boxed::Box<::std::any::Any> {
  595. self
  596. }
  597. fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
  598. Self::descriptor_static()
  599. }
  600. fn new() -> Delta {
  601. Delta::new()
  602. }
  603. fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
  604. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
  605. lock: ::protobuf::lazy::ONCE_INIT,
  606. ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
  607. };
  608. unsafe {
  609. descriptor.get(|| {
  610. let mut fields = ::std::vec::Vec::new();
  611. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  612. "base_version",
  613. |m: &Delta| { &m.base_version },
  614. |m: &mut Delta| { &mut m.base_version },
  615. ));
  616. fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4ops::Op>>(
  617. "ops",
  618. |m: &Delta| { &m.ops },
  619. |m: &mut Delta| { &mut m.ops },
  620. ));
  621. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChangeInfo>>(
  622. "info",
  623. |m: &Delta| { &m.info },
  624. |m: &mut Delta| { &mut m.info },
  625. ));
  626. ::protobuf::reflect::MessageDescriptor::new::<Delta>(
  627. "Delta",
  628. fields,
  629. file_descriptor_proto()
  630. )
  631. })
  632. }
  633. }
  634. fn default_instance() -> &'static Delta {
  635. static mut instance: ::protobuf::lazy::Lazy<Delta> = ::protobuf::lazy::Lazy {
  636. lock: ::protobuf::lazy::ONCE_INIT,
  637. ptr: 0 as *const Delta,
  638. };
  639. unsafe {
  640. instance.get(Delta::new)
  641. }
  642. }
  643. }
  644. impl ::protobuf::Clear for Delta {
  645. fn clear(&mut self) {
  646. self.base_version.clear();
  647. self.ops.clear();
  648. self.info.clear();
  649. self.unknown_fields.clear();
  650. }
  651. }
  652. impl ::std::fmt::Debug for Delta {
  653. fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
  654. ::protobuf::text_format::fmt(self, f)
  655. }
  656. }
  657. impl ::protobuf::reflect::ProtobufValue for Delta {
  658. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  659. ::protobuf::reflect::ProtobufValueRef::Message(self)
  660. }
  661. }
  662. #[derive(PartialEq,Clone,Default)]
  663. pub struct Merge {
  664. // message fields
  665. base_version: ::protobuf::SingularField<::std::vec::Vec<u8>>,
  666. merge_version: ::protobuf::SingularField<::std::vec::Vec<u8>>,
  667. info: ::protobuf::SingularPtrField<ChangeInfo>,
  668. // special fields
  669. pub unknown_fields: ::protobuf::UnknownFields,
  670. pub cached_size: ::protobuf::CachedSize,
  671. }
  672. impl<'a> ::std::default::Default for &'a Merge {
  673. fn default() -> &'a Merge {
  674. <Merge as ::protobuf::Message>::default_instance()
  675. }
  676. }
  677. impl Merge {
  678. pub fn new() -> Merge {
  679. ::std::default::Default::default()
  680. }
  681. // optional bytes base_version = 1;
  682. pub fn get_base_version(&self) -> &[u8] {
  683. match self.base_version.as_ref() {
  684. Some(v) => &v,
  685. None => &[],
  686. }
  687. }
  688. pub fn clear_base_version(&mut self) {
  689. self.base_version.clear();
  690. }
  691. pub fn has_base_version(&self) -> bool {
  692. self.base_version.is_some()
  693. }
  694. // Param is passed by value, moved
  695. pub fn set_base_version(&mut self, v: ::std::vec::Vec<u8>) {
  696. self.base_version = ::protobuf::SingularField::some(v);
  697. }
  698. // Mutable pointer to the field.
  699. // If field is not initialized, it is initialized with default value first.
  700. pub fn mut_base_version(&mut self) -> &mut ::std::vec::Vec<u8> {
  701. if self.base_version.is_none() {
  702. self.base_version.set_default();
  703. }
  704. self.base_version.as_mut().unwrap()
  705. }
  706. // Take field
  707. pub fn take_base_version(&mut self) -> ::std::vec::Vec<u8> {
  708. self.base_version.take().unwrap_or_else(|| ::std::vec::Vec::new())
  709. }
  710. // optional bytes merge_version = 2;
  711. pub fn get_merge_version(&self) -> &[u8] {
  712. match self.merge_version.as_ref() {
  713. Some(v) => &v,
  714. None => &[],
  715. }
  716. }
  717. pub fn clear_merge_version(&mut self) {
  718. self.merge_version.clear();
  719. }
  720. pub fn has_merge_version(&self) -> bool {
  721. self.merge_version.is_some()
  722. }
  723. // Param is passed by value, moved
  724. pub fn set_merge_version(&mut self, v: ::std::vec::Vec<u8>) {
  725. self.merge_version = ::protobuf::SingularField::some(v);
  726. }
  727. // Mutable pointer to the field.
  728. // If field is not initialized, it is initialized with default value first.
  729. pub fn mut_merge_version(&mut self) -> &mut ::std::vec::Vec<u8> {
  730. if self.merge_version.is_none() {
  731. self.merge_version.set_default();
  732. }
  733. self.merge_version.as_mut().unwrap()
  734. }
  735. // Take field
  736. pub fn take_merge_version(&mut self) -> ::std::vec::Vec<u8> {
  737. self.merge_version.take().unwrap_or_else(|| ::std::vec::Vec::new())
  738. }
  739. // optional .ChangeInfo info = 4;
  740. pub fn get_info(&self) -> &ChangeInfo {
  741. self.info.as_ref().unwrap_or_else(|| ChangeInfo::default_instance())
  742. }
  743. pub fn clear_info(&mut self) {
  744. self.info.clear();
  745. }
  746. pub fn has_info(&self) -> bool {
  747. self.info.is_some()
  748. }
  749. // Param is passed by value, moved
  750. pub fn set_info(&mut self, v: ChangeInfo) {
  751. self.info = ::protobuf::SingularPtrField::some(v);
  752. }
  753. // Mutable pointer to the field.
  754. // If field is not initialized, it is initialized with default value first.
  755. pub fn mut_info(&mut self) -> &mut ChangeInfo {
  756. if self.info.is_none() {
  757. self.info.set_default();
  758. }
  759. self.info.as_mut().unwrap()
  760. }
  761. // Take field
  762. pub fn take_info(&mut self) -> ChangeInfo {
  763. self.info.take().unwrap_or_else(|| ChangeInfo::new())
  764. }
  765. }
  766. impl ::protobuf::Message for Merge {
  767. fn is_initialized(&self) -> bool {
  768. for v in &self.info {
  769. if !v.is_initialized() {
  770. return false;
  771. }
  772. };
  773. true
  774. }
  775. fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream) -> ::protobuf::ProtobufResult<()> {
  776. while !is.eof()? {
  777. let (field_number, wire_type) = is.read_tag_unpack()?;
  778. match field_number {
  779. 1 => {
  780. ::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.base_version)?;
  781. },
  782. 2 => {
  783. ::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.merge_version)?;
  784. },
  785. 4 => {
  786. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.info)?;
  787. },
  788. _ => {
  789. ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
  790. },
  791. };
  792. }
  793. ::std::result::Result::Ok(())
  794. }
  795. // Compute sizes of nested messages
  796. #[allow(unused_variables)]
  797. fn compute_size(&self) -> u32 {
  798. let mut my_size = 0;
  799. if let Some(ref v) = self.base_version.as_ref() {
  800. my_size += ::protobuf::rt::bytes_size(1, &v);
  801. }
  802. if let Some(ref v) = self.merge_version.as_ref() {
  803. my_size += ::protobuf::rt::bytes_size(2, &v);
  804. }
  805. if let Some(ref v) = self.info.as_ref() {
  806. let len = v.compute_size();
  807. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  808. }
  809. my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
  810. self.cached_size.set(my_size);
  811. my_size
  812. }
  813. fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream) -> ::protobuf::ProtobufResult<()> {
  814. if let Some(ref v) = self.base_version.as_ref() {
  815. os.write_bytes(1, &v)?;
  816. }
  817. if let Some(ref v) = self.merge_version.as_ref() {
  818. os.write_bytes(2, &v)?;
  819. }
  820. if let Some(ref v) = self.info.as_ref() {
  821. os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  822. os.write_raw_varint32(v.get_cached_size())?;
  823. v.write_to_with_cached_sizes(os)?;
  824. }
  825. os.write_unknown_fields(self.get_unknown_fields())?;
  826. ::std::result::Result::Ok(())
  827. }
  828. fn get_cached_size(&self) -> u32 {
  829. self.cached_size.get()
  830. }
  831. fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
  832. &self.unknown_fields
  833. }
  834. fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
  835. &mut self.unknown_fields
  836. }
  837. fn as_any(&self) -> &::std::any::Any {
  838. self as &::std::any::Any
  839. }
  840. fn as_any_mut(&mut self) -> &mut ::std::any::Any {
  841. self as &mut ::std::any::Any
  842. }
  843. fn into_any(self: Box<Self>) -> ::std::boxed::Box<::std::any::Any> {
  844. self
  845. }
  846. fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
  847. Self::descriptor_static()
  848. }
  849. fn new() -> Merge {
  850. Merge::new()
  851. }
  852. fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
  853. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
  854. lock: ::protobuf::lazy::ONCE_INIT,
  855. ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
  856. };
  857. unsafe {
  858. descriptor.get(|| {
  859. let mut fields = ::std::vec::Vec::new();
  860. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  861. "base_version",
  862. |m: &Merge| { &m.base_version },
  863. |m: &mut Merge| { &mut m.base_version },
  864. ));
  865. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  866. "merge_version",
  867. |m: &Merge| { &m.merge_version },
  868. |m: &mut Merge| { &mut m.merge_version },
  869. ));
  870. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChangeInfo>>(
  871. "info",
  872. |m: &Merge| { &m.info },
  873. |m: &mut Merge| { &mut m.info },
  874. ));
  875. ::protobuf::reflect::MessageDescriptor::new::<Merge>(
  876. "Merge",
  877. fields,
  878. file_descriptor_proto()
  879. )
  880. })
  881. }
  882. }
  883. fn default_instance() -> &'static Merge {
  884. static mut instance: ::protobuf::lazy::Lazy<Merge> = ::protobuf::lazy::Lazy {
  885. lock: ::protobuf::lazy::ONCE_INIT,
  886. ptr: 0 as *const Merge,
  887. };
  888. unsafe {
  889. instance.get(Merge::new)
  890. }
  891. }
  892. }
  893. impl ::protobuf::Clear for Merge {
  894. fn clear(&mut self) {
  895. self.base_version.clear();
  896. self.merge_version.clear();
  897. self.info.clear();
  898. self.unknown_fields.clear();
  899. }
  900. }
  901. impl ::std::fmt::Debug for Merge {
  902. fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
  903. ::protobuf::text_format::fmt(self, f)
  904. }
  905. }
  906. impl ::protobuf::reflect::ProtobufValue for Merge {
  907. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  908. ::protobuf::reflect::ProtobufValueRef::Message(self)
  909. }
  910. }
  911. #[derive(PartialEq,Clone,Default)]
  912. pub struct ChangeSet {
  913. // message fields
  914. kind: ::std::option::Option<ChangeSet_Kind>,
  915. delta: ::protobuf::SingularPtrField<Delta>,
  916. merge: ::protobuf::SingularPtrField<Merge>,
  917. // special fields
  918. pub unknown_fields: ::protobuf::UnknownFields,
  919. pub cached_size: ::protobuf::CachedSize,
  920. }
  921. impl<'a> ::std::default::Default for &'a ChangeSet {
  922. fn default() -> &'a ChangeSet {
  923. <ChangeSet as ::protobuf::Message>::default_instance()
  924. }
  925. }
  926. impl ChangeSet {
  927. pub fn new() -> ChangeSet {
  928. ::std::default::Default::default()
  929. }
  930. // optional .ChangeSet.Kind kind = 1;
  931. pub fn get_kind(&self) -> ChangeSet_Kind {
  932. self.kind.unwrap_or(ChangeSet_Kind::KIND_UNKNOWN)
  933. }
  934. pub fn clear_kind(&mut self) {
  935. self.kind = ::std::option::Option::None;
  936. }
  937. pub fn has_kind(&self) -> bool {
  938. self.kind.is_some()
  939. }
  940. // Param is passed by value, moved
  941. pub fn set_kind(&mut self, v: ChangeSet_Kind) {
  942. self.kind = ::std::option::Option::Some(v);
  943. }
  944. // optional .Delta delta = 2;
  945. pub fn get_delta(&self) -> &Delta {
  946. self.delta.as_ref().unwrap_or_else(|| Delta::default_instance())
  947. }
  948. pub fn clear_delta(&mut self) {
  949. self.delta.clear();
  950. }
  951. pub fn has_delta(&self) -> bool {
  952. self.delta.is_some()
  953. }
  954. // Param is passed by value, moved
  955. pub fn set_delta(&mut self, v: Delta) {
  956. self.delta = ::protobuf::SingularPtrField::some(v);
  957. }
  958. // Mutable pointer to the field.
  959. // If field is not initialized, it is initialized with default value first.
  960. pub fn mut_delta(&mut self) -> &mut Delta {
  961. if self.delta.is_none() {
  962. self.delta.set_default();
  963. }
  964. self.delta.as_mut().unwrap()
  965. }
  966. // Take field
  967. pub fn take_delta(&mut self) -> Delta {
  968. self.delta.take().unwrap_or_else(|| Delta::new())
  969. }
  970. // optional .Merge merge = 3;
  971. pub fn get_merge(&self) -> &Merge {
  972. self.merge.as_ref().unwrap_or_else(|| Merge::default_instance())
  973. }
  974. pub fn clear_merge(&mut self) {
  975. self.merge.clear();
  976. }
  977. pub fn has_merge(&self) -> bool {
  978. self.merge.is_some()
  979. }
  980. // Param is passed by value, moved
  981. pub fn set_merge(&mut self, v: Merge) {
  982. self.merge = ::protobuf::SingularPtrField::some(v);
  983. }
  984. // Mutable pointer to the field.
  985. // If field is not initialized, it is initialized with default value first.
  986. pub fn mut_merge(&mut self) -> &mut Merge {
  987. if self.merge.is_none() {
  988. self.merge.set_default();
  989. }
  990. self.merge.as_mut().unwrap()
  991. }
  992. // Take field
  993. pub fn take_merge(&mut self) -> Merge {
  994. self.merge.take().unwrap_or_else(|| Merge::new())
  995. }
  996. }
  997. impl ::protobuf::Message for ChangeSet {
  998. fn is_initialized(&self) -> bool {
  999. for v in &self.delta {
  1000. if !v.is_initialized() {
  1001. return false;
  1002. }
  1003. };
  1004. for v in &self.merge {
  1005. if !v.is_initialized() {
  1006. return false;
  1007. }
  1008. };
  1009. true
  1010. }
  1011. fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream) -> ::protobuf::ProtobufResult<()> {
  1012. while !is.eof()? {
  1013. let (field_number, wire_type) = is.read_tag_unpack()?;
  1014. match field_number {
  1015. 1 => {
  1016. ::protobuf::rt::read_proto2_enum_with_unknown_fields_into(wire_type, is, &mut self.kind, 1, &mut self.unknown_fields)?
  1017. },
  1018. 2 => {
  1019. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.delta)?;
  1020. },
  1021. 3 => {
  1022. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.merge)?;
  1023. },
  1024. _ => {
  1025. ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
  1026. },
  1027. };
  1028. }
  1029. ::std::result::Result::Ok(())
  1030. }
  1031. // Compute sizes of nested messages
  1032. #[allow(unused_variables)]
  1033. fn compute_size(&self) -> u32 {
  1034. let mut my_size = 0;
  1035. if let Some(v) = self.kind {
  1036. my_size += ::protobuf::rt::enum_size(1, v);
  1037. }
  1038. if let Some(ref v) = self.delta.as_ref() {
  1039. let len = v.compute_size();
  1040. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  1041. }
  1042. if let Some(ref v) = self.merge.as_ref() {
  1043. let len = v.compute_size();
  1044. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  1045. }
  1046. my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
  1047. self.cached_size.set(my_size);
  1048. my_size
  1049. }
  1050. fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream) -> ::protobuf::ProtobufResult<()> {
  1051. if let Some(v) = self.kind {
  1052. os.write_enum(1, v.value())?;
  1053. }
  1054. if let Some(ref v) = self.delta.as_ref() {
  1055. os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  1056. os.write_raw_varint32(v.get_cached_size())?;
  1057. v.write_to_with_cached_sizes(os)?;
  1058. }
  1059. if let Some(ref v) = self.merge.as_ref() {
  1060. os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  1061. os.write_raw_varint32(v.get_cached_size())?;
  1062. v.write_to_with_cached_sizes(os)?;
  1063. }
  1064. os.write_unknown_fields(self.get_unknown_fields())?;
  1065. ::std::result::Result::Ok(())
  1066. }
  1067. fn get_cached_size(&self) -> u32 {
  1068. self.cached_size.get()
  1069. }
  1070. fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
  1071. &self.unknown_fields
  1072. }
  1073. fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
  1074. &mut self.unknown_fields
  1075. }
  1076. fn as_any(&self) -> &::std::any::Any {
  1077. self as &::std::any::Any
  1078. }
  1079. fn as_any_mut(&mut self) -> &mut ::std::any::Any {
  1080. self as &mut ::std::any::Any
  1081. }
  1082. fn into_any(self: Box<Self>) -> ::std::boxed::Box<::std::any::Any> {
  1083. self
  1084. }
  1085. fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
  1086. Self::descriptor_static()
  1087. }
  1088. fn new() -> ChangeSet {
  1089. ChangeSet::new()
  1090. }
  1091. fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
  1092. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
  1093. lock: ::protobuf::lazy::ONCE_INIT,
  1094. ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
  1095. };
  1096. unsafe {
  1097. descriptor.get(|| {
  1098. let mut fields = ::std::vec::Vec::new();
  1099. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeEnum<ChangeSet_Kind>>(
  1100. "kind",
  1101. |m: &ChangeSet| { &m.kind },
  1102. |m: &mut ChangeSet| { &mut m.kind },
  1103. ));
  1104. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<Delta>>(
  1105. "delta",
  1106. |m: &ChangeSet| { &m.delta },
  1107. |m: &mut ChangeSet| { &mut m.delta },
  1108. ));
  1109. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<Merge>>(
  1110. "merge",
  1111. |m: &ChangeSet| { &m.merge },
  1112. |m: &mut ChangeSet| { &mut m.merge },
  1113. ));
  1114. ::protobuf::reflect::MessageDescriptor::new::<ChangeSet>(
  1115. "ChangeSet",
  1116. fields,
  1117. file_descriptor_proto()
  1118. )
  1119. })
  1120. }
  1121. }
  1122. fn default_instance() -> &'static ChangeSet {
  1123. static mut instance: ::protobuf::lazy::Lazy<ChangeSet> = ::protobuf::lazy::Lazy {
  1124. lock: ::protobuf::lazy::ONCE_INIT,
  1125. ptr: 0 as *const ChangeSet,
  1126. };
  1127. unsafe {
  1128. instance.get(ChangeSet::new)
  1129. }
  1130. }
  1131. }
  1132. impl ::protobuf::Clear for ChangeSet {
  1133. fn clear(&mut self) {
  1134. self.kind = ::std::option::Option::None;
  1135. self.delta.clear();
  1136. self.merge.clear();
  1137. self.unknown_fields.clear();
  1138. }
  1139. }
  1140. impl ::std::fmt::Debug for ChangeSet {
  1141. fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
  1142. ::protobuf::text_format::fmt(self, f)
  1143. }
  1144. }
  1145. impl ::protobuf::reflect::ProtobufValue for ChangeSet {
  1146. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  1147. ::protobuf::reflect::ProtobufValueRef::Message(self)
  1148. }
  1149. }
  1150. #[derive(Clone,PartialEq,Eq,Debug,Hash)]
  1151. pub enum ChangeSet_Kind {
  1152. KIND_UNKNOWN = 0,
  1153. DELTA = 2,
  1154. MERGE = 3,
  1155. }
  1156. impl ::protobuf::ProtobufEnum for ChangeSet_Kind {
  1157. fn value(&self) -> i32 {
  1158. *self as i32
  1159. }
  1160. fn from_i32(value: i32) -> ::std::option::Option<ChangeSet_Kind> {
  1161. match value {
  1162. 0 => ::std::option::Option::Some(ChangeSet_Kind::KIND_UNKNOWN),
  1163. 2 => ::std::option::Option::Some(ChangeSet_Kind::DELTA),
  1164. 3 => ::std::option::Option::Some(ChangeSet_Kind::MERGE),
  1165. _ => ::std::option::Option::None
  1166. }
  1167. }
  1168. fn values() -> &'static [Self] {
  1169. static values: &'static [ChangeSet_Kind] = &[
  1170. ChangeSet_Kind::KIND_UNKNOWN,
  1171. ChangeSet_Kind::DELTA,
  1172. ChangeSet_Kind::MERGE,
  1173. ];
  1174. values
  1175. }
  1176. fn enum_descriptor_static() -> &'static ::protobuf::reflect::EnumDescriptor {
  1177. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::EnumDescriptor> = ::protobuf::lazy::Lazy {
  1178. lock: ::protobuf::lazy::ONCE_INIT,
  1179. ptr: 0 as *const ::protobuf::reflect::EnumDescriptor,
  1180. };
  1181. unsafe {
  1182. descriptor.get(|| {
  1183. ::protobuf::reflect::EnumDescriptor::new("ChangeSet_Kind", file_descriptor_proto())
  1184. })
  1185. }
  1186. }
  1187. }
  1188. impl ::std::marker::Copy for ChangeSet_Kind {
  1189. }
  1190. impl ::std::default::Default for ChangeSet_Kind {
  1191. fn default() -> Self {
  1192. ChangeSet_Kind::KIND_UNKNOWN
  1193. }
  1194. }
  1195. impl ::protobuf::reflect::ProtobufValue for ChangeSet_Kind {
  1196. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  1197. ::protobuf::reflect::ProtobufValueRef::Enum(self.descriptor())
  1198. }
  1199. }
  1200. #[derive(PartialEq,Clone,Default)]
  1201. pub struct RevisionTaggedChangeSet {
  1202. // message fields
  1203. revision: ::protobuf::SingularField<::std::vec::Vec<u8>>,
  1204. change_set: ::protobuf::SingularPtrField<ChangeSet>,
  1205. // special fields
  1206. pub unknown_fields: ::protobuf::UnknownFields,
  1207. pub cached_size: ::protobuf::CachedSize,
  1208. }
  1209. impl<'a> ::std::default::Default for &'a RevisionTaggedChangeSet {
  1210. fn default() -> &'a RevisionTaggedChangeSet {
  1211. <RevisionTaggedChangeSet as ::protobuf::Message>::default_instance()
  1212. }
  1213. }
  1214. impl RevisionTaggedChangeSet {
  1215. pub fn new() -> RevisionTaggedChangeSet {
  1216. ::std::default::Default::default()
  1217. }
  1218. // optional bytes revision = 1;
  1219. pub fn get_revision(&self) -> &[u8] {
  1220. match self.revision.as_ref() {
  1221. Some(v) => &v,
  1222. None => &[],
  1223. }
  1224. }
  1225. pub fn clear_revision(&mut self) {
  1226. self.revision.clear();
  1227. }
  1228. pub fn has_revision(&self) -> bool {
  1229. self.revision.is_some()
  1230. }
  1231. // Param is passed by value, moved
  1232. pub fn set_revision(&mut self, v: ::std::vec::Vec<u8>) {
  1233. self.revision = ::protobuf::SingularField::some(v);
  1234. }
  1235. // Mutable pointer to the field.
  1236. // If field is not initialized, it is initialized with default value first.
  1237. pub fn mut_revision(&mut self) -> &mut ::std::vec::Vec<u8> {
  1238. if self.revision.is_none() {
  1239. self.revision.set_default();
  1240. }
  1241. self.revision.as_mut().unwrap()
  1242. }
  1243. // Take field
  1244. pub fn take_revision(&mut self) -> ::std::vec::Vec<u8> {
  1245. self.revision.take().unwrap_or_else(|| ::std::vec::Vec::new())
  1246. }
  1247. // optional .ChangeSet change_set = 2;
  1248. pub fn get_change_set(&self) -> &ChangeSet {
  1249. self.change_set.as_ref().unwrap_or_else(|| ChangeSet::default_instance())
  1250. }
  1251. pub fn clear_change_set(&mut self) {
  1252. self.change_set.clear();
  1253. }
  1254. pub fn has_change_set(&self) -> bool {
  1255. self.change_set.is_some()
  1256. }
  1257. // Param is passed by value, moved
  1258. pub fn set_change_set(&mut self, v: ChangeSet) {
  1259. self.change_set = ::protobuf::SingularPtrField::some(v);
  1260. }
  1261. // Mutable pointer to the field.
  1262. // If field is not initialized, it is initialized with default value first.
  1263. pub fn mut_change_set(&mut self) -> &mut ChangeSet {
  1264. if self.change_set.is_none() {
  1265. self.change_set.set_default();
  1266. }
  1267. self.change_set.as_mut().unwrap()
  1268. }
  1269. // Take field
  1270. pub fn take_change_set(&mut self) -> ChangeSet {
  1271. self.change_set.take().unwrap_or_else(|| ChangeSet::new())
  1272. }
  1273. }
  1274. impl ::protobuf::Message for RevisionTaggedChangeSet {
  1275. fn is_initialized(&self) -> bool {
  1276. for v in &self.change_set {
  1277. if !v.is_initialized() {
  1278. return false;
  1279. }
  1280. };
  1281. true
  1282. }
  1283. fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream) -> ::protobuf::ProtobufResult<()> {
  1284. while !is.eof()? {
  1285. let (field_number, wire_type) = is.read_tag_unpack()?;
  1286. match field_number {
  1287. 1 => {
  1288. ::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.revision)?;
  1289. },
  1290. 2 => {
  1291. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.change_set)?;
  1292. },
  1293. _ => {
  1294. ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
  1295. },
  1296. };
  1297. }
  1298. ::std::result::Result::Ok(())
  1299. }
  1300. // Compute sizes of nested messages
  1301. #[allow(unused_variables)]
  1302. fn compute_size(&self) -> u32 {
  1303. let mut my_size = 0;
  1304. if let Some(ref v) = self.revision.as_ref() {
  1305. my_size += ::protobuf::rt::bytes_size(1, &v);
  1306. }
  1307. if let Some(ref v) = self.change_set.as_ref() {
  1308. let len = v.compute_size();
  1309. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  1310. }
  1311. my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
  1312. self.cached_size.set(my_size);
  1313. my_size
  1314. }
  1315. fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream) -> ::protobuf::ProtobufResult<()> {
  1316. if let Some(ref v) = self.revision.as_ref() {
  1317. os.write_bytes(1, &v)?;
  1318. }
  1319. if let Some(ref v) = self.change_set.as_ref() {
  1320. os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  1321. os.write_raw_varint32(v.get_cached_size())?;
  1322. v.write_to_with_cached_sizes(os)?;
  1323. }
  1324. os.write_unknown_fields(self.get_unknown_fields())?;
  1325. ::std::result::Result::Ok(())
  1326. }
  1327. fn get_cached_size(&self) -> u32 {
  1328. self.cached_size.get()
  1329. }
  1330. fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
  1331. &self.unknown_fields
  1332. }
  1333. fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
  1334. &mut self.unknown_fields
  1335. }
  1336. fn as_any(&self) -> &::std::any::Any {
  1337. self as &::std::any::Any
  1338. }
  1339. fn as_any_mut(&mut self) -> &mut ::std::any::Any {
  1340. self as &mut ::std::any::Any
  1341. }
  1342. fn into_any(self: Box<Self>) -> ::std::boxed::Box<::std::any::Any> {
  1343. self
  1344. }
  1345. fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
  1346. Self::descriptor_static()
  1347. }
  1348. fn new() -> RevisionTaggedChangeSet {
  1349. RevisionTaggedChangeSet::new()
  1350. }
  1351. fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
  1352. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
  1353. lock: ::protobuf::lazy::ONCE_INIT,
  1354. ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
  1355. };
  1356. unsafe {
  1357. descriptor.get(|| {
  1358. let mut fields = ::std::vec::Vec::new();
  1359. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  1360. "revision",
  1361. |m: &RevisionTaggedChangeSet| { &m.revision },
  1362. |m: &mut RevisionTaggedChangeSet| { &mut m.revision },
  1363. ));
  1364. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ChangeSet>>(
  1365. "change_set",
  1366. |m: &RevisionTaggedChangeSet| { &m.change_set },
  1367. |m: &mut RevisionTaggedChangeSet| { &mut m.change_set },
  1368. ));
  1369. ::protobuf::reflect::MessageDescriptor::new::<RevisionTaggedChangeSet>(
  1370. "RevisionTaggedChangeSet",
  1371. fields,
  1372. file_descriptor_proto()
  1373. )
  1374. })
  1375. }
  1376. }
  1377. fn default_instance() -> &'static RevisionTaggedChangeSet {
  1378. static mut instance: ::protobuf::lazy::Lazy<RevisionTaggedChangeSet> = ::protobuf::lazy::Lazy {
  1379. lock: ::protobuf::lazy::ONCE_INIT,
  1380. ptr: 0 as *const RevisionTaggedChangeSet,
  1381. };
  1382. unsafe {
  1383. instance.get(RevisionTaggedChangeSet::new)
  1384. }
  1385. }
  1386. }
  1387. impl ::protobuf::Clear for RevisionTaggedChangeSet {
  1388. fn clear(&mut self) {
  1389. self.revision.clear();
  1390. self.change_set.clear();
  1391. self.unknown_fields.clear();
  1392. }
  1393. }
  1394. impl ::std::fmt::Debug for RevisionTaggedChangeSet {
  1395. fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
  1396. ::protobuf::text_format::fmt(self, f)
  1397. }
  1398. }
  1399. impl ::protobuf::reflect::ProtobufValue for RevisionTaggedChangeSet {
  1400. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  1401. ::protobuf::reflect::ProtobufValueRef::Message(self)
  1402. }
  1403. }
  1404. #[derive(PartialEq,Clone,Default)]
  1405. pub struct Diff {
  1406. // message fields
  1407. from_revision: ::protobuf::SingularField<::std::vec::Vec<u8>>,
  1408. ops: ::protobuf::RepeatedField<super::playlist4ops::Op>,
  1409. to_revision: ::protobuf::SingularField<::std::vec::Vec<u8>>,
  1410. // special fields
  1411. pub unknown_fields: ::protobuf::UnknownFields,
  1412. pub cached_size: ::protobuf::CachedSize,
  1413. }
  1414. impl<'a> ::std::default::Default for &'a Diff {
  1415. fn default() -> &'a Diff {
  1416. <Diff as ::protobuf::Message>::default_instance()
  1417. }
  1418. }
  1419. impl Diff {
  1420. pub fn new() -> Diff {
  1421. ::std::default::Default::default()
  1422. }
  1423. // optional bytes from_revision = 1;
  1424. pub fn get_from_revision(&self) -> &[u8] {
  1425. match self.from_revision.as_ref() {
  1426. Some(v) => &v,
  1427. None => &[],
  1428. }
  1429. }
  1430. pub fn clear_from_revision(&mut self) {
  1431. self.from_revision.clear();
  1432. }
  1433. pub fn has_from_revision(&self) -> bool {
  1434. self.from_revision.is_some()
  1435. }
  1436. // Param is passed by value, moved
  1437. pub fn set_from_revision(&mut self, v: ::std::vec::Vec<u8>) {
  1438. self.from_revision = ::protobuf::SingularField::some(v);
  1439. }
  1440. // Mutable pointer to the field.
  1441. // If field is not initialized, it is initialized with default value first.
  1442. pub fn mut_from_revision(&mut self) -> &mut ::std::vec::Vec<u8> {
  1443. if self.from_revision.is_none() {
  1444. self.from_revision.set_default();
  1445. }
  1446. self.from_revision.as_mut().unwrap()
  1447. }
  1448. // Take field
  1449. pub fn take_from_revision(&mut self) -> ::std::vec::Vec<u8> {
  1450. self.from_revision.take().unwrap_or_else(|| ::std::vec::Vec::new())
  1451. }
  1452. // repeated .Op ops = 2;
  1453. pub fn get_ops(&self) -> &[super::playlist4ops::Op] {
  1454. &self.ops
  1455. }
  1456. pub fn clear_ops(&mut self) {
  1457. self.ops.clear();
  1458. }
  1459. // Param is passed by value, moved
  1460. pub fn set_ops(&mut self, v: ::protobuf::RepeatedField<super::playlist4ops::Op>) {
  1461. self.ops = v;
  1462. }
  1463. // Mutable pointer to the field.
  1464. pub fn mut_ops(&mut self) -> &mut ::protobuf::RepeatedField<super::playlist4ops::Op> {
  1465. &mut self.ops
  1466. }
  1467. // Take field
  1468. pub fn take_ops(&mut self) -> ::protobuf::RepeatedField<super::playlist4ops::Op> {
  1469. ::std::mem::replace(&mut self.ops, ::protobuf::RepeatedField::new())
  1470. }
  1471. // optional bytes to_revision = 3;
  1472. pub fn get_to_revision(&self) -> &[u8] {
  1473. match self.to_revision.as_ref() {
  1474. Some(v) => &v,
  1475. None => &[],
  1476. }
  1477. }
  1478. pub fn clear_to_revision(&mut self) {
  1479. self.to_revision.clear();
  1480. }
  1481. pub fn has_to_revision(&self) -> bool {
  1482. self.to_revision.is_some()
  1483. }
  1484. // Param is passed by value, moved
  1485. pub fn set_to_revision(&mut self, v: ::std::vec::Vec<u8>) {
  1486. self.to_revision = ::protobuf::SingularField::some(v);
  1487. }
  1488. // Mutable pointer to the field.
  1489. // If field is not initialized, it is initialized with default value first.
  1490. pub fn mut_to_revision(&mut self) -> &mut ::std::vec::Vec<u8> {
  1491. if self.to_revision.is_none() {
  1492. self.to_revision.set_default();
  1493. }
  1494. self.to_revision.as_mut().unwrap()
  1495. }
  1496. // Take field
  1497. pub fn take_to_revision(&mut self) -> ::std::vec::Vec<u8> {
  1498. self.to_revision.take().unwrap_or_else(|| ::std::vec::Vec::new())
  1499. }
  1500. }
  1501. impl ::protobuf::Message for Diff {
  1502. fn is_initialized(&self) -> bool {
  1503. for v in &self.ops {
  1504. if !v.is_initialized() {
  1505. return false;
  1506. }
  1507. };
  1508. true
  1509. }
  1510. fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream) -> ::protobuf::ProtobufResult<()> {
  1511. while !is.eof()? {
  1512. let (field_number, wire_type) = is.read_tag_unpack()?;
  1513. match field_number {
  1514. 1 => {
  1515. ::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.from_revision)?;
  1516. },
  1517. 2 => {
  1518. ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.ops)?;
  1519. },
  1520. 3 => {
  1521. ::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.to_revision)?;
  1522. },
  1523. _ => {
  1524. ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
  1525. },
  1526. };
  1527. }
  1528. ::std::result::Result::Ok(())
  1529. }
  1530. // Compute sizes of nested messages
  1531. #[allow(unused_variables)]
  1532. fn compute_size(&self) -> u32 {
  1533. let mut my_size = 0;
  1534. if let Some(ref v) = self.from_revision.as_ref() {
  1535. my_size += ::protobuf::rt::bytes_size(1, &v);
  1536. }
  1537. for value in &self.ops {
  1538. let len = value.compute_size();
  1539. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  1540. };
  1541. if let Some(ref v) = self.to_revision.as_ref() {
  1542. my_size += ::protobuf::rt::bytes_size(3, &v);
  1543. }
  1544. my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
  1545. self.cached_size.set(my_size);
  1546. my_size
  1547. }
  1548. fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream) -> ::protobuf::ProtobufResult<()> {
  1549. if let Some(ref v) = self.from_revision.as_ref() {
  1550. os.write_bytes(1, &v)?;
  1551. }
  1552. for v in &self.ops {
  1553. os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  1554. os.write_raw_varint32(v.get_cached_size())?;
  1555. v.write_to_with_cached_sizes(os)?;
  1556. };
  1557. if let Some(ref v) = self.to_revision.as_ref() {
  1558. os.write_bytes(3, &v)?;
  1559. }
  1560. os.write_unknown_fields(self.get_unknown_fields())?;
  1561. ::std::result::Result::Ok(())
  1562. }
  1563. fn get_cached_size(&self) -> u32 {
  1564. self.cached_size.get()
  1565. }
  1566. fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
  1567. &self.unknown_fields
  1568. }
  1569. fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
  1570. &mut self.unknown_fields
  1571. }
  1572. fn as_any(&self) -> &::std::any::Any {
  1573. self as &::std::any::Any
  1574. }
  1575. fn as_any_mut(&mut self) -> &mut ::std::any::Any {
  1576. self as &mut ::std::any::Any
  1577. }
  1578. fn into_any(self: Box<Self>) -> ::std::boxed::Box<::std::any::Any> {
  1579. self
  1580. }
  1581. fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
  1582. Self::descriptor_static()
  1583. }
  1584. fn new() -> Diff {
  1585. Diff::new()
  1586. }
  1587. fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
  1588. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
  1589. lock: ::protobuf::lazy::ONCE_INIT,
  1590. ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
  1591. };
  1592. unsafe {
  1593. descriptor.get(|| {
  1594. let mut fields = ::std::vec::Vec::new();
  1595. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  1596. "from_revision",
  1597. |m: &Diff| { &m.from_revision },
  1598. |m: &mut Diff| { &mut m.from_revision },
  1599. ));
  1600. fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4ops::Op>>(
  1601. "ops",
  1602. |m: &Diff| { &m.ops },
  1603. |m: &mut Diff| { &mut m.ops },
  1604. ));
  1605. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  1606. "to_revision",
  1607. |m: &Diff| { &m.to_revision },
  1608. |m: &mut Diff| { &mut m.to_revision },
  1609. ));
  1610. ::protobuf::reflect::MessageDescriptor::new::<Diff>(
  1611. "Diff",
  1612. fields,
  1613. file_descriptor_proto()
  1614. )
  1615. })
  1616. }
  1617. }
  1618. fn default_instance() -> &'static Diff {
  1619. static mut instance: ::protobuf::lazy::Lazy<Diff> = ::protobuf::lazy::Lazy {
  1620. lock: ::protobuf::lazy::ONCE_INIT,
  1621. ptr: 0 as *const Diff,
  1622. };
  1623. unsafe {
  1624. instance.get(Diff::new)
  1625. }
  1626. }
  1627. }
  1628. impl ::protobuf::Clear for Diff {
  1629. fn clear(&mut self) {
  1630. self.from_revision.clear();
  1631. self.ops.clear();
  1632. self.to_revision.clear();
  1633. self.unknown_fields.clear();
  1634. }
  1635. }
  1636. impl ::std::fmt::Debug for Diff {
  1637. fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
  1638. ::protobuf::text_format::fmt(self, f)
  1639. }
  1640. }
  1641. impl ::protobuf::reflect::ProtobufValue for Diff {
  1642. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  1643. ::protobuf::reflect::ProtobufValueRef::Message(self)
  1644. }
  1645. }
  1646. #[derive(PartialEq,Clone,Default)]
  1647. pub struct ListDump {
  1648. // message fields
  1649. latestRevision: ::protobuf::SingularField<::std::vec::Vec<u8>>,
  1650. length: ::std::option::Option<i32>,
  1651. attributes: ::protobuf::SingularPtrField<super::playlist4meta::ListAttributes>,
  1652. checksum: ::protobuf::SingularPtrField<super::playlist4meta::ListChecksum>,
  1653. contents: ::protobuf::SingularPtrField<super::playlist4content::ListItems>,
  1654. pendingDeltas: ::protobuf::RepeatedField<Delta>,
  1655. // special fields
  1656. pub unknown_fields: ::protobuf::UnknownFields,
  1657. pub cached_size: ::protobuf::CachedSize,
  1658. }
  1659. impl<'a> ::std::default::Default for &'a ListDump {
  1660. fn default() -> &'a ListDump {
  1661. <ListDump as ::protobuf::Message>::default_instance()
  1662. }
  1663. }
  1664. impl ListDump {
  1665. pub fn new() -> ListDump {
  1666. ::std::default::Default::default()
  1667. }
  1668. // optional bytes latestRevision = 1;
  1669. pub fn get_latestRevision(&self) -> &[u8] {
  1670. match self.latestRevision.as_ref() {
  1671. Some(v) => &v,
  1672. None => &[],
  1673. }
  1674. }
  1675. pub fn clear_latestRevision(&mut self) {
  1676. self.latestRevision.clear();
  1677. }
  1678. pub fn has_latestRevision(&self) -> bool {
  1679. self.latestRevision.is_some()
  1680. }
  1681. // Param is passed by value, moved
  1682. pub fn set_latestRevision(&mut self, v: ::std::vec::Vec<u8>) {
  1683. self.latestRevision = ::protobuf::SingularField::some(v);
  1684. }
  1685. // Mutable pointer to the field.
  1686. // If field is not initialized, it is initialized with default value first.
  1687. pub fn mut_latestRevision(&mut self) -> &mut ::std::vec::Vec<u8> {
  1688. if self.latestRevision.is_none() {
  1689. self.latestRevision.set_default();
  1690. }
  1691. self.latestRevision.as_mut().unwrap()
  1692. }
  1693. // Take field
  1694. pub fn take_latestRevision(&mut self) -> ::std::vec::Vec<u8> {
  1695. self.latestRevision.take().unwrap_or_else(|| ::std::vec::Vec::new())
  1696. }
  1697. // optional int32 length = 2;
  1698. pub fn get_length(&self) -> i32 {
  1699. self.length.unwrap_or(0)
  1700. }
  1701. pub fn clear_length(&mut self) {
  1702. self.length = ::std::option::Option::None;
  1703. }
  1704. pub fn has_length(&self) -> bool {
  1705. self.length.is_some()
  1706. }
  1707. // Param is passed by value, moved
  1708. pub fn set_length(&mut self, v: i32) {
  1709. self.length = ::std::option::Option::Some(v);
  1710. }
  1711. // optional .ListAttributes attributes = 3;
  1712. pub fn get_attributes(&self) -> &super::playlist4meta::ListAttributes {
  1713. self.attributes.as_ref().unwrap_or_else(|| super::playlist4meta::ListAttributes::default_instance())
  1714. }
  1715. pub fn clear_attributes(&mut self) {
  1716. self.attributes.clear();
  1717. }
  1718. pub fn has_attributes(&self) -> bool {
  1719. self.attributes.is_some()
  1720. }
  1721. // Param is passed by value, moved
  1722. pub fn set_attributes(&mut self, v: super::playlist4meta::ListAttributes) {
  1723. self.attributes = ::protobuf::SingularPtrField::some(v);
  1724. }
  1725. // Mutable pointer to the field.
  1726. // If field is not initialized, it is initialized with default value first.
  1727. pub fn mut_attributes(&mut self) -> &mut super::playlist4meta::ListAttributes {
  1728. if self.attributes.is_none() {
  1729. self.attributes.set_default();
  1730. }
  1731. self.attributes.as_mut().unwrap()
  1732. }
  1733. // Take field
  1734. pub fn take_attributes(&mut self) -> super::playlist4meta::ListAttributes {
  1735. self.attributes.take().unwrap_or_else(|| super::playlist4meta::ListAttributes::new())
  1736. }
  1737. // optional .ListChecksum checksum = 4;
  1738. pub fn get_checksum(&self) -> &super::playlist4meta::ListChecksum {
  1739. self.checksum.as_ref().unwrap_or_else(|| super::playlist4meta::ListChecksum::default_instance())
  1740. }
  1741. pub fn clear_checksum(&mut self) {
  1742. self.checksum.clear();
  1743. }
  1744. pub fn has_checksum(&self) -> bool {
  1745. self.checksum.is_some()
  1746. }
  1747. // Param is passed by value, moved
  1748. pub fn set_checksum(&mut self, v: super::playlist4meta::ListChecksum) {
  1749. self.checksum = ::protobuf::SingularPtrField::some(v);
  1750. }
  1751. // Mutable pointer to the field.
  1752. // If field is not initialized, it is initialized with default value first.
  1753. pub fn mut_checksum(&mut self) -> &mut super::playlist4meta::ListChecksum {
  1754. if self.checksum.is_none() {
  1755. self.checksum.set_default();
  1756. }
  1757. self.checksum.as_mut().unwrap()
  1758. }
  1759. // Take field
  1760. pub fn take_checksum(&mut self) -> super::playlist4meta::ListChecksum {
  1761. self.checksum.take().unwrap_or_else(|| super::playlist4meta::ListChecksum::new())
  1762. }
  1763. // optional .ListItems contents = 5;
  1764. pub fn get_contents(&self) -> &super::playlist4content::ListItems {
  1765. self.contents.as_ref().unwrap_or_else(|| super::playlist4content::ListItems::default_instance())
  1766. }
  1767. pub fn clear_contents(&mut self) {
  1768. self.contents.clear();
  1769. }
  1770. pub fn has_contents(&self) -> bool {
  1771. self.contents.is_some()
  1772. }
  1773. // Param is passed by value, moved
  1774. pub fn set_contents(&mut self, v: super::playlist4content::ListItems) {
  1775. self.contents = ::protobuf::SingularPtrField::some(v);
  1776. }
  1777. // Mutable pointer to the field.
  1778. // If field is not initialized, it is initialized with default value first.
  1779. pub fn mut_contents(&mut self) -> &mut super::playlist4content::ListItems {
  1780. if self.contents.is_none() {
  1781. self.contents.set_default();
  1782. }
  1783. self.contents.as_mut().unwrap()
  1784. }
  1785. // Take field
  1786. pub fn take_contents(&mut self) -> super::playlist4content::ListItems {
  1787. self.contents.take().unwrap_or_else(|| super::playlist4content::ListItems::new())
  1788. }
  1789. // repeated .Delta pendingDeltas = 7;
  1790. pub fn get_pendingDeltas(&self) -> &[Delta] {
  1791. &self.pendingDeltas
  1792. }
  1793. pub fn clear_pendingDeltas(&mut self) {
  1794. self.pendingDeltas.clear();
  1795. }
  1796. // Param is passed by value, moved
  1797. pub fn set_pendingDeltas(&mut self, v: ::protobuf::RepeatedField<Delta>) {
  1798. self.pendingDeltas = v;
  1799. }
  1800. // Mutable pointer to the field.
  1801. pub fn mut_pendingDeltas(&mut self) -> &mut ::protobuf::RepeatedField<Delta> {
  1802. &mut self.pendingDeltas
  1803. }
  1804. // Take field
  1805. pub fn take_pendingDeltas(&mut self) -> ::protobuf::RepeatedField<Delta> {
  1806. ::std::mem::replace(&mut self.pendingDeltas, ::protobuf::RepeatedField::new())
  1807. }
  1808. }
  1809. impl ::protobuf::Message for ListDump {
  1810. fn is_initialized(&self) -> bool {
  1811. for v in &self.attributes {
  1812. if !v.is_initialized() {
  1813. return false;
  1814. }
  1815. };
  1816. for v in &self.checksum {
  1817. if !v.is_initialized() {
  1818. return false;
  1819. }
  1820. };
  1821. for v in &self.contents {
  1822. if !v.is_initialized() {
  1823. return false;
  1824. }
  1825. };
  1826. for v in &self.pendingDeltas {
  1827. if !v.is_initialized() {
  1828. return false;
  1829. }
  1830. };
  1831. true
  1832. }
  1833. fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream) -> ::protobuf::ProtobufResult<()> {
  1834. while !is.eof()? {
  1835. let (field_number, wire_type) = is.read_tag_unpack()?;
  1836. match field_number {
  1837. 1 => {
  1838. ::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.latestRevision)?;
  1839. },
  1840. 2 => {
  1841. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  1842. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  1843. }
  1844. let tmp = is.read_int32()?;
  1845. self.length = ::std::option::Option::Some(tmp);
  1846. },
  1847. 3 => {
  1848. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.attributes)?;
  1849. },
  1850. 4 => {
  1851. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.checksum)?;
  1852. },
  1853. 5 => {
  1854. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.contents)?;
  1855. },
  1856. 7 => {
  1857. ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.pendingDeltas)?;
  1858. },
  1859. _ => {
  1860. ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
  1861. },
  1862. };
  1863. }
  1864. ::std::result::Result::Ok(())
  1865. }
  1866. // Compute sizes of nested messages
  1867. #[allow(unused_variables)]
  1868. fn compute_size(&self) -> u32 {
  1869. let mut my_size = 0;
  1870. if let Some(ref v) = self.latestRevision.as_ref() {
  1871. my_size += ::protobuf::rt::bytes_size(1, &v);
  1872. }
  1873. if let Some(v) = self.length {
  1874. my_size += ::protobuf::rt::value_size(2, v, ::protobuf::wire_format::WireTypeVarint);
  1875. }
  1876. if let Some(ref v) = self.attributes.as_ref() {
  1877. let len = v.compute_size();
  1878. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  1879. }
  1880. if let Some(ref v) = self.checksum.as_ref() {
  1881. let len = v.compute_size();
  1882. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  1883. }
  1884. if let Some(ref v) = self.contents.as_ref() {
  1885. let len = v.compute_size();
  1886. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  1887. }
  1888. for value in &self.pendingDeltas {
  1889. let len = value.compute_size();
  1890. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  1891. };
  1892. my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
  1893. self.cached_size.set(my_size);
  1894. my_size
  1895. }
  1896. fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream) -> ::protobuf::ProtobufResult<()> {
  1897. if let Some(ref v) = self.latestRevision.as_ref() {
  1898. os.write_bytes(1, &v)?;
  1899. }
  1900. if let Some(v) = self.length {
  1901. os.write_int32(2, v)?;
  1902. }
  1903. if let Some(ref v) = self.attributes.as_ref() {
  1904. os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  1905. os.write_raw_varint32(v.get_cached_size())?;
  1906. v.write_to_with_cached_sizes(os)?;
  1907. }
  1908. if let Some(ref v) = self.checksum.as_ref() {
  1909. os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  1910. os.write_raw_varint32(v.get_cached_size())?;
  1911. v.write_to_with_cached_sizes(os)?;
  1912. }
  1913. if let Some(ref v) = self.contents.as_ref() {
  1914. os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  1915. os.write_raw_varint32(v.get_cached_size())?;
  1916. v.write_to_with_cached_sizes(os)?;
  1917. }
  1918. for v in &self.pendingDeltas {
  1919. os.write_tag(7, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  1920. os.write_raw_varint32(v.get_cached_size())?;
  1921. v.write_to_with_cached_sizes(os)?;
  1922. };
  1923. os.write_unknown_fields(self.get_unknown_fields())?;
  1924. ::std::result::Result::Ok(())
  1925. }
  1926. fn get_cached_size(&self) -> u32 {
  1927. self.cached_size.get()
  1928. }
  1929. fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
  1930. &self.unknown_fields
  1931. }
  1932. fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
  1933. &mut self.unknown_fields
  1934. }
  1935. fn as_any(&self) -> &::std::any::Any {
  1936. self as &::std::any::Any
  1937. }
  1938. fn as_any_mut(&mut self) -> &mut ::std::any::Any {
  1939. self as &mut ::std::any::Any
  1940. }
  1941. fn into_any(self: Box<Self>) -> ::std::boxed::Box<::std::any::Any> {
  1942. self
  1943. }
  1944. fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
  1945. Self::descriptor_static()
  1946. }
  1947. fn new() -> ListDump {
  1948. ListDump::new()
  1949. }
  1950. fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
  1951. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
  1952. lock: ::protobuf::lazy::ONCE_INIT,
  1953. ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
  1954. };
  1955. unsafe {
  1956. descriptor.get(|| {
  1957. let mut fields = ::std::vec::Vec::new();
  1958. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  1959. "latestRevision",
  1960. |m: &ListDump| { &m.latestRevision },
  1961. |m: &mut ListDump| { &mut m.latestRevision },
  1962. ));
  1963. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeInt32>(
  1964. "length",
  1965. |m: &ListDump| { &m.length },
  1966. |m: &mut ListDump| { &mut m.length },
  1967. ));
  1968. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4meta::ListAttributes>>(
  1969. "attributes",
  1970. |m: &ListDump| { &m.attributes },
  1971. |m: &mut ListDump| { &mut m.attributes },
  1972. ));
  1973. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4meta::ListChecksum>>(
  1974. "checksum",
  1975. |m: &ListDump| { &m.checksum },
  1976. |m: &mut ListDump| { &mut m.checksum },
  1977. ));
  1978. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4content::ListItems>>(
  1979. "contents",
  1980. |m: &ListDump| { &m.contents },
  1981. |m: &mut ListDump| { &mut m.contents },
  1982. ));
  1983. fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<Delta>>(
  1984. "pendingDeltas",
  1985. |m: &ListDump| { &m.pendingDeltas },
  1986. |m: &mut ListDump| { &mut m.pendingDeltas },
  1987. ));
  1988. ::protobuf::reflect::MessageDescriptor::new::<ListDump>(
  1989. "ListDump",
  1990. fields,
  1991. file_descriptor_proto()
  1992. )
  1993. })
  1994. }
  1995. }
  1996. fn default_instance() -> &'static ListDump {
  1997. static mut instance: ::protobuf::lazy::Lazy<ListDump> = ::protobuf::lazy::Lazy {
  1998. lock: ::protobuf::lazy::ONCE_INIT,
  1999. ptr: 0 as *const ListDump,
  2000. };
  2001. unsafe {
  2002. instance.get(ListDump::new)
  2003. }
  2004. }
  2005. }
  2006. impl ::protobuf::Clear for ListDump {
  2007. fn clear(&mut self) {
  2008. self.latestRevision.clear();
  2009. self.length = ::std::option::Option::None;
  2010. self.attributes.clear();
  2011. self.checksum.clear();
  2012. self.contents.clear();
  2013. self.pendingDeltas.clear();
  2014. self.unknown_fields.clear();
  2015. }
  2016. }
  2017. impl ::std::fmt::Debug for ListDump {
  2018. fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
  2019. ::protobuf::text_format::fmt(self, f)
  2020. }
  2021. }
  2022. impl ::protobuf::reflect::ProtobufValue for ListDump {
  2023. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  2024. ::protobuf::reflect::ProtobufValueRef::Message(self)
  2025. }
  2026. }
  2027. #[derive(PartialEq,Clone,Default)]
  2028. pub struct ListChanges {
  2029. // message fields
  2030. baseRevision: ::protobuf::SingularField<::std::vec::Vec<u8>>,
  2031. deltas: ::protobuf::RepeatedField<Delta>,
  2032. wantResultingRevisions: ::std::option::Option<bool>,
  2033. wantSyncResult: ::std::option::Option<bool>,
  2034. dump: ::protobuf::SingularPtrField<ListDump>,
  2035. nonces: ::std::vec::Vec<i32>,
  2036. // special fields
  2037. pub unknown_fields: ::protobuf::UnknownFields,
  2038. pub cached_size: ::protobuf::CachedSize,
  2039. }
  2040. impl<'a> ::std::default::Default for &'a ListChanges {
  2041. fn default() -> &'a ListChanges {
  2042. <ListChanges as ::protobuf::Message>::default_instance()
  2043. }
  2044. }
  2045. impl ListChanges {
  2046. pub fn new() -> ListChanges {
  2047. ::std::default::Default::default()
  2048. }
  2049. // optional bytes baseRevision = 1;
  2050. pub fn get_baseRevision(&self) -> &[u8] {
  2051. match self.baseRevision.as_ref() {
  2052. Some(v) => &v,
  2053. None => &[],
  2054. }
  2055. }
  2056. pub fn clear_baseRevision(&mut self) {
  2057. self.baseRevision.clear();
  2058. }
  2059. pub fn has_baseRevision(&self) -> bool {
  2060. self.baseRevision.is_some()
  2061. }
  2062. // Param is passed by value, moved
  2063. pub fn set_baseRevision(&mut self, v: ::std::vec::Vec<u8>) {
  2064. self.baseRevision = ::protobuf::SingularField::some(v);
  2065. }
  2066. // Mutable pointer to the field.
  2067. // If field is not initialized, it is initialized with default value first.
  2068. pub fn mut_baseRevision(&mut self) -> &mut ::std::vec::Vec<u8> {
  2069. if self.baseRevision.is_none() {
  2070. self.baseRevision.set_default();
  2071. }
  2072. self.baseRevision.as_mut().unwrap()
  2073. }
  2074. // Take field
  2075. pub fn take_baseRevision(&mut self) -> ::std::vec::Vec<u8> {
  2076. self.baseRevision.take().unwrap_or_else(|| ::std::vec::Vec::new())
  2077. }
  2078. // repeated .Delta deltas = 2;
  2079. pub fn get_deltas(&self) -> &[Delta] {
  2080. &self.deltas
  2081. }
  2082. pub fn clear_deltas(&mut self) {
  2083. self.deltas.clear();
  2084. }
  2085. // Param is passed by value, moved
  2086. pub fn set_deltas(&mut self, v: ::protobuf::RepeatedField<Delta>) {
  2087. self.deltas = v;
  2088. }
  2089. // Mutable pointer to the field.
  2090. pub fn mut_deltas(&mut self) -> &mut ::protobuf::RepeatedField<Delta> {
  2091. &mut self.deltas
  2092. }
  2093. // Take field
  2094. pub fn take_deltas(&mut self) -> ::protobuf::RepeatedField<Delta> {
  2095. ::std::mem::replace(&mut self.deltas, ::protobuf::RepeatedField::new())
  2096. }
  2097. // optional bool wantResultingRevisions = 3;
  2098. pub fn get_wantResultingRevisions(&self) -> bool {
  2099. self.wantResultingRevisions.unwrap_or(false)
  2100. }
  2101. pub fn clear_wantResultingRevisions(&mut self) {
  2102. self.wantResultingRevisions = ::std::option::Option::None;
  2103. }
  2104. pub fn has_wantResultingRevisions(&self) -> bool {
  2105. self.wantResultingRevisions.is_some()
  2106. }
  2107. // Param is passed by value, moved
  2108. pub fn set_wantResultingRevisions(&mut self, v: bool) {
  2109. self.wantResultingRevisions = ::std::option::Option::Some(v);
  2110. }
  2111. // optional bool wantSyncResult = 4;
  2112. pub fn get_wantSyncResult(&self) -> bool {
  2113. self.wantSyncResult.unwrap_or(false)
  2114. }
  2115. pub fn clear_wantSyncResult(&mut self) {
  2116. self.wantSyncResult = ::std::option::Option::None;
  2117. }
  2118. pub fn has_wantSyncResult(&self) -> bool {
  2119. self.wantSyncResult.is_some()
  2120. }
  2121. // Param is passed by value, moved
  2122. pub fn set_wantSyncResult(&mut self, v: bool) {
  2123. self.wantSyncResult = ::std::option::Option::Some(v);
  2124. }
  2125. // optional .ListDump dump = 5;
  2126. pub fn get_dump(&self) -> &ListDump {
  2127. self.dump.as_ref().unwrap_or_else(|| ListDump::default_instance())
  2128. }
  2129. pub fn clear_dump(&mut self) {
  2130. self.dump.clear();
  2131. }
  2132. pub fn has_dump(&self) -> bool {
  2133. self.dump.is_some()
  2134. }
  2135. // Param is passed by value, moved
  2136. pub fn set_dump(&mut self, v: ListDump) {
  2137. self.dump = ::protobuf::SingularPtrField::some(v);
  2138. }
  2139. // Mutable pointer to the field.
  2140. // If field is not initialized, it is initialized with default value first.
  2141. pub fn mut_dump(&mut self) -> &mut ListDump {
  2142. if self.dump.is_none() {
  2143. self.dump.set_default();
  2144. }
  2145. self.dump.as_mut().unwrap()
  2146. }
  2147. // Take field
  2148. pub fn take_dump(&mut self) -> ListDump {
  2149. self.dump.take().unwrap_or_else(|| ListDump::new())
  2150. }
  2151. // repeated int32 nonces = 6;
  2152. pub fn get_nonces(&self) -> &[i32] {
  2153. &self.nonces
  2154. }
  2155. pub fn clear_nonces(&mut self) {
  2156. self.nonces.clear();
  2157. }
  2158. // Param is passed by value, moved
  2159. pub fn set_nonces(&mut self, v: ::std::vec::Vec<i32>) {
  2160. self.nonces = v;
  2161. }
  2162. // Mutable pointer to the field.
  2163. pub fn mut_nonces(&mut self) -> &mut ::std::vec::Vec<i32> {
  2164. &mut self.nonces
  2165. }
  2166. // Take field
  2167. pub fn take_nonces(&mut self) -> ::std::vec::Vec<i32> {
  2168. ::std::mem::replace(&mut self.nonces, ::std::vec::Vec::new())
  2169. }
  2170. }
  2171. impl ::protobuf::Message for ListChanges {
  2172. fn is_initialized(&self) -> bool {
  2173. for v in &self.deltas {
  2174. if !v.is_initialized() {
  2175. return false;
  2176. }
  2177. };
  2178. for v in &self.dump {
  2179. if !v.is_initialized() {
  2180. return false;
  2181. }
  2182. };
  2183. true
  2184. }
  2185. fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream) -> ::protobuf::ProtobufResult<()> {
  2186. while !is.eof()? {
  2187. let (field_number, wire_type) = is.read_tag_unpack()?;
  2188. match field_number {
  2189. 1 => {
  2190. ::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.baseRevision)?;
  2191. },
  2192. 2 => {
  2193. ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.deltas)?;
  2194. },
  2195. 3 => {
  2196. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  2197. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  2198. }
  2199. let tmp = is.read_bool()?;
  2200. self.wantResultingRevisions = ::std::option::Option::Some(tmp);
  2201. },
  2202. 4 => {
  2203. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  2204. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  2205. }
  2206. let tmp = is.read_bool()?;
  2207. self.wantSyncResult = ::std::option::Option::Some(tmp);
  2208. },
  2209. 5 => {
  2210. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.dump)?;
  2211. },
  2212. 6 => {
  2213. ::protobuf::rt::read_repeated_int32_into(wire_type, is, &mut self.nonces)?;
  2214. },
  2215. _ => {
  2216. ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
  2217. },
  2218. };
  2219. }
  2220. ::std::result::Result::Ok(())
  2221. }
  2222. // Compute sizes of nested messages
  2223. #[allow(unused_variables)]
  2224. fn compute_size(&self) -> u32 {
  2225. let mut my_size = 0;
  2226. if let Some(ref v) = self.baseRevision.as_ref() {
  2227. my_size += ::protobuf::rt::bytes_size(1, &v);
  2228. }
  2229. for value in &self.deltas {
  2230. let len = value.compute_size();
  2231. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  2232. };
  2233. if let Some(v) = self.wantResultingRevisions {
  2234. my_size += 2;
  2235. }
  2236. if let Some(v) = self.wantSyncResult {
  2237. my_size += 2;
  2238. }
  2239. if let Some(ref v) = self.dump.as_ref() {
  2240. let len = v.compute_size();
  2241. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  2242. }
  2243. for value in &self.nonces {
  2244. my_size += ::protobuf::rt::value_size(6, *value, ::protobuf::wire_format::WireTypeVarint);
  2245. };
  2246. my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
  2247. self.cached_size.set(my_size);
  2248. my_size
  2249. }
  2250. fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream) -> ::protobuf::ProtobufResult<()> {
  2251. if let Some(ref v) = self.baseRevision.as_ref() {
  2252. os.write_bytes(1, &v)?;
  2253. }
  2254. for v in &self.deltas {
  2255. os.write_tag(2, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  2256. os.write_raw_varint32(v.get_cached_size())?;
  2257. v.write_to_with_cached_sizes(os)?;
  2258. };
  2259. if let Some(v) = self.wantResultingRevisions {
  2260. os.write_bool(3, v)?;
  2261. }
  2262. if let Some(v) = self.wantSyncResult {
  2263. os.write_bool(4, v)?;
  2264. }
  2265. if let Some(ref v) = self.dump.as_ref() {
  2266. os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  2267. os.write_raw_varint32(v.get_cached_size())?;
  2268. v.write_to_with_cached_sizes(os)?;
  2269. }
  2270. for v in &self.nonces {
  2271. os.write_int32(6, *v)?;
  2272. };
  2273. os.write_unknown_fields(self.get_unknown_fields())?;
  2274. ::std::result::Result::Ok(())
  2275. }
  2276. fn get_cached_size(&self) -> u32 {
  2277. self.cached_size.get()
  2278. }
  2279. fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
  2280. &self.unknown_fields
  2281. }
  2282. fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
  2283. &mut self.unknown_fields
  2284. }
  2285. fn as_any(&self) -> &::std::any::Any {
  2286. self as &::std::any::Any
  2287. }
  2288. fn as_any_mut(&mut self) -> &mut ::std::any::Any {
  2289. self as &mut ::std::any::Any
  2290. }
  2291. fn into_any(self: Box<Self>) -> ::std::boxed::Box<::std::any::Any> {
  2292. self
  2293. }
  2294. fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
  2295. Self::descriptor_static()
  2296. }
  2297. fn new() -> ListChanges {
  2298. ListChanges::new()
  2299. }
  2300. fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
  2301. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
  2302. lock: ::protobuf::lazy::ONCE_INIT,
  2303. ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
  2304. };
  2305. unsafe {
  2306. descriptor.get(|| {
  2307. let mut fields = ::std::vec::Vec::new();
  2308. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  2309. "baseRevision",
  2310. |m: &ListChanges| { &m.baseRevision },
  2311. |m: &mut ListChanges| { &mut m.baseRevision },
  2312. ));
  2313. fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<Delta>>(
  2314. "deltas",
  2315. |m: &ListChanges| { &m.deltas },
  2316. |m: &mut ListChanges| { &mut m.deltas },
  2317. ));
  2318. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  2319. "wantResultingRevisions",
  2320. |m: &ListChanges| { &m.wantResultingRevisions },
  2321. |m: &mut ListChanges| { &mut m.wantResultingRevisions },
  2322. ));
  2323. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  2324. "wantSyncResult",
  2325. |m: &ListChanges| { &m.wantSyncResult },
  2326. |m: &mut ListChanges| { &mut m.wantSyncResult },
  2327. ));
  2328. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<ListDump>>(
  2329. "dump",
  2330. |m: &ListChanges| { &m.dump },
  2331. |m: &mut ListChanges| { &mut m.dump },
  2332. ));
  2333. fields.push(::protobuf::reflect::accessor::make_vec_accessor::<_, ::protobuf::types::ProtobufTypeInt32>(
  2334. "nonces",
  2335. |m: &ListChanges| { &m.nonces },
  2336. |m: &mut ListChanges| { &mut m.nonces },
  2337. ));
  2338. ::protobuf::reflect::MessageDescriptor::new::<ListChanges>(
  2339. "ListChanges",
  2340. fields,
  2341. file_descriptor_proto()
  2342. )
  2343. })
  2344. }
  2345. }
  2346. fn default_instance() -> &'static ListChanges {
  2347. static mut instance: ::protobuf::lazy::Lazy<ListChanges> = ::protobuf::lazy::Lazy {
  2348. lock: ::protobuf::lazy::ONCE_INIT,
  2349. ptr: 0 as *const ListChanges,
  2350. };
  2351. unsafe {
  2352. instance.get(ListChanges::new)
  2353. }
  2354. }
  2355. }
  2356. impl ::protobuf::Clear for ListChanges {
  2357. fn clear(&mut self) {
  2358. self.baseRevision.clear();
  2359. self.deltas.clear();
  2360. self.wantResultingRevisions = ::std::option::Option::None;
  2361. self.wantSyncResult = ::std::option::Option::None;
  2362. self.dump.clear();
  2363. self.nonces.clear();
  2364. self.unknown_fields.clear();
  2365. }
  2366. }
  2367. impl ::std::fmt::Debug for ListChanges {
  2368. fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
  2369. ::protobuf::text_format::fmt(self, f)
  2370. }
  2371. }
  2372. impl ::protobuf::reflect::ProtobufValue for ListChanges {
  2373. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  2374. ::protobuf::reflect::ProtobufValueRef::Message(self)
  2375. }
  2376. }
  2377. #[derive(PartialEq,Clone,Default)]
  2378. pub struct SelectedListContent {
  2379. // message fields
  2380. revision: ::protobuf::SingularField<::std::vec::Vec<u8>>,
  2381. length: ::std::option::Option<i32>,
  2382. attributes: ::protobuf::SingularPtrField<super::playlist4meta::ListAttributes>,
  2383. checksum: ::protobuf::SingularPtrField<super::playlist4meta::ListChecksum>,
  2384. contents: ::protobuf::SingularPtrField<super::playlist4content::ListItems>,
  2385. diff: ::protobuf::SingularPtrField<Diff>,
  2386. syncResult: ::protobuf::SingularPtrField<Diff>,
  2387. resultingRevisions: ::protobuf::RepeatedField<::std::vec::Vec<u8>>,
  2388. multipleHeads: ::std::option::Option<bool>,
  2389. upToDate: ::std::option::Option<bool>,
  2390. resolveAction: ::protobuf::RepeatedField<super::playlist4issues::ClientResolveAction>,
  2391. issues: ::protobuf::RepeatedField<super::playlist4issues::ClientIssue>,
  2392. nonces: ::std::vec::Vec<i32>,
  2393. // special fields
  2394. pub unknown_fields: ::protobuf::UnknownFields,
  2395. pub cached_size: ::protobuf::CachedSize,
  2396. }
  2397. impl<'a> ::std::default::Default for &'a SelectedListContent {
  2398. fn default() -> &'a SelectedListContent {
  2399. <SelectedListContent as ::protobuf::Message>::default_instance()
  2400. }
  2401. }
  2402. impl SelectedListContent {
  2403. pub fn new() -> SelectedListContent {
  2404. ::std::default::Default::default()
  2405. }
  2406. // optional bytes revision = 1;
  2407. pub fn get_revision(&self) -> &[u8] {
  2408. match self.revision.as_ref() {
  2409. Some(v) => &v,
  2410. None => &[],
  2411. }
  2412. }
  2413. pub fn clear_revision(&mut self) {
  2414. self.revision.clear();
  2415. }
  2416. pub fn has_revision(&self) -> bool {
  2417. self.revision.is_some()
  2418. }
  2419. // Param is passed by value, moved
  2420. pub fn set_revision(&mut self, v: ::std::vec::Vec<u8>) {
  2421. self.revision = ::protobuf::SingularField::some(v);
  2422. }
  2423. // Mutable pointer to the field.
  2424. // If field is not initialized, it is initialized with default value first.
  2425. pub fn mut_revision(&mut self) -> &mut ::std::vec::Vec<u8> {
  2426. if self.revision.is_none() {
  2427. self.revision.set_default();
  2428. }
  2429. self.revision.as_mut().unwrap()
  2430. }
  2431. // Take field
  2432. pub fn take_revision(&mut self) -> ::std::vec::Vec<u8> {
  2433. self.revision.take().unwrap_or_else(|| ::std::vec::Vec::new())
  2434. }
  2435. // optional int32 length = 2;
  2436. pub fn get_length(&self) -> i32 {
  2437. self.length.unwrap_or(0)
  2438. }
  2439. pub fn clear_length(&mut self) {
  2440. self.length = ::std::option::Option::None;
  2441. }
  2442. pub fn has_length(&self) -> bool {
  2443. self.length.is_some()
  2444. }
  2445. // Param is passed by value, moved
  2446. pub fn set_length(&mut self, v: i32) {
  2447. self.length = ::std::option::Option::Some(v);
  2448. }
  2449. // optional .ListAttributes attributes = 3;
  2450. pub fn get_attributes(&self) -> &super::playlist4meta::ListAttributes {
  2451. self.attributes.as_ref().unwrap_or_else(|| super::playlist4meta::ListAttributes::default_instance())
  2452. }
  2453. pub fn clear_attributes(&mut self) {
  2454. self.attributes.clear();
  2455. }
  2456. pub fn has_attributes(&self) -> bool {
  2457. self.attributes.is_some()
  2458. }
  2459. // Param is passed by value, moved
  2460. pub fn set_attributes(&mut self, v: super::playlist4meta::ListAttributes) {
  2461. self.attributes = ::protobuf::SingularPtrField::some(v);
  2462. }
  2463. // Mutable pointer to the field.
  2464. // If field is not initialized, it is initialized with default value first.
  2465. pub fn mut_attributes(&mut self) -> &mut super::playlist4meta::ListAttributes {
  2466. if self.attributes.is_none() {
  2467. self.attributes.set_default();
  2468. }
  2469. self.attributes.as_mut().unwrap()
  2470. }
  2471. // Take field
  2472. pub fn take_attributes(&mut self) -> super::playlist4meta::ListAttributes {
  2473. self.attributes.take().unwrap_or_else(|| super::playlist4meta::ListAttributes::new())
  2474. }
  2475. // optional .ListChecksum checksum = 4;
  2476. pub fn get_checksum(&self) -> &super::playlist4meta::ListChecksum {
  2477. self.checksum.as_ref().unwrap_or_else(|| super::playlist4meta::ListChecksum::default_instance())
  2478. }
  2479. pub fn clear_checksum(&mut self) {
  2480. self.checksum.clear();
  2481. }
  2482. pub fn has_checksum(&self) -> bool {
  2483. self.checksum.is_some()
  2484. }
  2485. // Param is passed by value, moved
  2486. pub fn set_checksum(&mut self, v: super::playlist4meta::ListChecksum) {
  2487. self.checksum = ::protobuf::SingularPtrField::some(v);
  2488. }
  2489. // Mutable pointer to the field.
  2490. // If field is not initialized, it is initialized with default value first.
  2491. pub fn mut_checksum(&mut self) -> &mut super::playlist4meta::ListChecksum {
  2492. if self.checksum.is_none() {
  2493. self.checksum.set_default();
  2494. }
  2495. self.checksum.as_mut().unwrap()
  2496. }
  2497. // Take field
  2498. pub fn take_checksum(&mut self) -> super::playlist4meta::ListChecksum {
  2499. self.checksum.take().unwrap_or_else(|| super::playlist4meta::ListChecksum::new())
  2500. }
  2501. // optional .ListItems contents = 5;
  2502. pub fn get_contents(&self) -> &super::playlist4content::ListItems {
  2503. self.contents.as_ref().unwrap_or_else(|| super::playlist4content::ListItems::default_instance())
  2504. }
  2505. pub fn clear_contents(&mut self) {
  2506. self.contents.clear();
  2507. }
  2508. pub fn has_contents(&self) -> bool {
  2509. self.contents.is_some()
  2510. }
  2511. // Param is passed by value, moved
  2512. pub fn set_contents(&mut self, v: super::playlist4content::ListItems) {
  2513. self.contents = ::protobuf::SingularPtrField::some(v);
  2514. }
  2515. // Mutable pointer to the field.
  2516. // If field is not initialized, it is initialized with default value first.
  2517. pub fn mut_contents(&mut self) -> &mut super::playlist4content::ListItems {
  2518. if self.contents.is_none() {
  2519. self.contents.set_default();
  2520. }
  2521. self.contents.as_mut().unwrap()
  2522. }
  2523. // Take field
  2524. pub fn take_contents(&mut self) -> super::playlist4content::ListItems {
  2525. self.contents.take().unwrap_or_else(|| super::playlist4content::ListItems::new())
  2526. }
  2527. // optional .Diff diff = 6;
  2528. pub fn get_diff(&self) -> &Diff {
  2529. self.diff.as_ref().unwrap_or_else(|| Diff::default_instance())
  2530. }
  2531. pub fn clear_diff(&mut self) {
  2532. self.diff.clear();
  2533. }
  2534. pub fn has_diff(&self) -> bool {
  2535. self.diff.is_some()
  2536. }
  2537. // Param is passed by value, moved
  2538. pub fn set_diff(&mut self, v: Diff) {
  2539. self.diff = ::protobuf::SingularPtrField::some(v);
  2540. }
  2541. // Mutable pointer to the field.
  2542. // If field is not initialized, it is initialized with default value first.
  2543. pub fn mut_diff(&mut self) -> &mut Diff {
  2544. if self.diff.is_none() {
  2545. self.diff.set_default();
  2546. }
  2547. self.diff.as_mut().unwrap()
  2548. }
  2549. // Take field
  2550. pub fn take_diff(&mut self) -> Diff {
  2551. self.diff.take().unwrap_or_else(|| Diff::new())
  2552. }
  2553. // optional .Diff syncResult = 7;
  2554. pub fn get_syncResult(&self) -> &Diff {
  2555. self.syncResult.as_ref().unwrap_or_else(|| Diff::default_instance())
  2556. }
  2557. pub fn clear_syncResult(&mut self) {
  2558. self.syncResult.clear();
  2559. }
  2560. pub fn has_syncResult(&self) -> bool {
  2561. self.syncResult.is_some()
  2562. }
  2563. // Param is passed by value, moved
  2564. pub fn set_syncResult(&mut self, v: Diff) {
  2565. self.syncResult = ::protobuf::SingularPtrField::some(v);
  2566. }
  2567. // Mutable pointer to the field.
  2568. // If field is not initialized, it is initialized with default value first.
  2569. pub fn mut_syncResult(&mut self) -> &mut Diff {
  2570. if self.syncResult.is_none() {
  2571. self.syncResult.set_default();
  2572. }
  2573. self.syncResult.as_mut().unwrap()
  2574. }
  2575. // Take field
  2576. pub fn take_syncResult(&mut self) -> Diff {
  2577. self.syncResult.take().unwrap_or_else(|| Diff::new())
  2578. }
  2579. // repeated bytes resultingRevisions = 8;
  2580. pub fn get_resultingRevisions(&self) -> &[::std::vec::Vec<u8>] {
  2581. &self.resultingRevisions
  2582. }
  2583. pub fn clear_resultingRevisions(&mut self) {
  2584. self.resultingRevisions.clear();
  2585. }
  2586. // Param is passed by value, moved
  2587. pub fn set_resultingRevisions(&mut self, v: ::protobuf::RepeatedField<::std::vec::Vec<u8>>) {
  2588. self.resultingRevisions = v;
  2589. }
  2590. // Mutable pointer to the field.
  2591. pub fn mut_resultingRevisions(&mut self) -> &mut ::protobuf::RepeatedField<::std::vec::Vec<u8>> {
  2592. &mut self.resultingRevisions
  2593. }
  2594. // Take field
  2595. pub fn take_resultingRevisions(&mut self) -> ::protobuf::RepeatedField<::std::vec::Vec<u8>> {
  2596. ::std::mem::replace(&mut self.resultingRevisions, ::protobuf::RepeatedField::new())
  2597. }
  2598. // optional bool multipleHeads = 9;
  2599. pub fn get_multipleHeads(&self) -> bool {
  2600. self.multipleHeads.unwrap_or(false)
  2601. }
  2602. pub fn clear_multipleHeads(&mut self) {
  2603. self.multipleHeads = ::std::option::Option::None;
  2604. }
  2605. pub fn has_multipleHeads(&self) -> bool {
  2606. self.multipleHeads.is_some()
  2607. }
  2608. // Param is passed by value, moved
  2609. pub fn set_multipleHeads(&mut self, v: bool) {
  2610. self.multipleHeads = ::std::option::Option::Some(v);
  2611. }
  2612. // optional bool upToDate = 10;
  2613. pub fn get_upToDate(&self) -> bool {
  2614. self.upToDate.unwrap_or(false)
  2615. }
  2616. pub fn clear_upToDate(&mut self) {
  2617. self.upToDate = ::std::option::Option::None;
  2618. }
  2619. pub fn has_upToDate(&self) -> bool {
  2620. self.upToDate.is_some()
  2621. }
  2622. // Param is passed by value, moved
  2623. pub fn set_upToDate(&mut self, v: bool) {
  2624. self.upToDate = ::std::option::Option::Some(v);
  2625. }
  2626. // repeated .ClientResolveAction resolveAction = 12;
  2627. pub fn get_resolveAction(&self) -> &[super::playlist4issues::ClientResolveAction] {
  2628. &self.resolveAction
  2629. }
  2630. pub fn clear_resolveAction(&mut self) {
  2631. self.resolveAction.clear();
  2632. }
  2633. // Param is passed by value, moved
  2634. pub fn set_resolveAction(&mut self, v: ::protobuf::RepeatedField<super::playlist4issues::ClientResolveAction>) {
  2635. self.resolveAction = v;
  2636. }
  2637. // Mutable pointer to the field.
  2638. pub fn mut_resolveAction(&mut self) -> &mut ::protobuf::RepeatedField<super::playlist4issues::ClientResolveAction> {
  2639. &mut self.resolveAction
  2640. }
  2641. // Take field
  2642. pub fn take_resolveAction(&mut self) -> ::protobuf::RepeatedField<super::playlist4issues::ClientResolveAction> {
  2643. ::std::mem::replace(&mut self.resolveAction, ::protobuf::RepeatedField::new())
  2644. }
  2645. // repeated .ClientIssue issues = 13;
  2646. pub fn get_issues(&self) -> &[super::playlist4issues::ClientIssue] {
  2647. &self.issues
  2648. }
  2649. pub fn clear_issues(&mut self) {
  2650. self.issues.clear();
  2651. }
  2652. // Param is passed by value, moved
  2653. pub fn set_issues(&mut self, v: ::protobuf::RepeatedField<super::playlist4issues::ClientIssue>) {
  2654. self.issues = v;
  2655. }
  2656. // Mutable pointer to the field.
  2657. pub fn mut_issues(&mut self) -> &mut ::protobuf::RepeatedField<super::playlist4issues::ClientIssue> {
  2658. &mut self.issues
  2659. }
  2660. // Take field
  2661. pub fn take_issues(&mut self) -> ::protobuf::RepeatedField<super::playlist4issues::ClientIssue> {
  2662. ::std::mem::replace(&mut self.issues, ::protobuf::RepeatedField::new())
  2663. }
  2664. // repeated int32 nonces = 14;
  2665. pub fn get_nonces(&self) -> &[i32] {
  2666. &self.nonces
  2667. }
  2668. pub fn clear_nonces(&mut self) {
  2669. self.nonces.clear();
  2670. }
  2671. // Param is passed by value, moved
  2672. pub fn set_nonces(&mut self, v: ::std::vec::Vec<i32>) {
  2673. self.nonces = v;
  2674. }
  2675. // Mutable pointer to the field.
  2676. pub fn mut_nonces(&mut self) -> &mut ::std::vec::Vec<i32> {
  2677. &mut self.nonces
  2678. }
  2679. // Take field
  2680. pub fn take_nonces(&mut self) -> ::std::vec::Vec<i32> {
  2681. ::std::mem::replace(&mut self.nonces, ::std::vec::Vec::new())
  2682. }
  2683. }
  2684. impl ::protobuf::Message for SelectedListContent {
  2685. fn is_initialized(&self) -> bool {
  2686. for v in &self.attributes {
  2687. if !v.is_initialized() {
  2688. return false;
  2689. }
  2690. };
  2691. for v in &self.checksum {
  2692. if !v.is_initialized() {
  2693. return false;
  2694. }
  2695. };
  2696. for v in &self.contents {
  2697. if !v.is_initialized() {
  2698. return false;
  2699. }
  2700. };
  2701. for v in &self.diff {
  2702. if !v.is_initialized() {
  2703. return false;
  2704. }
  2705. };
  2706. for v in &self.syncResult {
  2707. if !v.is_initialized() {
  2708. return false;
  2709. }
  2710. };
  2711. for v in &self.resolveAction {
  2712. if !v.is_initialized() {
  2713. return false;
  2714. }
  2715. };
  2716. for v in &self.issues {
  2717. if !v.is_initialized() {
  2718. return false;
  2719. }
  2720. };
  2721. true
  2722. }
  2723. fn merge_from(&mut self, is: &mut ::protobuf::CodedInputStream) -> ::protobuf::ProtobufResult<()> {
  2724. while !is.eof()? {
  2725. let (field_number, wire_type) = is.read_tag_unpack()?;
  2726. match field_number {
  2727. 1 => {
  2728. ::protobuf::rt::read_singular_bytes_into(wire_type, is, &mut self.revision)?;
  2729. },
  2730. 2 => {
  2731. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  2732. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  2733. }
  2734. let tmp = is.read_int32()?;
  2735. self.length = ::std::option::Option::Some(tmp);
  2736. },
  2737. 3 => {
  2738. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.attributes)?;
  2739. },
  2740. 4 => {
  2741. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.checksum)?;
  2742. },
  2743. 5 => {
  2744. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.contents)?;
  2745. },
  2746. 6 => {
  2747. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.diff)?;
  2748. },
  2749. 7 => {
  2750. ::protobuf::rt::read_singular_message_into(wire_type, is, &mut self.syncResult)?;
  2751. },
  2752. 8 => {
  2753. ::protobuf::rt::read_repeated_bytes_into(wire_type, is, &mut self.resultingRevisions)?;
  2754. },
  2755. 9 => {
  2756. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  2757. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  2758. }
  2759. let tmp = is.read_bool()?;
  2760. self.multipleHeads = ::std::option::Option::Some(tmp);
  2761. },
  2762. 10 => {
  2763. if wire_type != ::protobuf::wire_format::WireTypeVarint {
  2764. return ::std::result::Result::Err(::protobuf::rt::unexpected_wire_type(wire_type));
  2765. }
  2766. let tmp = is.read_bool()?;
  2767. self.upToDate = ::std::option::Option::Some(tmp);
  2768. },
  2769. 12 => {
  2770. ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.resolveAction)?;
  2771. },
  2772. 13 => {
  2773. ::protobuf::rt::read_repeated_message_into(wire_type, is, &mut self.issues)?;
  2774. },
  2775. 14 => {
  2776. ::protobuf::rt::read_repeated_int32_into(wire_type, is, &mut self.nonces)?;
  2777. },
  2778. _ => {
  2779. ::protobuf::rt::read_unknown_or_skip_group(field_number, wire_type, is, self.mut_unknown_fields())?;
  2780. },
  2781. };
  2782. }
  2783. ::std::result::Result::Ok(())
  2784. }
  2785. // Compute sizes of nested messages
  2786. #[allow(unused_variables)]
  2787. fn compute_size(&self) -> u32 {
  2788. let mut my_size = 0;
  2789. if let Some(ref v) = self.revision.as_ref() {
  2790. my_size += ::protobuf::rt::bytes_size(1, &v);
  2791. }
  2792. if let Some(v) = self.length {
  2793. my_size += ::protobuf::rt::value_size(2, v, ::protobuf::wire_format::WireTypeVarint);
  2794. }
  2795. if let Some(ref v) = self.attributes.as_ref() {
  2796. let len = v.compute_size();
  2797. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  2798. }
  2799. if let Some(ref v) = self.checksum.as_ref() {
  2800. let len = v.compute_size();
  2801. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  2802. }
  2803. if let Some(ref v) = self.contents.as_ref() {
  2804. let len = v.compute_size();
  2805. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  2806. }
  2807. if let Some(ref v) = self.diff.as_ref() {
  2808. let len = v.compute_size();
  2809. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  2810. }
  2811. if let Some(ref v) = self.syncResult.as_ref() {
  2812. let len = v.compute_size();
  2813. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  2814. }
  2815. for value in &self.resultingRevisions {
  2816. my_size += ::protobuf::rt::bytes_size(8, &value);
  2817. };
  2818. if let Some(v) = self.multipleHeads {
  2819. my_size += 2;
  2820. }
  2821. if let Some(v) = self.upToDate {
  2822. my_size += 2;
  2823. }
  2824. for value in &self.resolveAction {
  2825. let len = value.compute_size();
  2826. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  2827. };
  2828. for value in &self.issues {
  2829. let len = value.compute_size();
  2830. my_size += 1 + ::protobuf::rt::compute_raw_varint32_size(len) + len;
  2831. };
  2832. for value in &self.nonces {
  2833. my_size += ::protobuf::rt::value_size(14, *value, ::protobuf::wire_format::WireTypeVarint);
  2834. };
  2835. my_size += ::protobuf::rt::unknown_fields_size(self.get_unknown_fields());
  2836. self.cached_size.set(my_size);
  2837. my_size
  2838. }
  2839. fn write_to_with_cached_sizes(&self, os: &mut ::protobuf::CodedOutputStream) -> ::protobuf::ProtobufResult<()> {
  2840. if let Some(ref v) = self.revision.as_ref() {
  2841. os.write_bytes(1, &v)?;
  2842. }
  2843. if let Some(v) = self.length {
  2844. os.write_int32(2, v)?;
  2845. }
  2846. if let Some(ref v) = self.attributes.as_ref() {
  2847. os.write_tag(3, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  2848. os.write_raw_varint32(v.get_cached_size())?;
  2849. v.write_to_with_cached_sizes(os)?;
  2850. }
  2851. if let Some(ref v) = self.checksum.as_ref() {
  2852. os.write_tag(4, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  2853. os.write_raw_varint32(v.get_cached_size())?;
  2854. v.write_to_with_cached_sizes(os)?;
  2855. }
  2856. if let Some(ref v) = self.contents.as_ref() {
  2857. os.write_tag(5, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  2858. os.write_raw_varint32(v.get_cached_size())?;
  2859. v.write_to_with_cached_sizes(os)?;
  2860. }
  2861. if let Some(ref v) = self.diff.as_ref() {
  2862. os.write_tag(6, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  2863. os.write_raw_varint32(v.get_cached_size())?;
  2864. v.write_to_with_cached_sizes(os)?;
  2865. }
  2866. if let Some(ref v) = self.syncResult.as_ref() {
  2867. os.write_tag(7, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  2868. os.write_raw_varint32(v.get_cached_size())?;
  2869. v.write_to_with_cached_sizes(os)?;
  2870. }
  2871. for v in &self.resultingRevisions {
  2872. os.write_bytes(8, &v)?;
  2873. };
  2874. if let Some(v) = self.multipleHeads {
  2875. os.write_bool(9, v)?;
  2876. }
  2877. if let Some(v) = self.upToDate {
  2878. os.write_bool(10, v)?;
  2879. }
  2880. for v in &self.resolveAction {
  2881. os.write_tag(12, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  2882. os.write_raw_varint32(v.get_cached_size())?;
  2883. v.write_to_with_cached_sizes(os)?;
  2884. };
  2885. for v in &self.issues {
  2886. os.write_tag(13, ::protobuf::wire_format::WireTypeLengthDelimited)?;
  2887. os.write_raw_varint32(v.get_cached_size())?;
  2888. v.write_to_with_cached_sizes(os)?;
  2889. };
  2890. for v in &self.nonces {
  2891. os.write_int32(14, *v)?;
  2892. };
  2893. os.write_unknown_fields(self.get_unknown_fields())?;
  2894. ::std::result::Result::Ok(())
  2895. }
  2896. fn get_cached_size(&self) -> u32 {
  2897. self.cached_size.get()
  2898. }
  2899. fn get_unknown_fields(&self) -> &::protobuf::UnknownFields {
  2900. &self.unknown_fields
  2901. }
  2902. fn mut_unknown_fields(&mut self) -> &mut ::protobuf::UnknownFields {
  2903. &mut self.unknown_fields
  2904. }
  2905. fn as_any(&self) -> &::std::any::Any {
  2906. self as &::std::any::Any
  2907. }
  2908. fn as_any_mut(&mut self) -> &mut ::std::any::Any {
  2909. self as &mut ::std::any::Any
  2910. }
  2911. fn into_any(self: Box<Self>) -> ::std::boxed::Box<::std::any::Any> {
  2912. self
  2913. }
  2914. fn descriptor(&self) -> &'static ::protobuf::reflect::MessageDescriptor {
  2915. Self::descriptor_static()
  2916. }
  2917. fn new() -> SelectedListContent {
  2918. SelectedListContent::new()
  2919. }
  2920. fn descriptor_static() -> &'static ::protobuf::reflect::MessageDescriptor {
  2921. static mut descriptor: ::protobuf::lazy::Lazy<::protobuf::reflect::MessageDescriptor> = ::protobuf::lazy::Lazy {
  2922. lock: ::protobuf::lazy::ONCE_INIT,
  2923. ptr: 0 as *const ::protobuf::reflect::MessageDescriptor,
  2924. };
  2925. unsafe {
  2926. descriptor.get(|| {
  2927. let mut fields = ::std::vec::Vec::new();
  2928. fields.push(::protobuf::reflect::accessor::make_singular_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  2929. "revision",
  2930. |m: &SelectedListContent| { &m.revision },
  2931. |m: &mut SelectedListContent| { &mut m.revision },
  2932. ));
  2933. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeInt32>(
  2934. "length",
  2935. |m: &SelectedListContent| { &m.length },
  2936. |m: &mut SelectedListContent| { &mut m.length },
  2937. ));
  2938. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4meta::ListAttributes>>(
  2939. "attributes",
  2940. |m: &SelectedListContent| { &m.attributes },
  2941. |m: &mut SelectedListContent| { &mut m.attributes },
  2942. ));
  2943. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4meta::ListChecksum>>(
  2944. "checksum",
  2945. |m: &SelectedListContent| { &m.checksum },
  2946. |m: &mut SelectedListContent| { &mut m.checksum },
  2947. ));
  2948. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4content::ListItems>>(
  2949. "contents",
  2950. |m: &SelectedListContent| { &m.contents },
  2951. |m: &mut SelectedListContent| { &mut m.contents },
  2952. ));
  2953. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<Diff>>(
  2954. "diff",
  2955. |m: &SelectedListContent| { &m.diff },
  2956. |m: &mut SelectedListContent| { &mut m.diff },
  2957. ));
  2958. fields.push(::protobuf::reflect::accessor::make_singular_ptr_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<Diff>>(
  2959. "syncResult",
  2960. |m: &SelectedListContent| { &m.syncResult },
  2961. |m: &mut SelectedListContent| { &mut m.syncResult },
  2962. ));
  2963. fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeBytes>(
  2964. "resultingRevisions",
  2965. |m: &SelectedListContent| { &m.resultingRevisions },
  2966. |m: &mut SelectedListContent| { &mut m.resultingRevisions },
  2967. ));
  2968. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  2969. "multipleHeads",
  2970. |m: &SelectedListContent| { &m.multipleHeads },
  2971. |m: &mut SelectedListContent| { &mut m.multipleHeads },
  2972. ));
  2973. fields.push(::protobuf::reflect::accessor::make_option_accessor::<_, ::protobuf::types::ProtobufTypeBool>(
  2974. "upToDate",
  2975. |m: &SelectedListContent| { &m.upToDate },
  2976. |m: &mut SelectedListContent| { &mut m.upToDate },
  2977. ));
  2978. fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4issues::ClientResolveAction>>(
  2979. "resolveAction",
  2980. |m: &SelectedListContent| { &m.resolveAction },
  2981. |m: &mut SelectedListContent| { &mut m.resolveAction },
  2982. ));
  2983. fields.push(::protobuf::reflect::accessor::make_repeated_field_accessor::<_, ::protobuf::types::ProtobufTypeMessage<super::playlist4issues::ClientIssue>>(
  2984. "issues",
  2985. |m: &SelectedListContent| { &m.issues },
  2986. |m: &mut SelectedListContent| { &mut m.issues },
  2987. ));
  2988. fields.push(::protobuf::reflect::accessor::make_vec_accessor::<_, ::protobuf::types::ProtobufTypeInt32>(
  2989. "nonces",
  2990. |m: &SelectedListContent| { &m.nonces },
  2991. |m: &mut SelectedListContent| { &mut m.nonces },
  2992. ));
  2993. ::protobuf::reflect::MessageDescriptor::new::<SelectedListContent>(
  2994. "SelectedListContent",
  2995. fields,
  2996. file_descriptor_proto()
  2997. )
  2998. })
  2999. }
  3000. }
  3001. fn default_instance() -> &'static SelectedListContent {
  3002. static mut instance: ::protobuf::lazy::Lazy<SelectedListContent> = ::protobuf::lazy::Lazy {
  3003. lock: ::protobuf::lazy::ONCE_INIT,
  3004. ptr: 0 as *const SelectedListContent,
  3005. };
  3006. unsafe {
  3007. instance.get(SelectedListContent::new)
  3008. }
  3009. }
  3010. }
  3011. impl ::protobuf::Clear for SelectedListContent {
  3012. fn clear(&mut self) {
  3013. self.revision.clear();
  3014. self.length = ::std::option::Option::None;
  3015. self.attributes.clear();
  3016. self.checksum.clear();
  3017. self.contents.clear();
  3018. self.diff.clear();
  3019. self.syncResult.clear();
  3020. self.resultingRevisions.clear();
  3021. self.multipleHeads = ::std::option::Option::None;
  3022. self.upToDate = ::std::option::Option::None;
  3023. self.resolveAction.clear();
  3024. self.issues.clear();
  3025. self.nonces.clear();
  3026. self.unknown_fields.clear();
  3027. }
  3028. }
  3029. impl ::std::fmt::Debug for SelectedListContent {
  3030. fn fmt(&self, f: &mut ::std::fmt::Formatter) -> ::std::fmt::Result {
  3031. ::protobuf::text_format::fmt(self, f)
  3032. }
  3033. }
  3034. impl ::protobuf::reflect::ProtobufValue for SelectedListContent {
  3035. fn as_ref(&self) -> ::protobuf::reflect::ProtobufValueRef {
  3036. ::protobuf::reflect::ProtobufValueRef::Message(self)
  3037. }
  3038. }
  3039. static file_descriptor_proto_data: &'static [u8] = b"\
  3040. \n\x16playlist4changes.proto\x12\0\"\xa0\x01\n\nChangeInfo\x12\x0e\n\x04\
  3041. user\x18\x01\x20\x01(\tB\0\x12\x13\n\ttimestamp\x18\x02\x20\x01(\x05B\0\
  3042. \x12\x0f\n\x05admin\x18\x03\x20\x01(\x08B\0\x12\x0e\n\x04undo\x18\x04\
  3043. \x20\x01(\x08B\0\x12\x0e\n\x04redo\x18\x05\x20\x01(\x08B\0\x12\x0f\n\x05\
  3044. merge\x18\x06\x20\x01(\x08B\0\x12\x14\n\ncompressed\x18\x07\x20\x01(\x08\
  3045. B\0\x12\x13\n\tmigration\x18\x08\x20\x01(\x08B\0:\0\"R\n\x05Delta\x12\
  3046. \x16\n\x0cbase_version\x18\x01\x20\x01(\x0cB\0\x12\x12\n\x03ops\x18\x02\
  3047. \x20\x03(\x0b2\x03.OpB\0\x12\x1b\n\x04info\x18\x04\x20\x01(\x0b2\x0b.Cha\
  3048. ngeInfoB\0:\0\"W\n\x05Merge\x12\x16\n\x0cbase_version\x18\x01\x20\x01(\
  3049. \x0cB\0\x12\x17\n\rmerge_version\x18\x02\x20\x01(\x0cB\0\x12\x1b\n\x04in\
  3050. fo\x18\x04\x20\x01(\x0b2\x0b.ChangeInfoB\0:\0\"\x92\x01\n\tChangeSet\x12\
  3051. \x1f\n\x04kind\x18\x01\x20\x01(\x0e2\x0f.ChangeSet.KindB\0\x12\x17\n\x05\
  3052. delta\x18\x02\x20\x01(\x0b2\x06.DeltaB\0\x12\x17\n\x05merge\x18\x03\x20\
  3053. \x01(\x0b2\x06.MergeB\0\"0\n\x04Kind\x12\x10\n\x0cKIND_UNKNOWN\x10\0\x12\
  3054. \t\n\x05DELTA\x10\x02\x12\t\n\x05MERGE\x10\x03\x1a\0:\0\"Q\n\x17Revision\
  3055. TaggedChangeSet\x12\x12\n\x08revision\x18\x01\x20\x01(\x0cB\0\x12\x20\n\
  3056. \nchange_set\x18\x02\x20\x01(\x0b2\n.ChangeSetB\0:\0\"L\n\x04Diff\x12\
  3057. \x17\n\rfrom_revision\x18\x01\x20\x01(\x0cB\0\x12\x12\n\x03ops\x18\x02\
  3058. \x20\x03(\x0b2\x03.OpB\0\x12\x15\n\x0bto_revision\x18\x03\x20\x01(\x0cB\
  3059. \0:\0\"\xc3\x01\n\x08ListDump\x12\x18\n\x0elatestRevision\x18\x01\x20\
  3060. \x01(\x0cB\0\x12\x10\n\x06length\x18\x02\x20\x01(\x05B\0\x12%\n\nattribu\
  3061. tes\x18\x03\x20\x01(\x0b2\x0f.ListAttributesB\0\x12!\n\x08checksum\x18\
  3062. \x04\x20\x01(\x0b2\r.ListChecksumB\0\x12\x1e\n\x08contents\x18\x05\x20\
  3063. \x01(\x0b2\n.ListItemsB\0\x12\x1f\n\rpendingDeltas\x18\x07\x20\x03(\x0b2\
  3064. \x06.DeltaB\0:\0\"\xaa\x01\n\x0bListChanges\x12\x16\n\x0cbaseRevision\
  3065. \x18\x01\x20\x01(\x0cB\0\x12\x18\n\x06deltas\x18\x02\x20\x03(\x0b2\x06.D\
  3066. eltaB\0\x12\x20\n\x16wantResultingRevisions\x18\x03\x20\x01(\x08B\0\x12\
  3067. \x18\n\x0ewantSyncResult\x18\x04\x20\x01(\x08B\0\x12\x19\n\x04dump\x18\
  3068. \x05\x20\x01(\x0b2\t.ListDumpB\0\x12\x10\n\x06nonces\x18\x06\x20\x03(\
  3069. \x05B\0:\0\"\x87\x03\n\x13SelectedListContent\x12\x12\n\x08revision\x18\
  3070. \x01\x20\x01(\x0cB\0\x12\x10\n\x06length\x18\x02\x20\x01(\x05B\0\x12%\n\
  3071. \nattributes\x18\x03\x20\x01(\x0b2\x0f.ListAttributesB\0\x12!\n\x08check\
  3072. sum\x18\x04\x20\x01(\x0b2\r.ListChecksumB\0\x12\x1e\n\x08contents\x18\
  3073. \x05\x20\x01(\x0b2\n.ListItemsB\0\x12\x15\n\x04diff\x18\x06\x20\x01(\x0b\
  3074. 2\x05.DiffB\0\x12\x1b\n\nsyncResult\x18\x07\x20\x01(\x0b2\x05.DiffB\0\
  3075. \x12\x1c\n\x12resultingRevisions\x18\x08\x20\x03(\x0cB\0\x12\x17\n\rmult\
  3076. ipleHeads\x18\t\x20\x01(\x08B\0\x12\x12\n\x08upToDate\x18\n\x20\x01(\x08\
  3077. B\0\x12-\n\rresolveAction\x18\x0c\x20\x03(\x0b2\x14.ClientResolveActionB\
  3078. \0\x12\x1e\n\x06issues\x18\r\x20\x03(\x0b2\x0c.ClientIssueB\0\x12\x10\n\
  3079. \x06nonces\x18\x0e\x20\x03(\x05B\0:\0B\0b\x06proto2\
  3080. ";
  3081. static mut file_descriptor_proto_lazy: ::protobuf::lazy::Lazy<::protobuf::descriptor::FileDescriptorProto> = ::protobuf::lazy::Lazy {
  3082. lock: ::protobuf::lazy::ONCE_INIT,
  3083. ptr: 0 as *const ::protobuf::descriptor::FileDescriptorProto,
  3084. };
  3085. fn parse_descriptor_proto() -> ::protobuf::descriptor::FileDescriptorProto {
  3086. ::protobuf::parse_from_bytes(file_descriptor_proto_data).unwrap()
  3087. }
  3088. pub fn file_descriptor_proto() -> &'static ::protobuf::descriptor::FileDescriptorProto {
  3089. unsafe {
  3090. file_descriptor_proto_lazy.get(|| {
  3091. parse_descriptor_proto()
  3092. })
  3093. }
  3094. }