user_resource.pb.go 81 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332
  1. // Code generated by protoc-gen-gogo. DO NOT EDIT.
  2. // source: user_resource.proto
  3. package v2
  4. import proto "github.com/gogo/protobuf/proto"
  5. import fmt "fmt"
  6. import math "math"
  7. import _ "github.com/gogo/protobuf/gogoproto"
  8. import io "io"
  9. // Reference imports to suppress errors if they are not otherwise used.
  10. var _ = proto.Marshal
  11. var _ = fmt.Errorf
  12. var _ = math.Inf
  13. // This is a compile-time assertion to ensure that this generated file
  14. // is compatible with the proto package it is being compiled against.
  15. // A compilation error at this line likely means your copy of the
  16. // proto package needs to be updated.
  17. const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package
  18. // 请求创建资源
  19. type UserResourceAddReq struct {
  20. // 资源类型
  21. ResType int32 `protobuf:"varint,1,opt,name=res_type,json=resType,proto3" json:"res_type,omitempty" form:"res_type" validate:"required"`
  22. // 名称
  23. Title string `protobuf:"bytes,2,opt,name=title,proto3" json:"title,omitempty" form:"title" validate:"required"`
  24. // URL
  25. Url string `protobuf:"bytes,3,opt,name=url,proto3" json:"url,omitempty" form:"url" validate:"required"`
  26. // 权重
  27. Weight int32 `protobuf:"varint,4,opt,name=weight,proto3" json:"weight,omitempty" form:"weight" validate:"required"`
  28. // 创建人
  29. Creator string `protobuf:"bytes,5,opt,name=creator,proto3" json:"creator,omitempty" form:"creator" validate:"required"`
  30. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  31. XXX_unrecognized []byte `json:"-"`
  32. XXX_sizecache int32 `json:"-"`
  33. }
  34. func (m *UserResourceAddReq) Reset() { *m = UserResourceAddReq{} }
  35. func (m *UserResourceAddReq) String() string { return proto.CompactTextString(m) }
  36. func (*UserResourceAddReq) ProtoMessage() {}
  37. func (*UserResourceAddReq) Descriptor() ([]byte, []int) {
  38. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{0}
  39. }
  40. func (m *UserResourceAddReq) XXX_Unmarshal(b []byte) error {
  41. return m.Unmarshal(b)
  42. }
  43. func (m *UserResourceAddReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  44. if deterministic {
  45. return xxx_messageInfo_UserResourceAddReq.Marshal(b, m, deterministic)
  46. } else {
  47. b = b[:cap(b)]
  48. n, err := m.MarshalTo(b)
  49. if err != nil {
  50. return nil, err
  51. }
  52. return b[:n], nil
  53. }
  54. }
  55. func (dst *UserResourceAddReq) XXX_Merge(src proto.Message) {
  56. xxx_messageInfo_UserResourceAddReq.Merge(dst, src)
  57. }
  58. func (m *UserResourceAddReq) XXX_Size() int {
  59. return m.Size()
  60. }
  61. func (m *UserResourceAddReq) XXX_DiscardUnknown() {
  62. xxx_messageInfo_UserResourceAddReq.DiscardUnknown(m)
  63. }
  64. var xxx_messageInfo_UserResourceAddReq proto.InternalMessageInfo
  65. func (m *UserResourceAddReq) GetResType() int32 {
  66. if m != nil {
  67. return m.ResType
  68. }
  69. return 0
  70. }
  71. func (m *UserResourceAddReq) GetTitle() string {
  72. if m != nil {
  73. return m.Title
  74. }
  75. return ""
  76. }
  77. func (m *UserResourceAddReq) GetUrl() string {
  78. if m != nil {
  79. return m.Url
  80. }
  81. return ""
  82. }
  83. func (m *UserResourceAddReq) GetWeight() int32 {
  84. if m != nil {
  85. return m.Weight
  86. }
  87. return 0
  88. }
  89. func (m *UserResourceAddReq) GetCreator() string {
  90. if m != nil {
  91. return m.Creator
  92. }
  93. return ""
  94. }
  95. // 返回创建结果
  96. type UserResourceAddResp struct {
  97. // ID
  98. Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id"`
  99. // 资源ID
  100. CustomId int32 `protobuf:"varint,3,opt,name=custom_id,json=customId,proto3" json:"custom_id"`
  101. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  102. XXX_unrecognized []byte `json:"-"`
  103. XXX_sizecache int32 `json:"-"`
  104. }
  105. func (m *UserResourceAddResp) Reset() { *m = UserResourceAddResp{} }
  106. func (m *UserResourceAddResp) String() string { return proto.CompactTextString(m) }
  107. func (*UserResourceAddResp) ProtoMessage() {}
  108. func (*UserResourceAddResp) Descriptor() ([]byte, []int) {
  109. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{1}
  110. }
  111. func (m *UserResourceAddResp) XXX_Unmarshal(b []byte) error {
  112. return m.Unmarshal(b)
  113. }
  114. func (m *UserResourceAddResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  115. if deterministic {
  116. return xxx_messageInfo_UserResourceAddResp.Marshal(b, m, deterministic)
  117. } else {
  118. b = b[:cap(b)]
  119. n, err := m.MarshalTo(b)
  120. if err != nil {
  121. return nil, err
  122. }
  123. return b[:n], nil
  124. }
  125. }
  126. func (dst *UserResourceAddResp) XXX_Merge(src proto.Message) {
  127. xxx_messageInfo_UserResourceAddResp.Merge(dst, src)
  128. }
  129. func (m *UserResourceAddResp) XXX_Size() int {
  130. return m.Size()
  131. }
  132. func (m *UserResourceAddResp) XXX_DiscardUnknown() {
  133. xxx_messageInfo_UserResourceAddResp.DiscardUnknown(m)
  134. }
  135. var xxx_messageInfo_UserResourceAddResp proto.InternalMessageInfo
  136. func (m *UserResourceAddResp) GetId() int32 {
  137. if m != nil {
  138. return m.Id
  139. }
  140. return 0
  141. }
  142. func (m *UserResourceAddResp) GetCustomId() int32 {
  143. if m != nil {
  144. return m.CustomId
  145. }
  146. return 0
  147. }
  148. // 请求编辑资源
  149. type UserResourceEditReq struct {
  150. // 资源类型
  151. ResType int32 `protobuf:"varint,1,opt,name=res_type,json=resType,proto3" json:"res_type,omitempty" form:"res_type" validate:"required"`
  152. // 资源ID
  153. CustomId int32 `protobuf:"varint,2,opt,name=custom_id,json=customId,proto3" json:"custom_id,omitempty" form:"custom_id" validate:"required"`
  154. // 名称
  155. Title string `protobuf:"bytes,3,opt,name=title,proto3" json:"title,omitempty" form:"title"`
  156. // URL
  157. Url string `protobuf:"bytes,4,opt,name=url,proto3" json:"url,omitempty" form:"url"`
  158. // 权重
  159. Weight int32 `protobuf:"varint,5,opt,name=weight,proto3" json:"weight,omitempty" form:"weight"`
  160. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  161. XXX_unrecognized []byte `json:"-"`
  162. XXX_sizecache int32 `json:"-"`
  163. }
  164. func (m *UserResourceEditReq) Reset() { *m = UserResourceEditReq{} }
  165. func (m *UserResourceEditReq) String() string { return proto.CompactTextString(m) }
  166. func (*UserResourceEditReq) ProtoMessage() {}
  167. func (*UserResourceEditReq) Descriptor() ([]byte, []int) {
  168. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{2}
  169. }
  170. func (m *UserResourceEditReq) XXX_Unmarshal(b []byte) error {
  171. return m.Unmarshal(b)
  172. }
  173. func (m *UserResourceEditReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  174. if deterministic {
  175. return xxx_messageInfo_UserResourceEditReq.Marshal(b, m, deterministic)
  176. } else {
  177. b = b[:cap(b)]
  178. n, err := m.MarshalTo(b)
  179. if err != nil {
  180. return nil, err
  181. }
  182. return b[:n], nil
  183. }
  184. }
  185. func (dst *UserResourceEditReq) XXX_Merge(src proto.Message) {
  186. xxx_messageInfo_UserResourceEditReq.Merge(dst, src)
  187. }
  188. func (m *UserResourceEditReq) XXX_Size() int {
  189. return m.Size()
  190. }
  191. func (m *UserResourceEditReq) XXX_DiscardUnknown() {
  192. xxx_messageInfo_UserResourceEditReq.DiscardUnknown(m)
  193. }
  194. var xxx_messageInfo_UserResourceEditReq proto.InternalMessageInfo
  195. func (m *UserResourceEditReq) GetResType() int32 {
  196. if m != nil {
  197. return m.ResType
  198. }
  199. return 0
  200. }
  201. func (m *UserResourceEditReq) GetCustomId() int32 {
  202. if m != nil {
  203. return m.CustomId
  204. }
  205. return 0
  206. }
  207. func (m *UserResourceEditReq) GetTitle() string {
  208. if m != nil {
  209. return m.Title
  210. }
  211. return ""
  212. }
  213. func (m *UserResourceEditReq) GetUrl() string {
  214. if m != nil {
  215. return m.Url
  216. }
  217. return ""
  218. }
  219. func (m *UserResourceEditReq) GetWeight() int32 {
  220. if m != nil {
  221. return m.Weight
  222. }
  223. return 0
  224. }
  225. // 返回编辑结果
  226. type UserResourceEditResp struct {
  227. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  228. XXX_unrecognized []byte `json:"-"`
  229. XXX_sizecache int32 `json:"-"`
  230. }
  231. func (m *UserResourceEditResp) Reset() { *m = UserResourceEditResp{} }
  232. func (m *UserResourceEditResp) String() string { return proto.CompactTextString(m) }
  233. func (*UserResourceEditResp) ProtoMessage() {}
  234. func (*UserResourceEditResp) Descriptor() ([]byte, []int) {
  235. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{3}
  236. }
  237. func (m *UserResourceEditResp) XXX_Unmarshal(b []byte) error {
  238. return m.Unmarshal(b)
  239. }
  240. func (m *UserResourceEditResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  241. if deterministic {
  242. return xxx_messageInfo_UserResourceEditResp.Marshal(b, m, deterministic)
  243. } else {
  244. b = b[:cap(b)]
  245. n, err := m.MarshalTo(b)
  246. if err != nil {
  247. return nil, err
  248. }
  249. return b[:n], nil
  250. }
  251. }
  252. func (dst *UserResourceEditResp) XXX_Merge(src proto.Message) {
  253. xxx_messageInfo_UserResourceEditResp.Merge(dst, src)
  254. }
  255. func (m *UserResourceEditResp) XXX_Size() int {
  256. return m.Size()
  257. }
  258. func (m *UserResourceEditResp) XXX_DiscardUnknown() {
  259. xxx_messageInfo_UserResourceEditResp.DiscardUnknown(m)
  260. }
  261. var xxx_messageInfo_UserResourceEditResp proto.InternalMessageInfo
  262. // 请求资源列表
  263. type UserResourceListReq struct {
  264. // 资源类型
  265. ResType int32 `protobuf:"varint,1,opt,name=res_type,json=resType,proto3" json:"res_type,omitempty" form:"res_type" validate:"required"`
  266. // 页码
  267. Page int32 `protobuf:"varint,2,opt,name=page,proto3" json:"page,omitempty" form:"page"`
  268. // 每页数据量
  269. PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty" form:"page_size"`
  270. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  271. XXX_unrecognized []byte `json:"-"`
  272. XXX_sizecache int32 `json:"-"`
  273. }
  274. func (m *UserResourceListReq) Reset() { *m = UserResourceListReq{} }
  275. func (m *UserResourceListReq) String() string { return proto.CompactTextString(m) }
  276. func (*UserResourceListReq) ProtoMessage() {}
  277. func (*UserResourceListReq) Descriptor() ([]byte, []int) {
  278. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{4}
  279. }
  280. func (m *UserResourceListReq) XXX_Unmarshal(b []byte) error {
  281. return m.Unmarshal(b)
  282. }
  283. func (m *UserResourceListReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  284. if deterministic {
  285. return xxx_messageInfo_UserResourceListReq.Marshal(b, m, deterministic)
  286. } else {
  287. b = b[:cap(b)]
  288. n, err := m.MarshalTo(b)
  289. if err != nil {
  290. return nil, err
  291. }
  292. return b[:n], nil
  293. }
  294. }
  295. func (dst *UserResourceListReq) XXX_Merge(src proto.Message) {
  296. xxx_messageInfo_UserResourceListReq.Merge(dst, src)
  297. }
  298. func (m *UserResourceListReq) XXX_Size() int {
  299. return m.Size()
  300. }
  301. func (m *UserResourceListReq) XXX_DiscardUnknown() {
  302. xxx_messageInfo_UserResourceListReq.DiscardUnknown(m)
  303. }
  304. var xxx_messageInfo_UserResourceListReq proto.InternalMessageInfo
  305. func (m *UserResourceListReq) GetResType() int32 {
  306. if m != nil {
  307. return m.ResType
  308. }
  309. return 0
  310. }
  311. func (m *UserResourceListReq) GetPage() int32 {
  312. if m != nil {
  313. return m.Page
  314. }
  315. return 0
  316. }
  317. func (m *UserResourceListReq) GetPageSize() int32 {
  318. if m != nil {
  319. return m.PageSize
  320. }
  321. return 0
  322. }
  323. // 返回资源列表
  324. type UserResourceListResp struct {
  325. CurrentPage int32 `protobuf:"varint,1,opt,name=currentPage,proto3" json:"currentPage"`
  326. TotalCount int32 `protobuf:"varint,2,opt,name=totalCount,proto3" json:"totalCount"`
  327. List []*UserResourceListResp_List `protobuf:"bytes,3,rep,name=list" json:"list"`
  328. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  329. XXX_unrecognized []byte `json:"-"`
  330. XXX_sizecache int32 `json:"-"`
  331. }
  332. func (m *UserResourceListResp) Reset() { *m = UserResourceListResp{} }
  333. func (m *UserResourceListResp) String() string { return proto.CompactTextString(m) }
  334. func (*UserResourceListResp) ProtoMessage() {}
  335. func (*UserResourceListResp) Descriptor() ([]byte, []int) {
  336. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{5}
  337. }
  338. func (m *UserResourceListResp) XXX_Unmarshal(b []byte) error {
  339. return m.Unmarshal(b)
  340. }
  341. func (m *UserResourceListResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  342. if deterministic {
  343. return xxx_messageInfo_UserResourceListResp.Marshal(b, m, deterministic)
  344. } else {
  345. b = b[:cap(b)]
  346. n, err := m.MarshalTo(b)
  347. if err != nil {
  348. return nil, err
  349. }
  350. return b[:n], nil
  351. }
  352. }
  353. func (dst *UserResourceListResp) XXX_Merge(src proto.Message) {
  354. xxx_messageInfo_UserResourceListResp.Merge(dst, src)
  355. }
  356. func (m *UserResourceListResp) XXX_Size() int {
  357. return m.Size()
  358. }
  359. func (m *UserResourceListResp) XXX_DiscardUnknown() {
  360. xxx_messageInfo_UserResourceListResp.DiscardUnknown(m)
  361. }
  362. var xxx_messageInfo_UserResourceListResp proto.InternalMessageInfo
  363. func (m *UserResourceListResp) GetCurrentPage() int32 {
  364. if m != nil {
  365. return m.CurrentPage
  366. }
  367. return 0
  368. }
  369. func (m *UserResourceListResp) GetTotalCount() int32 {
  370. if m != nil {
  371. return m.TotalCount
  372. }
  373. return 0
  374. }
  375. func (m *UserResourceListResp) GetList() []*UserResourceListResp_List {
  376. if m != nil {
  377. return m.List
  378. }
  379. return nil
  380. }
  381. type UserResourceListResp_List struct {
  382. // ID
  383. Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id"`
  384. // 资源类型
  385. ResType int32 `protobuf:"varint,2,opt,name=res_type,json=resType,proto3" json:"res_type"`
  386. // 资源ID
  387. CustomId int32 `protobuf:"varint,3,opt,name=custom_id,json=customId,proto3" json:"custom_id"`
  388. // 名称
  389. Title string `protobuf:"bytes,4,opt,name=title,proto3" json:"title"`
  390. // URL
  391. Url string `protobuf:"bytes,5,opt,name=url,proto3" json:"url"`
  392. // 权重
  393. Weight int32 `protobuf:"varint,6,opt,name=weight,proto3" json:"weight"`
  394. // 创建人
  395. Creator string `protobuf:"bytes,7,opt,name=creator,proto3" json:"creator"`
  396. // "状态1.上线中2.下线"
  397. Status int32 `protobuf:"varint,8,opt,name=status,proto3" json:"status"`
  398. // 创建时刻
  399. Ctime string `protobuf:"bytes,9,opt,name=ctime,proto3" json:"ctime"`
  400. // 修改时刻
  401. Mtime string `protobuf:"bytes,10,opt,name=mtime,proto3" json:"mtime"`
  402. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  403. XXX_unrecognized []byte `json:"-"`
  404. XXX_sizecache int32 `json:"-"`
  405. }
  406. func (m *UserResourceListResp_List) Reset() { *m = UserResourceListResp_List{} }
  407. func (m *UserResourceListResp_List) String() string { return proto.CompactTextString(m) }
  408. func (*UserResourceListResp_List) ProtoMessage() {}
  409. func (*UserResourceListResp_List) Descriptor() ([]byte, []int) {
  410. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{5, 0}
  411. }
  412. func (m *UserResourceListResp_List) XXX_Unmarshal(b []byte) error {
  413. return m.Unmarshal(b)
  414. }
  415. func (m *UserResourceListResp_List) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  416. if deterministic {
  417. return xxx_messageInfo_UserResourceListResp_List.Marshal(b, m, deterministic)
  418. } else {
  419. b = b[:cap(b)]
  420. n, err := m.MarshalTo(b)
  421. if err != nil {
  422. return nil, err
  423. }
  424. return b[:n], nil
  425. }
  426. }
  427. func (dst *UserResourceListResp_List) XXX_Merge(src proto.Message) {
  428. xxx_messageInfo_UserResourceListResp_List.Merge(dst, src)
  429. }
  430. func (m *UserResourceListResp_List) XXX_Size() int {
  431. return m.Size()
  432. }
  433. func (m *UserResourceListResp_List) XXX_DiscardUnknown() {
  434. xxx_messageInfo_UserResourceListResp_List.DiscardUnknown(m)
  435. }
  436. var xxx_messageInfo_UserResourceListResp_List proto.InternalMessageInfo
  437. func (m *UserResourceListResp_List) GetId() int32 {
  438. if m != nil {
  439. return m.Id
  440. }
  441. return 0
  442. }
  443. func (m *UserResourceListResp_List) GetResType() int32 {
  444. if m != nil {
  445. return m.ResType
  446. }
  447. return 0
  448. }
  449. func (m *UserResourceListResp_List) GetCustomId() int32 {
  450. if m != nil {
  451. return m.CustomId
  452. }
  453. return 0
  454. }
  455. func (m *UserResourceListResp_List) GetTitle() string {
  456. if m != nil {
  457. return m.Title
  458. }
  459. return ""
  460. }
  461. func (m *UserResourceListResp_List) GetUrl() string {
  462. if m != nil {
  463. return m.Url
  464. }
  465. return ""
  466. }
  467. func (m *UserResourceListResp_List) GetWeight() int32 {
  468. if m != nil {
  469. return m.Weight
  470. }
  471. return 0
  472. }
  473. func (m *UserResourceListResp_List) GetCreator() string {
  474. if m != nil {
  475. return m.Creator
  476. }
  477. return ""
  478. }
  479. func (m *UserResourceListResp_List) GetStatus() int32 {
  480. if m != nil {
  481. return m.Status
  482. }
  483. return 0
  484. }
  485. func (m *UserResourceListResp_List) GetCtime() string {
  486. if m != nil {
  487. return m.Ctime
  488. }
  489. return ""
  490. }
  491. func (m *UserResourceListResp_List) GetMtime() string {
  492. if m != nil {
  493. return m.Mtime
  494. }
  495. return ""
  496. }
  497. // 请求变更资源状态
  498. type UserResourceSetStatusReq struct {
  499. // 资源类型
  500. ResType int32 `protobuf:"varint,1,opt,name=res_type,json=resType,proto3" json:"res_type,omitempty" form:"res_type" validate:"required"`
  501. // 页码
  502. CustomId int32 `protobuf:"varint,2,opt,name=custom_id,json=customId,proto3" json:"custom_id,omitempty" form:"custom_id" validate:"required"`
  503. // 每页数据量
  504. Status int32 `protobuf:"varint,3,opt,name=status,proto3" json:"status,omitempty" form:"status" validate:"required"`
  505. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  506. XXX_unrecognized []byte `json:"-"`
  507. XXX_sizecache int32 `json:"-"`
  508. }
  509. func (m *UserResourceSetStatusReq) Reset() { *m = UserResourceSetStatusReq{} }
  510. func (m *UserResourceSetStatusReq) String() string { return proto.CompactTextString(m) }
  511. func (*UserResourceSetStatusReq) ProtoMessage() {}
  512. func (*UserResourceSetStatusReq) Descriptor() ([]byte, []int) {
  513. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{6}
  514. }
  515. func (m *UserResourceSetStatusReq) XXX_Unmarshal(b []byte) error {
  516. return m.Unmarshal(b)
  517. }
  518. func (m *UserResourceSetStatusReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  519. if deterministic {
  520. return xxx_messageInfo_UserResourceSetStatusReq.Marshal(b, m, deterministic)
  521. } else {
  522. b = b[:cap(b)]
  523. n, err := m.MarshalTo(b)
  524. if err != nil {
  525. return nil, err
  526. }
  527. return b[:n], nil
  528. }
  529. }
  530. func (dst *UserResourceSetStatusReq) XXX_Merge(src proto.Message) {
  531. xxx_messageInfo_UserResourceSetStatusReq.Merge(dst, src)
  532. }
  533. func (m *UserResourceSetStatusReq) XXX_Size() int {
  534. return m.Size()
  535. }
  536. func (m *UserResourceSetStatusReq) XXX_DiscardUnknown() {
  537. xxx_messageInfo_UserResourceSetStatusReq.DiscardUnknown(m)
  538. }
  539. var xxx_messageInfo_UserResourceSetStatusReq proto.InternalMessageInfo
  540. func (m *UserResourceSetStatusReq) GetResType() int32 {
  541. if m != nil {
  542. return m.ResType
  543. }
  544. return 0
  545. }
  546. func (m *UserResourceSetStatusReq) GetCustomId() int32 {
  547. if m != nil {
  548. return m.CustomId
  549. }
  550. return 0
  551. }
  552. func (m *UserResourceSetStatusReq) GetStatus() int32 {
  553. if m != nil {
  554. return m.Status
  555. }
  556. return 0
  557. }
  558. // 返回变更结果
  559. type UserResourceSetStatusResp struct {
  560. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  561. XXX_unrecognized []byte `json:"-"`
  562. XXX_sizecache int32 `json:"-"`
  563. }
  564. func (m *UserResourceSetStatusResp) Reset() { *m = UserResourceSetStatusResp{} }
  565. func (m *UserResourceSetStatusResp) String() string { return proto.CompactTextString(m) }
  566. func (*UserResourceSetStatusResp) ProtoMessage() {}
  567. func (*UserResourceSetStatusResp) Descriptor() ([]byte, []int) {
  568. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{7}
  569. }
  570. func (m *UserResourceSetStatusResp) XXX_Unmarshal(b []byte) error {
  571. return m.Unmarshal(b)
  572. }
  573. func (m *UserResourceSetStatusResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  574. if deterministic {
  575. return xxx_messageInfo_UserResourceSetStatusResp.Marshal(b, m, deterministic)
  576. } else {
  577. b = b[:cap(b)]
  578. n, err := m.MarshalTo(b)
  579. if err != nil {
  580. return nil, err
  581. }
  582. return b[:n], nil
  583. }
  584. }
  585. func (dst *UserResourceSetStatusResp) XXX_Merge(src proto.Message) {
  586. xxx_messageInfo_UserResourceSetStatusResp.Merge(dst, src)
  587. }
  588. func (m *UserResourceSetStatusResp) XXX_Size() int {
  589. return m.Size()
  590. }
  591. func (m *UserResourceSetStatusResp) XXX_DiscardUnknown() {
  592. xxx_messageInfo_UserResourceSetStatusResp.DiscardUnknown(m)
  593. }
  594. var xxx_messageInfo_UserResourceSetStatusResp proto.InternalMessageInfo
  595. // 请求单个资源
  596. type UserResourceGetSingleReq struct {
  597. // 资源类型
  598. ResType int32 `protobuf:"varint,1,opt,name=res_type,json=resType,proto3" json:"res_type,omitempty" form:"res_type" validate:"required"`
  599. // 资源ID
  600. CustomId int32 `protobuf:"varint,2,opt,name=custom_id,json=customId,proto3" json:"custom_id,omitempty" form:"custom_id" validate:"required"`
  601. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  602. XXX_unrecognized []byte `json:"-"`
  603. XXX_sizecache int32 `json:"-"`
  604. }
  605. func (m *UserResourceGetSingleReq) Reset() { *m = UserResourceGetSingleReq{} }
  606. func (m *UserResourceGetSingleReq) String() string { return proto.CompactTextString(m) }
  607. func (*UserResourceGetSingleReq) ProtoMessage() {}
  608. func (*UserResourceGetSingleReq) Descriptor() ([]byte, []int) {
  609. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{8}
  610. }
  611. func (m *UserResourceGetSingleReq) XXX_Unmarshal(b []byte) error {
  612. return m.Unmarshal(b)
  613. }
  614. func (m *UserResourceGetSingleReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  615. if deterministic {
  616. return xxx_messageInfo_UserResourceGetSingleReq.Marshal(b, m, deterministic)
  617. } else {
  618. b = b[:cap(b)]
  619. n, err := m.MarshalTo(b)
  620. if err != nil {
  621. return nil, err
  622. }
  623. return b[:n], nil
  624. }
  625. }
  626. func (dst *UserResourceGetSingleReq) XXX_Merge(src proto.Message) {
  627. xxx_messageInfo_UserResourceGetSingleReq.Merge(dst, src)
  628. }
  629. func (m *UserResourceGetSingleReq) XXX_Size() int {
  630. return m.Size()
  631. }
  632. func (m *UserResourceGetSingleReq) XXX_DiscardUnknown() {
  633. xxx_messageInfo_UserResourceGetSingleReq.DiscardUnknown(m)
  634. }
  635. var xxx_messageInfo_UserResourceGetSingleReq proto.InternalMessageInfo
  636. func (m *UserResourceGetSingleReq) GetResType() int32 {
  637. if m != nil {
  638. return m.ResType
  639. }
  640. return 0
  641. }
  642. func (m *UserResourceGetSingleReq) GetCustomId() int32 {
  643. if m != nil {
  644. return m.CustomId
  645. }
  646. return 0
  647. }
  648. // 返回单个资源
  649. type UserResourceGetSingleResp struct {
  650. // ID
  651. Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id"`
  652. // 资源类型
  653. ResType int32 `protobuf:"varint,2,opt,name=res_type,json=resType,proto3" json:"res_type"`
  654. // 资源ID
  655. CustomId int32 `protobuf:"varint,3,opt,name=custom_id,json=customId,proto3" json:"custom_id"`
  656. // 名称
  657. Title string `protobuf:"bytes,4,opt,name=title,proto3" json:"title"`
  658. // URL
  659. Url string `protobuf:"bytes,5,opt,name=url,proto3" json:"url"`
  660. // 权重
  661. Weight int32 `protobuf:"varint,6,opt,name=weight,proto3" json:"weight"`
  662. // 创建人
  663. Creator string `protobuf:"bytes,7,opt,name=creator,proto3" json:"creator"`
  664. // "状态1.上线中2.下线"
  665. Status int32 `protobuf:"varint,8,opt,name=status,proto3" json:"status"`
  666. // 创建时刻
  667. Ctime string `protobuf:"bytes,9,opt,name=ctime,proto3" json:"ctime"`
  668. // 修改时刻
  669. Mtime string `protobuf:"bytes,10,opt,name=mtime,proto3" json:"mtime"`
  670. XXX_NoUnkeyedLiteral struct{} `json:"-"`
  671. XXX_unrecognized []byte `json:"-"`
  672. XXX_sizecache int32 `json:"-"`
  673. }
  674. func (m *UserResourceGetSingleResp) Reset() { *m = UserResourceGetSingleResp{} }
  675. func (m *UserResourceGetSingleResp) String() string { return proto.CompactTextString(m) }
  676. func (*UserResourceGetSingleResp) ProtoMessage() {}
  677. func (*UserResourceGetSingleResp) Descriptor() ([]byte, []int) {
  678. return fileDescriptor_user_resource_4bd0130d4f3d3c5a, []int{9}
  679. }
  680. func (m *UserResourceGetSingleResp) XXX_Unmarshal(b []byte) error {
  681. return m.Unmarshal(b)
  682. }
  683. func (m *UserResourceGetSingleResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  684. if deterministic {
  685. return xxx_messageInfo_UserResourceGetSingleResp.Marshal(b, m, deterministic)
  686. } else {
  687. b = b[:cap(b)]
  688. n, err := m.MarshalTo(b)
  689. if err != nil {
  690. return nil, err
  691. }
  692. return b[:n], nil
  693. }
  694. }
  695. func (dst *UserResourceGetSingleResp) XXX_Merge(src proto.Message) {
  696. xxx_messageInfo_UserResourceGetSingleResp.Merge(dst, src)
  697. }
  698. func (m *UserResourceGetSingleResp) XXX_Size() int {
  699. return m.Size()
  700. }
  701. func (m *UserResourceGetSingleResp) XXX_DiscardUnknown() {
  702. xxx_messageInfo_UserResourceGetSingleResp.DiscardUnknown(m)
  703. }
  704. var xxx_messageInfo_UserResourceGetSingleResp proto.InternalMessageInfo
  705. func (m *UserResourceGetSingleResp) GetId() int32 {
  706. if m != nil {
  707. return m.Id
  708. }
  709. return 0
  710. }
  711. func (m *UserResourceGetSingleResp) GetResType() int32 {
  712. if m != nil {
  713. return m.ResType
  714. }
  715. return 0
  716. }
  717. func (m *UserResourceGetSingleResp) GetCustomId() int32 {
  718. if m != nil {
  719. return m.CustomId
  720. }
  721. return 0
  722. }
  723. func (m *UserResourceGetSingleResp) GetTitle() string {
  724. if m != nil {
  725. return m.Title
  726. }
  727. return ""
  728. }
  729. func (m *UserResourceGetSingleResp) GetUrl() string {
  730. if m != nil {
  731. return m.Url
  732. }
  733. return ""
  734. }
  735. func (m *UserResourceGetSingleResp) GetWeight() int32 {
  736. if m != nil {
  737. return m.Weight
  738. }
  739. return 0
  740. }
  741. func (m *UserResourceGetSingleResp) GetCreator() string {
  742. if m != nil {
  743. return m.Creator
  744. }
  745. return ""
  746. }
  747. func (m *UserResourceGetSingleResp) GetStatus() int32 {
  748. if m != nil {
  749. return m.Status
  750. }
  751. return 0
  752. }
  753. func (m *UserResourceGetSingleResp) GetCtime() string {
  754. if m != nil {
  755. return m.Ctime
  756. }
  757. return ""
  758. }
  759. func (m *UserResourceGetSingleResp) GetMtime() string {
  760. if m != nil {
  761. return m.Mtime
  762. }
  763. return ""
  764. }
  765. func init() {
  766. proto.RegisterType((*UserResourceAddReq)(nil), "live.liveadmin.v2.UserResourceAddReq")
  767. proto.RegisterType((*UserResourceAddResp)(nil), "live.liveadmin.v2.UserResourceAddResp")
  768. proto.RegisterType((*UserResourceEditReq)(nil), "live.liveadmin.v2.UserResourceEditReq")
  769. proto.RegisterType((*UserResourceEditResp)(nil), "live.liveadmin.v2.UserResourceEditResp")
  770. proto.RegisterType((*UserResourceListReq)(nil), "live.liveadmin.v2.UserResourceListReq")
  771. proto.RegisterType((*UserResourceListResp)(nil), "live.liveadmin.v2.UserResourceListResp")
  772. proto.RegisterType((*UserResourceListResp_List)(nil), "live.liveadmin.v2.UserResourceListResp.List")
  773. proto.RegisterType((*UserResourceSetStatusReq)(nil), "live.liveadmin.v2.UserResourceSetStatusReq")
  774. proto.RegisterType((*UserResourceSetStatusResp)(nil), "live.liveadmin.v2.UserResourceSetStatusResp")
  775. proto.RegisterType((*UserResourceGetSingleReq)(nil), "live.liveadmin.v2.UserResourceGetSingleReq")
  776. proto.RegisterType((*UserResourceGetSingleResp)(nil), "live.liveadmin.v2.UserResourceGetSingleResp")
  777. }
  778. func (m *UserResourceAddReq) Marshal() (dAtA []byte, err error) {
  779. size := m.Size()
  780. dAtA = make([]byte, size)
  781. n, err := m.MarshalTo(dAtA)
  782. if err != nil {
  783. return nil, err
  784. }
  785. return dAtA[:n], nil
  786. }
  787. func (m *UserResourceAddReq) MarshalTo(dAtA []byte) (int, error) {
  788. var i int
  789. _ = i
  790. var l int
  791. _ = l
  792. if m.ResType != 0 {
  793. dAtA[i] = 0x8
  794. i++
  795. i = encodeVarintUserResource(dAtA, i, uint64(m.ResType))
  796. }
  797. if len(m.Title) > 0 {
  798. dAtA[i] = 0x12
  799. i++
  800. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Title)))
  801. i += copy(dAtA[i:], m.Title)
  802. }
  803. if len(m.Url) > 0 {
  804. dAtA[i] = 0x1a
  805. i++
  806. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Url)))
  807. i += copy(dAtA[i:], m.Url)
  808. }
  809. if m.Weight != 0 {
  810. dAtA[i] = 0x20
  811. i++
  812. i = encodeVarintUserResource(dAtA, i, uint64(m.Weight))
  813. }
  814. if len(m.Creator) > 0 {
  815. dAtA[i] = 0x2a
  816. i++
  817. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Creator)))
  818. i += copy(dAtA[i:], m.Creator)
  819. }
  820. if m.XXX_unrecognized != nil {
  821. i += copy(dAtA[i:], m.XXX_unrecognized)
  822. }
  823. return i, nil
  824. }
  825. func (m *UserResourceAddResp) Marshal() (dAtA []byte, err error) {
  826. size := m.Size()
  827. dAtA = make([]byte, size)
  828. n, err := m.MarshalTo(dAtA)
  829. if err != nil {
  830. return nil, err
  831. }
  832. return dAtA[:n], nil
  833. }
  834. func (m *UserResourceAddResp) MarshalTo(dAtA []byte) (int, error) {
  835. var i int
  836. _ = i
  837. var l int
  838. _ = l
  839. if m.Id != 0 {
  840. dAtA[i] = 0x8
  841. i++
  842. i = encodeVarintUserResource(dAtA, i, uint64(m.Id))
  843. }
  844. if m.CustomId != 0 {
  845. dAtA[i] = 0x18
  846. i++
  847. i = encodeVarintUserResource(dAtA, i, uint64(m.CustomId))
  848. }
  849. if m.XXX_unrecognized != nil {
  850. i += copy(dAtA[i:], m.XXX_unrecognized)
  851. }
  852. return i, nil
  853. }
  854. func (m *UserResourceEditReq) Marshal() (dAtA []byte, err error) {
  855. size := m.Size()
  856. dAtA = make([]byte, size)
  857. n, err := m.MarshalTo(dAtA)
  858. if err != nil {
  859. return nil, err
  860. }
  861. return dAtA[:n], nil
  862. }
  863. func (m *UserResourceEditReq) MarshalTo(dAtA []byte) (int, error) {
  864. var i int
  865. _ = i
  866. var l int
  867. _ = l
  868. if m.ResType != 0 {
  869. dAtA[i] = 0x8
  870. i++
  871. i = encodeVarintUserResource(dAtA, i, uint64(m.ResType))
  872. }
  873. if m.CustomId != 0 {
  874. dAtA[i] = 0x10
  875. i++
  876. i = encodeVarintUserResource(dAtA, i, uint64(m.CustomId))
  877. }
  878. if len(m.Title) > 0 {
  879. dAtA[i] = 0x1a
  880. i++
  881. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Title)))
  882. i += copy(dAtA[i:], m.Title)
  883. }
  884. if len(m.Url) > 0 {
  885. dAtA[i] = 0x22
  886. i++
  887. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Url)))
  888. i += copy(dAtA[i:], m.Url)
  889. }
  890. if m.Weight != 0 {
  891. dAtA[i] = 0x28
  892. i++
  893. i = encodeVarintUserResource(dAtA, i, uint64(m.Weight))
  894. }
  895. if m.XXX_unrecognized != nil {
  896. i += copy(dAtA[i:], m.XXX_unrecognized)
  897. }
  898. return i, nil
  899. }
  900. func (m *UserResourceEditResp) Marshal() (dAtA []byte, err error) {
  901. size := m.Size()
  902. dAtA = make([]byte, size)
  903. n, err := m.MarshalTo(dAtA)
  904. if err != nil {
  905. return nil, err
  906. }
  907. return dAtA[:n], nil
  908. }
  909. func (m *UserResourceEditResp) MarshalTo(dAtA []byte) (int, error) {
  910. var i int
  911. _ = i
  912. var l int
  913. _ = l
  914. if m.XXX_unrecognized != nil {
  915. i += copy(dAtA[i:], m.XXX_unrecognized)
  916. }
  917. return i, nil
  918. }
  919. func (m *UserResourceListReq) Marshal() (dAtA []byte, err error) {
  920. size := m.Size()
  921. dAtA = make([]byte, size)
  922. n, err := m.MarshalTo(dAtA)
  923. if err != nil {
  924. return nil, err
  925. }
  926. return dAtA[:n], nil
  927. }
  928. func (m *UserResourceListReq) MarshalTo(dAtA []byte) (int, error) {
  929. var i int
  930. _ = i
  931. var l int
  932. _ = l
  933. if m.ResType != 0 {
  934. dAtA[i] = 0x8
  935. i++
  936. i = encodeVarintUserResource(dAtA, i, uint64(m.ResType))
  937. }
  938. if m.Page != 0 {
  939. dAtA[i] = 0x10
  940. i++
  941. i = encodeVarintUserResource(dAtA, i, uint64(m.Page))
  942. }
  943. if m.PageSize != 0 {
  944. dAtA[i] = 0x18
  945. i++
  946. i = encodeVarintUserResource(dAtA, i, uint64(m.PageSize))
  947. }
  948. if m.XXX_unrecognized != nil {
  949. i += copy(dAtA[i:], m.XXX_unrecognized)
  950. }
  951. return i, nil
  952. }
  953. func (m *UserResourceListResp) Marshal() (dAtA []byte, err error) {
  954. size := m.Size()
  955. dAtA = make([]byte, size)
  956. n, err := m.MarshalTo(dAtA)
  957. if err != nil {
  958. return nil, err
  959. }
  960. return dAtA[:n], nil
  961. }
  962. func (m *UserResourceListResp) MarshalTo(dAtA []byte) (int, error) {
  963. var i int
  964. _ = i
  965. var l int
  966. _ = l
  967. if m.CurrentPage != 0 {
  968. dAtA[i] = 0x8
  969. i++
  970. i = encodeVarintUserResource(dAtA, i, uint64(m.CurrentPage))
  971. }
  972. if m.TotalCount != 0 {
  973. dAtA[i] = 0x10
  974. i++
  975. i = encodeVarintUserResource(dAtA, i, uint64(m.TotalCount))
  976. }
  977. if len(m.List) > 0 {
  978. for _, msg := range m.List {
  979. dAtA[i] = 0x1a
  980. i++
  981. i = encodeVarintUserResource(dAtA, i, uint64(msg.Size()))
  982. n, err := msg.MarshalTo(dAtA[i:])
  983. if err != nil {
  984. return 0, err
  985. }
  986. i += n
  987. }
  988. }
  989. if m.XXX_unrecognized != nil {
  990. i += copy(dAtA[i:], m.XXX_unrecognized)
  991. }
  992. return i, nil
  993. }
  994. func (m *UserResourceListResp_List) Marshal() (dAtA []byte, err error) {
  995. size := m.Size()
  996. dAtA = make([]byte, size)
  997. n, err := m.MarshalTo(dAtA)
  998. if err != nil {
  999. return nil, err
  1000. }
  1001. return dAtA[:n], nil
  1002. }
  1003. func (m *UserResourceListResp_List) MarshalTo(dAtA []byte) (int, error) {
  1004. var i int
  1005. _ = i
  1006. var l int
  1007. _ = l
  1008. if m.Id != 0 {
  1009. dAtA[i] = 0x8
  1010. i++
  1011. i = encodeVarintUserResource(dAtA, i, uint64(m.Id))
  1012. }
  1013. if m.ResType != 0 {
  1014. dAtA[i] = 0x10
  1015. i++
  1016. i = encodeVarintUserResource(dAtA, i, uint64(m.ResType))
  1017. }
  1018. if m.CustomId != 0 {
  1019. dAtA[i] = 0x18
  1020. i++
  1021. i = encodeVarintUserResource(dAtA, i, uint64(m.CustomId))
  1022. }
  1023. if len(m.Title) > 0 {
  1024. dAtA[i] = 0x22
  1025. i++
  1026. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Title)))
  1027. i += copy(dAtA[i:], m.Title)
  1028. }
  1029. if len(m.Url) > 0 {
  1030. dAtA[i] = 0x2a
  1031. i++
  1032. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Url)))
  1033. i += copy(dAtA[i:], m.Url)
  1034. }
  1035. if m.Weight != 0 {
  1036. dAtA[i] = 0x30
  1037. i++
  1038. i = encodeVarintUserResource(dAtA, i, uint64(m.Weight))
  1039. }
  1040. if len(m.Creator) > 0 {
  1041. dAtA[i] = 0x3a
  1042. i++
  1043. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Creator)))
  1044. i += copy(dAtA[i:], m.Creator)
  1045. }
  1046. if m.Status != 0 {
  1047. dAtA[i] = 0x40
  1048. i++
  1049. i = encodeVarintUserResource(dAtA, i, uint64(m.Status))
  1050. }
  1051. if len(m.Ctime) > 0 {
  1052. dAtA[i] = 0x4a
  1053. i++
  1054. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Ctime)))
  1055. i += copy(dAtA[i:], m.Ctime)
  1056. }
  1057. if len(m.Mtime) > 0 {
  1058. dAtA[i] = 0x52
  1059. i++
  1060. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Mtime)))
  1061. i += copy(dAtA[i:], m.Mtime)
  1062. }
  1063. if m.XXX_unrecognized != nil {
  1064. i += copy(dAtA[i:], m.XXX_unrecognized)
  1065. }
  1066. return i, nil
  1067. }
  1068. func (m *UserResourceSetStatusReq) Marshal() (dAtA []byte, err error) {
  1069. size := m.Size()
  1070. dAtA = make([]byte, size)
  1071. n, err := m.MarshalTo(dAtA)
  1072. if err != nil {
  1073. return nil, err
  1074. }
  1075. return dAtA[:n], nil
  1076. }
  1077. func (m *UserResourceSetStatusReq) MarshalTo(dAtA []byte) (int, error) {
  1078. var i int
  1079. _ = i
  1080. var l int
  1081. _ = l
  1082. if m.ResType != 0 {
  1083. dAtA[i] = 0x8
  1084. i++
  1085. i = encodeVarintUserResource(dAtA, i, uint64(m.ResType))
  1086. }
  1087. if m.CustomId != 0 {
  1088. dAtA[i] = 0x10
  1089. i++
  1090. i = encodeVarintUserResource(dAtA, i, uint64(m.CustomId))
  1091. }
  1092. if m.Status != 0 {
  1093. dAtA[i] = 0x18
  1094. i++
  1095. i = encodeVarintUserResource(dAtA, i, uint64(m.Status))
  1096. }
  1097. if m.XXX_unrecognized != nil {
  1098. i += copy(dAtA[i:], m.XXX_unrecognized)
  1099. }
  1100. return i, nil
  1101. }
  1102. func (m *UserResourceSetStatusResp) Marshal() (dAtA []byte, err error) {
  1103. size := m.Size()
  1104. dAtA = make([]byte, size)
  1105. n, err := m.MarshalTo(dAtA)
  1106. if err != nil {
  1107. return nil, err
  1108. }
  1109. return dAtA[:n], nil
  1110. }
  1111. func (m *UserResourceSetStatusResp) MarshalTo(dAtA []byte) (int, error) {
  1112. var i int
  1113. _ = i
  1114. var l int
  1115. _ = l
  1116. if m.XXX_unrecognized != nil {
  1117. i += copy(dAtA[i:], m.XXX_unrecognized)
  1118. }
  1119. return i, nil
  1120. }
  1121. func (m *UserResourceGetSingleReq) Marshal() (dAtA []byte, err error) {
  1122. size := m.Size()
  1123. dAtA = make([]byte, size)
  1124. n, err := m.MarshalTo(dAtA)
  1125. if err != nil {
  1126. return nil, err
  1127. }
  1128. return dAtA[:n], nil
  1129. }
  1130. func (m *UserResourceGetSingleReq) MarshalTo(dAtA []byte) (int, error) {
  1131. var i int
  1132. _ = i
  1133. var l int
  1134. _ = l
  1135. if m.ResType != 0 {
  1136. dAtA[i] = 0x8
  1137. i++
  1138. i = encodeVarintUserResource(dAtA, i, uint64(m.ResType))
  1139. }
  1140. if m.CustomId != 0 {
  1141. dAtA[i] = 0x10
  1142. i++
  1143. i = encodeVarintUserResource(dAtA, i, uint64(m.CustomId))
  1144. }
  1145. if m.XXX_unrecognized != nil {
  1146. i += copy(dAtA[i:], m.XXX_unrecognized)
  1147. }
  1148. return i, nil
  1149. }
  1150. func (m *UserResourceGetSingleResp) Marshal() (dAtA []byte, err error) {
  1151. size := m.Size()
  1152. dAtA = make([]byte, size)
  1153. n, err := m.MarshalTo(dAtA)
  1154. if err != nil {
  1155. return nil, err
  1156. }
  1157. return dAtA[:n], nil
  1158. }
  1159. func (m *UserResourceGetSingleResp) MarshalTo(dAtA []byte) (int, error) {
  1160. var i int
  1161. _ = i
  1162. var l int
  1163. _ = l
  1164. if m.Id != 0 {
  1165. dAtA[i] = 0x8
  1166. i++
  1167. i = encodeVarintUserResource(dAtA, i, uint64(m.Id))
  1168. }
  1169. if m.ResType != 0 {
  1170. dAtA[i] = 0x10
  1171. i++
  1172. i = encodeVarintUserResource(dAtA, i, uint64(m.ResType))
  1173. }
  1174. if m.CustomId != 0 {
  1175. dAtA[i] = 0x18
  1176. i++
  1177. i = encodeVarintUserResource(dAtA, i, uint64(m.CustomId))
  1178. }
  1179. if len(m.Title) > 0 {
  1180. dAtA[i] = 0x22
  1181. i++
  1182. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Title)))
  1183. i += copy(dAtA[i:], m.Title)
  1184. }
  1185. if len(m.Url) > 0 {
  1186. dAtA[i] = 0x2a
  1187. i++
  1188. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Url)))
  1189. i += copy(dAtA[i:], m.Url)
  1190. }
  1191. if m.Weight != 0 {
  1192. dAtA[i] = 0x30
  1193. i++
  1194. i = encodeVarintUserResource(dAtA, i, uint64(m.Weight))
  1195. }
  1196. if len(m.Creator) > 0 {
  1197. dAtA[i] = 0x3a
  1198. i++
  1199. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Creator)))
  1200. i += copy(dAtA[i:], m.Creator)
  1201. }
  1202. if m.Status != 0 {
  1203. dAtA[i] = 0x40
  1204. i++
  1205. i = encodeVarintUserResource(dAtA, i, uint64(m.Status))
  1206. }
  1207. if len(m.Ctime) > 0 {
  1208. dAtA[i] = 0x4a
  1209. i++
  1210. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Ctime)))
  1211. i += copy(dAtA[i:], m.Ctime)
  1212. }
  1213. if len(m.Mtime) > 0 {
  1214. dAtA[i] = 0x52
  1215. i++
  1216. i = encodeVarintUserResource(dAtA, i, uint64(len(m.Mtime)))
  1217. i += copy(dAtA[i:], m.Mtime)
  1218. }
  1219. if m.XXX_unrecognized != nil {
  1220. i += copy(dAtA[i:], m.XXX_unrecognized)
  1221. }
  1222. return i, nil
  1223. }
  1224. func encodeVarintUserResource(dAtA []byte, offset int, v uint64) int {
  1225. for v >= 1<<7 {
  1226. dAtA[offset] = uint8(v&0x7f | 0x80)
  1227. v >>= 7
  1228. offset++
  1229. }
  1230. dAtA[offset] = uint8(v)
  1231. return offset + 1
  1232. }
  1233. func (m *UserResourceAddReq) Size() (n int) {
  1234. if m == nil {
  1235. return 0
  1236. }
  1237. var l int
  1238. _ = l
  1239. if m.ResType != 0 {
  1240. n += 1 + sovUserResource(uint64(m.ResType))
  1241. }
  1242. l = len(m.Title)
  1243. if l > 0 {
  1244. n += 1 + l + sovUserResource(uint64(l))
  1245. }
  1246. l = len(m.Url)
  1247. if l > 0 {
  1248. n += 1 + l + sovUserResource(uint64(l))
  1249. }
  1250. if m.Weight != 0 {
  1251. n += 1 + sovUserResource(uint64(m.Weight))
  1252. }
  1253. l = len(m.Creator)
  1254. if l > 0 {
  1255. n += 1 + l + sovUserResource(uint64(l))
  1256. }
  1257. if m.XXX_unrecognized != nil {
  1258. n += len(m.XXX_unrecognized)
  1259. }
  1260. return n
  1261. }
  1262. func (m *UserResourceAddResp) Size() (n int) {
  1263. if m == nil {
  1264. return 0
  1265. }
  1266. var l int
  1267. _ = l
  1268. if m.Id != 0 {
  1269. n += 1 + sovUserResource(uint64(m.Id))
  1270. }
  1271. if m.CustomId != 0 {
  1272. n += 1 + sovUserResource(uint64(m.CustomId))
  1273. }
  1274. if m.XXX_unrecognized != nil {
  1275. n += len(m.XXX_unrecognized)
  1276. }
  1277. return n
  1278. }
  1279. func (m *UserResourceEditReq) Size() (n int) {
  1280. if m == nil {
  1281. return 0
  1282. }
  1283. var l int
  1284. _ = l
  1285. if m.ResType != 0 {
  1286. n += 1 + sovUserResource(uint64(m.ResType))
  1287. }
  1288. if m.CustomId != 0 {
  1289. n += 1 + sovUserResource(uint64(m.CustomId))
  1290. }
  1291. l = len(m.Title)
  1292. if l > 0 {
  1293. n += 1 + l + sovUserResource(uint64(l))
  1294. }
  1295. l = len(m.Url)
  1296. if l > 0 {
  1297. n += 1 + l + sovUserResource(uint64(l))
  1298. }
  1299. if m.Weight != 0 {
  1300. n += 1 + sovUserResource(uint64(m.Weight))
  1301. }
  1302. if m.XXX_unrecognized != nil {
  1303. n += len(m.XXX_unrecognized)
  1304. }
  1305. return n
  1306. }
  1307. func (m *UserResourceEditResp) Size() (n int) {
  1308. if m == nil {
  1309. return 0
  1310. }
  1311. var l int
  1312. _ = l
  1313. if m.XXX_unrecognized != nil {
  1314. n += len(m.XXX_unrecognized)
  1315. }
  1316. return n
  1317. }
  1318. func (m *UserResourceListReq) Size() (n int) {
  1319. if m == nil {
  1320. return 0
  1321. }
  1322. var l int
  1323. _ = l
  1324. if m.ResType != 0 {
  1325. n += 1 + sovUserResource(uint64(m.ResType))
  1326. }
  1327. if m.Page != 0 {
  1328. n += 1 + sovUserResource(uint64(m.Page))
  1329. }
  1330. if m.PageSize != 0 {
  1331. n += 1 + sovUserResource(uint64(m.PageSize))
  1332. }
  1333. if m.XXX_unrecognized != nil {
  1334. n += len(m.XXX_unrecognized)
  1335. }
  1336. return n
  1337. }
  1338. func (m *UserResourceListResp) Size() (n int) {
  1339. if m == nil {
  1340. return 0
  1341. }
  1342. var l int
  1343. _ = l
  1344. if m.CurrentPage != 0 {
  1345. n += 1 + sovUserResource(uint64(m.CurrentPage))
  1346. }
  1347. if m.TotalCount != 0 {
  1348. n += 1 + sovUserResource(uint64(m.TotalCount))
  1349. }
  1350. if len(m.List) > 0 {
  1351. for _, e := range m.List {
  1352. l = e.Size()
  1353. n += 1 + l + sovUserResource(uint64(l))
  1354. }
  1355. }
  1356. if m.XXX_unrecognized != nil {
  1357. n += len(m.XXX_unrecognized)
  1358. }
  1359. return n
  1360. }
  1361. func (m *UserResourceListResp_List) Size() (n int) {
  1362. if m == nil {
  1363. return 0
  1364. }
  1365. var l int
  1366. _ = l
  1367. if m.Id != 0 {
  1368. n += 1 + sovUserResource(uint64(m.Id))
  1369. }
  1370. if m.ResType != 0 {
  1371. n += 1 + sovUserResource(uint64(m.ResType))
  1372. }
  1373. if m.CustomId != 0 {
  1374. n += 1 + sovUserResource(uint64(m.CustomId))
  1375. }
  1376. l = len(m.Title)
  1377. if l > 0 {
  1378. n += 1 + l + sovUserResource(uint64(l))
  1379. }
  1380. l = len(m.Url)
  1381. if l > 0 {
  1382. n += 1 + l + sovUserResource(uint64(l))
  1383. }
  1384. if m.Weight != 0 {
  1385. n += 1 + sovUserResource(uint64(m.Weight))
  1386. }
  1387. l = len(m.Creator)
  1388. if l > 0 {
  1389. n += 1 + l + sovUserResource(uint64(l))
  1390. }
  1391. if m.Status != 0 {
  1392. n += 1 + sovUserResource(uint64(m.Status))
  1393. }
  1394. l = len(m.Ctime)
  1395. if l > 0 {
  1396. n += 1 + l + sovUserResource(uint64(l))
  1397. }
  1398. l = len(m.Mtime)
  1399. if l > 0 {
  1400. n += 1 + l + sovUserResource(uint64(l))
  1401. }
  1402. if m.XXX_unrecognized != nil {
  1403. n += len(m.XXX_unrecognized)
  1404. }
  1405. return n
  1406. }
  1407. func (m *UserResourceSetStatusReq) Size() (n int) {
  1408. if m == nil {
  1409. return 0
  1410. }
  1411. var l int
  1412. _ = l
  1413. if m.ResType != 0 {
  1414. n += 1 + sovUserResource(uint64(m.ResType))
  1415. }
  1416. if m.CustomId != 0 {
  1417. n += 1 + sovUserResource(uint64(m.CustomId))
  1418. }
  1419. if m.Status != 0 {
  1420. n += 1 + sovUserResource(uint64(m.Status))
  1421. }
  1422. if m.XXX_unrecognized != nil {
  1423. n += len(m.XXX_unrecognized)
  1424. }
  1425. return n
  1426. }
  1427. func (m *UserResourceSetStatusResp) Size() (n int) {
  1428. if m == nil {
  1429. return 0
  1430. }
  1431. var l int
  1432. _ = l
  1433. if m.XXX_unrecognized != nil {
  1434. n += len(m.XXX_unrecognized)
  1435. }
  1436. return n
  1437. }
  1438. func (m *UserResourceGetSingleReq) Size() (n int) {
  1439. if m == nil {
  1440. return 0
  1441. }
  1442. var l int
  1443. _ = l
  1444. if m.ResType != 0 {
  1445. n += 1 + sovUserResource(uint64(m.ResType))
  1446. }
  1447. if m.CustomId != 0 {
  1448. n += 1 + sovUserResource(uint64(m.CustomId))
  1449. }
  1450. if m.XXX_unrecognized != nil {
  1451. n += len(m.XXX_unrecognized)
  1452. }
  1453. return n
  1454. }
  1455. func (m *UserResourceGetSingleResp) Size() (n int) {
  1456. if m == nil {
  1457. return 0
  1458. }
  1459. var l int
  1460. _ = l
  1461. if m.Id != 0 {
  1462. n += 1 + sovUserResource(uint64(m.Id))
  1463. }
  1464. if m.ResType != 0 {
  1465. n += 1 + sovUserResource(uint64(m.ResType))
  1466. }
  1467. if m.CustomId != 0 {
  1468. n += 1 + sovUserResource(uint64(m.CustomId))
  1469. }
  1470. l = len(m.Title)
  1471. if l > 0 {
  1472. n += 1 + l + sovUserResource(uint64(l))
  1473. }
  1474. l = len(m.Url)
  1475. if l > 0 {
  1476. n += 1 + l + sovUserResource(uint64(l))
  1477. }
  1478. if m.Weight != 0 {
  1479. n += 1 + sovUserResource(uint64(m.Weight))
  1480. }
  1481. l = len(m.Creator)
  1482. if l > 0 {
  1483. n += 1 + l + sovUserResource(uint64(l))
  1484. }
  1485. if m.Status != 0 {
  1486. n += 1 + sovUserResource(uint64(m.Status))
  1487. }
  1488. l = len(m.Ctime)
  1489. if l > 0 {
  1490. n += 1 + l + sovUserResource(uint64(l))
  1491. }
  1492. l = len(m.Mtime)
  1493. if l > 0 {
  1494. n += 1 + l + sovUserResource(uint64(l))
  1495. }
  1496. if m.XXX_unrecognized != nil {
  1497. n += len(m.XXX_unrecognized)
  1498. }
  1499. return n
  1500. }
  1501. func sovUserResource(x uint64) (n int) {
  1502. for {
  1503. n++
  1504. x >>= 7
  1505. if x == 0 {
  1506. break
  1507. }
  1508. }
  1509. return n
  1510. }
  1511. func sozUserResource(x uint64) (n int) {
  1512. return sovUserResource(uint64((x << 1) ^ uint64((int64(x) >> 63))))
  1513. }
  1514. func (m *UserResourceAddReq) Unmarshal(dAtA []byte) error {
  1515. l := len(dAtA)
  1516. iNdEx := 0
  1517. for iNdEx < l {
  1518. preIndex := iNdEx
  1519. var wire uint64
  1520. for shift := uint(0); ; shift += 7 {
  1521. if shift >= 64 {
  1522. return ErrIntOverflowUserResource
  1523. }
  1524. if iNdEx >= l {
  1525. return io.ErrUnexpectedEOF
  1526. }
  1527. b := dAtA[iNdEx]
  1528. iNdEx++
  1529. wire |= (uint64(b) & 0x7F) << shift
  1530. if b < 0x80 {
  1531. break
  1532. }
  1533. }
  1534. fieldNum := int32(wire >> 3)
  1535. wireType := int(wire & 0x7)
  1536. if wireType == 4 {
  1537. return fmt.Errorf("proto: UserResourceAddReq: wiretype end group for non-group")
  1538. }
  1539. if fieldNum <= 0 {
  1540. return fmt.Errorf("proto: UserResourceAddReq: illegal tag %d (wire type %d)", fieldNum, wire)
  1541. }
  1542. switch fieldNum {
  1543. case 1:
  1544. if wireType != 0 {
  1545. return fmt.Errorf("proto: wrong wireType = %d for field ResType", wireType)
  1546. }
  1547. m.ResType = 0
  1548. for shift := uint(0); ; shift += 7 {
  1549. if shift >= 64 {
  1550. return ErrIntOverflowUserResource
  1551. }
  1552. if iNdEx >= l {
  1553. return io.ErrUnexpectedEOF
  1554. }
  1555. b := dAtA[iNdEx]
  1556. iNdEx++
  1557. m.ResType |= (int32(b) & 0x7F) << shift
  1558. if b < 0x80 {
  1559. break
  1560. }
  1561. }
  1562. case 2:
  1563. if wireType != 2 {
  1564. return fmt.Errorf("proto: wrong wireType = %d for field Title", wireType)
  1565. }
  1566. var stringLen uint64
  1567. for shift := uint(0); ; shift += 7 {
  1568. if shift >= 64 {
  1569. return ErrIntOverflowUserResource
  1570. }
  1571. if iNdEx >= l {
  1572. return io.ErrUnexpectedEOF
  1573. }
  1574. b := dAtA[iNdEx]
  1575. iNdEx++
  1576. stringLen |= (uint64(b) & 0x7F) << shift
  1577. if b < 0x80 {
  1578. break
  1579. }
  1580. }
  1581. intStringLen := int(stringLen)
  1582. if intStringLen < 0 {
  1583. return ErrInvalidLengthUserResource
  1584. }
  1585. postIndex := iNdEx + intStringLen
  1586. if postIndex > l {
  1587. return io.ErrUnexpectedEOF
  1588. }
  1589. m.Title = string(dAtA[iNdEx:postIndex])
  1590. iNdEx = postIndex
  1591. case 3:
  1592. if wireType != 2 {
  1593. return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType)
  1594. }
  1595. var stringLen uint64
  1596. for shift := uint(0); ; shift += 7 {
  1597. if shift >= 64 {
  1598. return ErrIntOverflowUserResource
  1599. }
  1600. if iNdEx >= l {
  1601. return io.ErrUnexpectedEOF
  1602. }
  1603. b := dAtA[iNdEx]
  1604. iNdEx++
  1605. stringLen |= (uint64(b) & 0x7F) << shift
  1606. if b < 0x80 {
  1607. break
  1608. }
  1609. }
  1610. intStringLen := int(stringLen)
  1611. if intStringLen < 0 {
  1612. return ErrInvalidLengthUserResource
  1613. }
  1614. postIndex := iNdEx + intStringLen
  1615. if postIndex > l {
  1616. return io.ErrUnexpectedEOF
  1617. }
  1618. m.Url = string(dAtA[iNdEx:postIndex])
  1619. iNdEx = postIndex
  1620. case 4:
  1621. if wireType != 0 {
  1622. return fmt.Errorf("proto: wrong wireType = %d for field Weight", wireType)
  1623. }
  1624. m.Weight = 0
  1625. for shift := uint(0); ; shift += 7 {
  1626. if shift >= 64 {
  1627. return ErrIntOverflowUserResource
  1628. }
  1629. if iNdEx >= l {
  1630. return io.ErrUnexpectedEOF
  1631. }
  1632. b := dAtA[iNdEx]
  1633. iNdEx++
  1634. m.Weight |= (int32(b) & 0x7F) << shift
  1635. if b < 0x80 {
  1636. break
  1637. }
  1638. }
  1639. case 5:
  1640. if wireType != 2 {
  1641. return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType)
  1642. }
  1643. var stringLen uint64
  1644. for shift := uint(0); ; shift += 7 {
  1645. if shift >= 64 {
  1646. return ErrIntOverflowUserResource
  1647. }
  1648. if iNdEx >= l {
  1649. return io.ErrUnexpectedEOF
  1650. }
  1651. b := dAtA[iNdEx]
  1652. iNdEx++
  1653. stringLen |= (uint64(b) & 0x7F) << shift
  1654. if b < 0x80 {
  1655. break
  1656. }
  1657. }
  1658. intStringLen := int(stringLen)
  1659. if intStringLen < 0 {
  1660. return ErrInvalidLengthUserResource
  1661. }
  1662. postIndex := iNdEx + intStringLen
  1663. if postIndex > l {
  1664. return io.ErrUnexpectedEOF
  1665. }
  1666. m.Creator = string(dAtA[iNdEx:postIndex])
  1667. iNdEx = postIndex
  1668. default:
  1669. iNdEx = preIndex
  1670. skippy, err := skipUserResource(dAtA[iNdEx:])
  1671. if err != nil {
  1672. return err
  1673. }
  1674. if skippy < 0 {
  1675. return ErrInvalidLengthUserResource
  1676. }
  1677. if (iNdEx + skippy) > l {
  1678. return io.ErrUnexpectedEOF
  1679. }
  1680. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  1681. iNdEx += skippy
  1682. }
  1683. }
  1684. if iNdEx > l {
  1685. return io.ErrUnexpectedEOF
  1686. }
  1687. return nil
  1688. }
  1689. func (m *UserResourceAddResp) Unmarshal(dAtA []byte) error {
  1690. l := len(dAtA)
  1691. iNdEx := 0
  1692. for iNdEx < l {
  1693. preIndex := iNdEx
  1694. var wire uint64
  1695. for shift := uint(0); ; shift += 7 {
  1696. if shift >= 64 {
  1697. return ErrIntOverflowUserResource
  1698. }
  1699. if iNdEx >= l {
  1700. return io.ErrUnexpectedEOF
  1701. }
  1702. b := dAtA[iNdEx]
  1703. iNdEx++
  1704. wire |= (uint64(b) & 0x7F) << shift
  1705. if b < 0x80 {
  1706. break
  1707. }
  1708. }
  1709. fieldNum := int32(wire >> 3)
  1710. wireType := int(wire & 0x7)
  1711. if wireType == 4 {
  1712. return fmt.Errorf("proto: UserResourceAddResp: wiretype end group for non-group")
  1713. }
  1714. if fieldNum <= 0 {
  1715. return fmt.Errorf("proto: UserResourceAddResp: illegal tag %d (wire type %d)", fieldNum, wire)
  1716. }
  1717. switch fieldNum {
  1718. case 1:
  1719. if wireType != 0 {
  1720. return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
  1721. }
  1722. m.Id = 0
  1723. for shift := uint(0); ; shift += 7 {
  1724. if shift >= 64 {
  1725. return ErrIntOverflowUserResource
  1726. }
  1727. if iNdEx >= l {
  1728. return io.ErrUnexpectedEOF
  1729. }
  1730. b := dAtA[iNdEx]
  1731. iNdEx++
  1732. m.Id |= (int32(b) & 0x7F) << shift
  1733. if b < 0x80 {
  1734. break
  1735. }
  1736. }
  1737. case 3:
  1738. if wireType != 0 {
  1739. return fmt.Errorf("proto: wrong wireType = %d for field CustomId", wireType)
  1740. }
  1741. m.CustomId = 0
  1742. for shift := uint(0); ; shift += 7 {
  1743. if shift >= 64 {
  1744. return ErrIntOverflowUserResource
  1745. }
  1746. if iNdEx >= l {
  1747. return io.ErrUnexpectedEOF
  1748. }
  1749. b := dAtA[iNdEx]
  1750. iNdEx++
  1751. m.CustomId |= (int32(b) & 0x7F) << shift
  1752. if b < 0x80 {
  1753. break
  1754. }
  1755. }
  1756. default:
  1757. iNdEx = preIndex
  1758. skippy, err := skipUserResource(dAtA[iNdEx:])
  1759. if err != nil {
  1760. return err
  1761. }
  1762. if skippy < 0 {
  1763. return ErrInvalidLengthUserResource
  1764. }
  1765. if (iNdEx + skippy) > l {
  1766. return io.ErrUnexpectedEOF
  1767. }
  1768. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  1769. iNdEx += skippy
  1770. }
  1771. }
  1772. if iNdEx > l {
  1773. return io.ErrUnexpectedEOF
  1774. }
  1775. return nil
  1776. }
  1777. func (m *UserResourceEditReq) Unmarshal(dAtA []byte) error {
  1778. l := len(dAtA)
  1779. iNdEx := 0
  1780. for iNdEx < l {
  1781. preIndex := iNdEx
  1782. var wire uint64
  1783. for shift := uint(0); ; shift += 7 {
  1784. if shift >= 64 {
  1785. return ErrIntOverflowUserResource
  1786. }
  1787. if iNdEx >= l {
  1788. return io.ErrUnexpectedEOF
  1789. }
  1790. b := dAtA[iNdEx]
  1791. iNdEx++
  1792. wire |= (uint64(b) & 0x7F) << shift
  1793. if b < 0x80 {
  1794. break
  1795. }
  1796. }
  1797. fieldNum := int32(wire >> 3)
  1798. wireType := int(wire & 0x7)
  1799. if wireType == 4 {
  1800. return fmt.Errorf("proto: UserResourceEditReq: wiretype end group for non-group")
  1801. }
  1802. if fieldNum <= 0 {
  1803. return fmt.Errorf("proto: UserResourceEditReq: illegal tag %d (wire type %d)", fieldNum, wire)
  1804. }
  1805. switch fieldNum {
  1806. case 1:
  1807. if wireType != 0 {
  1808. return fmt.Errorf("proto: wrong wireType = %d for field ResType", wireType)
  1809. }
  1810. m.ResType = 0
  1811. for shift := uint(0); ; shift += 7 {
  1812. if shift >= 64 {
  1813. return ErrIntOverflowUserResource
  1814. }
  1815. if iNdEx >= l {
  1816. return io.ErrUnexpectedEOF
  1817. }
  1818. b := dAtA[iNdEx]
  1819. iNdEx++
  1820. m.ResType |= (int32(b) & 0x7F) << shift
  1821. if b < 0x80 {
  1822. break
  1823. }
  1824. }
  1825. case 2:
  1826. if wireType != 0 {
  1827. return fmt.Errorf("proto: wrong wireType = %d for field CustomId", wireType)
  1828. }
  1829. m.CustomId = 0
  1830. for shift := uint(0); ; shift += 7 {
  1831. if shift >= 64 {
  1832. return ErrIntOverflowUserResource
  1833. }
  1834. if iNdEx >= l {
  1835. return io.ErrUnexpectedEOF
  1836. }
  1837. b := dAtA[iNdEx]
  1838. iNdEx++
  1839. m.CustomId |= (int32(b) & 0x7F) << shift
  1840. if b < 0x80 {
  1841. break
  1842. }
  1843. }
  1844. case 3:
  1845. if wireType != 2 {
  1846. return fmt.Errorf("proto: wrong wireType = %d for field Title", wireType)
  1847. }
  1848. var stringLen uint64
  1849. for shift := uint(0); ; shift += 7 {
  1850. if shift >= 64 {
  1851. return ErrIntOverflowUserResource
  1852. }
  1853. if iNdEx >= l {
  1854. return io.ErrUnexpectedEOF
  1855. }
  1856. b := dAtA[iNdEx]
  1857. iNdEx++
  1858. stringLen |= (uint64(b) & 0x7F) << shift
  1859. if b < 0x80 {
  1860. break
  1861. }
  1862. }
  1863. intStringLen := int(stringLen)
  1864. if intStringLen < 0 {
  1865. return ErrInvalidLengthUserResource
  1866. }
  1867. postIndex := iNdEx + intStringLen
  1868. if postIndex > l {
  1869. return io.ErrUnexpectedEOF
  1870. }
  1871. m.Title = string(dAtA[iNdEx:postIndex])
  1872. iNdEx = postIndex
  1873. case 4:
  1874. if wireType != 2 {
  1875. return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType)
  1876. }
  1877. var stringLen uint64
  1878. for shift := uint(0); ; shift += 7 {
  1879. if shift >= 64 {
  1880. return ErrIntOverflowUserResource
  1881. }
  1882. if iNdEx >= l {
  1883. return io.ErrUnexpectedEOF
  1884. }
  1885. b := dAtA[iNdEx]
  1886. iNdEx++
  1887. stringLen |= (uint64(b) & 0x7F) << shift
  1888. if b < 0x80 {
  1889. break
  1890. }
  1891. }
  1892. intStringLen := int(stringLen)
  1893. if intStringLen < 0 {
  1894. return ErrInvalidLengthUserResource
  1895. }
  1896. postIndex := iNdEx + intStringLen
  1897. if postIndex > l {
  1898. return io.ErrUnexpectedEOF
  1899. }
  1900. m.Url = string(dAtA[iNdEx:postIndex])
  1901. iNdEx = postIndex
  1902. case 5:
  1903. if wireType != 0 {
  1904. return fmt.Errorf("proto: wrong wireType = %d for field Weight", wireType)
  1905. }
  1906. m.Weight = 0
  1907. for shift := uint(0); ; shift += 7 {
  1908. if shift >= 64 {
  1909. return ErrIntOverflowUserResource
  1910. }
  1911. if iNdEx >= l {
  1912. return io.ErrUnexpectedEOF
  1913. }
  1914. b := dAtA[iNdEx]
  1915. iNdEx++
  1916. m.Weight |= (int32(b) & 0x7F) << shift
  1917. if b < 0x80 {
  1918. break
  1919. }
  1920. }
  1921. default:
  1922. iNdEx = preIndex
  1923. skippy, err := skipUserResource(dAtA[iNdEx:])
  1924. if err != nil {
  1925. return err
  1926. }
  1927. if skippy < 0 {
  1928. return ErrInvalidLengthUserResource
  1929. }
  1930. if (iNdEx + skippy) > l {
  1931. return io.ErrUnexpectedEOF
  1932. }
  1933. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  1934. iNdEx += skippy
  1935. }
  1936. }
  1937. if iNdEx > l {
  1938. return io.ErrUnexpectedEOF
  1939. }
  1940. return nil
  1941. }
  1942. func (m *UserResourceEditResp) Unmarshal(dAtA []byte) error {
  1943. l := len(dAtA)
  1944. iNdEx := 0
  1945. for iNdEx < l {
  1946. preIndex := iNdEx
  1947. var wire uint64
  1948. for shift := uint(0); ; shift += 7 {
  1949. if shift >= 64 {
  1950. return ErrIntOverflowUserResource
  1951. }
  1952. if iNdEx >= l {
  1953. return io.ErrUnexpectedEOF
  1954. }
  1955. b := dAtA[iNdEx]
  1956. iNdEx++
  1957. wire |= (uint64(b) & 0x7F) << shift
  1958. if b < 0x80 {
  1959. break
  1960. }
  1961. }
  1962. fieldNum := int32(wire >> 3)
  1963. wireType := int(wire & 0x7)
  1964. if wireType == 4 {
  1965. return fmt.Errorf("proto: UserResourceEditResp: wiretype end group for non-group")
  1966. }
  1967. if fieldNum <= 0 {
  1968. return fmt.Errorf("proto: UserResourceEditResp: illegal tag %d (wire type %d)", fieldNum, wire)
  1969. }
  1970. switch fieldNum {
  1971. default:
  1972. iNdEx = preIndex
  1973. skippy, err := skipUserResource(dAtA[iNdEx:])
  1974. if err != nil {
  1975. return err
  1976. }
  1977. if skippy < 0 {
  1978. return ErrInvalidLengthUserResource
  1979. }
  1980. if (iNdEx + skippy) > l {
  1981. return io.ErrUnexpectedEOF
  1982. }
  1983. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  1984. iNdEx += skippy
  1985. }
  1986. }
  1987. if iNdEx > l {
  1988. return io.ErrUnexpectedEOF
  1989. }
  1990. return nil
  1991. }
  1992. func (m *UserResourceListReq) Unmarshal(dAtA []byte) error {
  1993. l := len(dAtA)
  1994. iNdEx := 0
  1995. for iNdEx < l {
  1996. preIndex := iNdEx
  1997. var wire uint64
  1998. for shift := uint(0); ; shift += 7 {
  1999. if shift >= 64 {
  2000. return ErrIntOverflowUserResource
  2001. }
  2002. if iNdEx >= l {
  2003. return io.ErrUnexpectedEOF
  2004. }
  2005. b := dAtA[iNdEx]
  2006. iNdEx++
  2007. wire |= (uint64(b) & 0x7F) << shift
  2008. if b < 0x80 {
  2009. break
  2010. }
  2011. }
  2012. fieldNum := int32(wire >> 3)
  2013. wireType := int(wire & 0x7)
  2014. if wireType == 4 {
  2015. return fmt.Errorf("proto: UserResourceListReq: wiretype end group for non-group")
  2016. }
  2017. if fieldNum <= 0 {
  2018. return fmt.Errorf("proto: UserResourceListReq: illegal tag %d (wire type %d)", fieldNum, wire)
  2019. }
  2020. switch fieldNum {
  2021. case 1:
  2022. if wireType != 0 {
  2023. return fmt.Errorf("proto: wrong wireType = %d for field ResType", wireType)
  2024. }
  2025. m.ResType = 0
  2026. for shift := uint(0); ; shift += 7 {
  2027. if shift >= 64 {
  2028. return ErrIntOverflowUserResource
  2029. }
  2030. if iNdEx >= l {
  2031. return io.ErrUnexpectedEOF
  2032. }
  2033. b := dAtA[iNdEx]
  2034. iNdEx++
  2035. m.ResType |= (int32(b) & 0x7F) << shift
  2036. if b < 0x80 {
  2037. break
  2038. }
  2039. }
  2040. case 2:
  2041. if wireType != 0 {
  2042. return fmt.Errorf("proto: wrong wireType = %d for field Page", wireType)
  2043. }
  2044. m.Page = 0
  2045. for shift := uint(0); ; shift += 7 {
  2046. if shift >= 64 {
  2047. return ErrIntOverflowUserResource
  2048. }
  2049. if iNdEx >= l {
  2050. return io.ErrUnexpectedEOF
  2051. }
  2052. b := dAtA[iNdEx]
  2053. iNdEx++
  2054. m.Page |= (int32(b) & 0x7F) << shift
  2055. if b < 0x80 {
  2056. break
  2057. }
  2058. }
  2059. case 3:
  2060. if wireType != 0 {
  2061. return fmt.Errorf("proto: wrong wireType = %d for field PageSize", wireType)
  2062. }
  2063. m.PageSize = 0
  2064. for shift := uint(0); ; shift += 7 {
  2065. if shift >= 64 {
  2066. return ErrIntOverflowUserResource
  2067. }
  2068. if iNdEx >= l {
  2069. return io.ErrUnexpectedEOF
  2070. }
  2071. b := dAtA[iNdEx]
  2072. iNdEx++
  2073. m.PageSize |= (int32(b) & 0x7F) << shift
  2074. if b < 0x80 {
  2075. break
  2076. }
  2077. }
  2078. default:
  2079. iNdEx = preIndex
  2080. skippy, err := skipUserResource(dAtA[iNdEx:])
  2081. if err != nil {
  2082. return err
  2083. }
  2084. if skippy < 0 {
  2085. return ErrInvalidLengthUserResource
  2086. }
  2087. if (iNdEx + skippy) > l {
  2088. return io.ErrUnexpectedEOF
  2089. }
  2090. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  2091. iNdEx += skippy
  2092. }
  2093. }
  2094. if iNdEx > l {
  2095. return io.ErrUnexpectedEOF
  2096. }
  2097. return nil
  2098. }
  2099. func (m *UserResourceListResp) Unmarshal(dAtA []byte) error {
  2100. l := len(dAtA)
  2101. iNdEx := 0
  2102. for iNdEx < l {
  2103. preIndex := iNdEx
  2104. var wire uint64
  2105. for shift := uint(0); ; shift += 7 {
  2106. if shift >= 64 {
  2107. return ErrIntOverflowUserResource
  2108. }
  2109. if iNdEx >= l {
  2110. return io.ErrUnexpectedEOF
  2111. }
  2112. b := dAtA[iNdEx]
  2113. iNdEx++
  2114. wire |= (uint64(b) & 0x7F) << shift
  2115. if b < 0x80 {
  2116. break
  2117. }
  2118. }
  2119. fieldNum := int32(wire >> 3)
  2120. wireType := int(wire & 0x7)
  2121. if wireType == 4 {
  2122. return fmt.Errorf("proto: UserResourceListResp: wiretype end group for non-group")
  2123. }
  2124. if fieldNum <= 0 {
  2125. return fmt.Errorf("proto: UserResourceListResp: illegal tag %d (wire type %d)", fieldNum, wire)
  2126. }
  2127. switch fieldNum {
  2128. case 1:
  2129. if wireType != 0 {
  2130. return fmt.Errorf("proto: wrong wireType = %d for field CurrentPage", wireType)
  2131. }
  2132. m.CurrentPage = 0
  2133. for shift := uint(0); ; shift += 7 {
  2134. if shift >= 64 {
  2135. return ErrIntOverflowUserResource
  2136. }
  2137. if iNdEx >= l {
  2138. return io.ErrUnexpectedEOF
  2139. }
  2140. b := dAtA[iNdEx]
  2141. iNdEx++
  2142. m.CurrentPage |= (int32(b) & 0x7F) << shift
  2143. if b < 0x80 {
  2144. break
  2145. }
  2146. }
  2147. case 2:
  2148. if wireType != 0 {
  2149. return fmt.Errorf("proto: wrong wireType = %d for field TotalCount", wireType)
  2150. }
  2151. m.TotalCount = 0
  2152. for shift := uint(0); ; shift += 7 {
  2153. if shift >= 64 {
  2154. return ErrIntOverflowUserResource
  2155. }
  2156. if iNdEx >= l {
  2157. return io.ErrUnexpectedEOF
  2158. }
  2159. b := dAtA[iNdEx]
  2160. iNdEx++
  2161. m.TotalCount |= (int32(b) & 0x7F) << shift
  2162. if b < 0x80 {
  2163. break
  2164. }
  2165. }
  2166. case 3:
  2167. if wireType != 2 {
  2168. return fmt.Errorf("proto: wrong wireType = %d for field List", wireType)
  2169. }
  2170. var msglen int
  2171. for shift := uint(0); ; shift += 7 {
  2172. if shift >= 64 {
  2173. return ErrIntOverflowUserResource
  2174. }
  2175. if iNdEx >= l {
  2176. return io.ErrUnexpectedEOF
  2177. }
  2178. b := dAtA[iNdEx]
  2179. iNdEx++
  2180. msglen |= (int(b) & 0x7F) << shift
  2181. if b < 0x80 {
  2182. break
  2183. }
  2184. }
  2185. if msglen < 0 {
  2186. return ErrInvalidLengthUserResource
  2187. }
  2188. postIndex := iNdEx + msglen
  2189. if postIndex > l {
  2190. return io.ErrUnexpectedEOF
  2191. }
  2192. m.List = append(m.List, &UserResourceListResp_List{})
  2193. if err := m.List[len(m.List)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  2194. return err
  2195. }
  2196. iNdEx = postIndex
  2197. default:
  2198. iNdEx = preIndex
  2199. skippy, err := skipUserResource(dAtA[iNdEx:])
  2200. if err != nil {
  2201. return err
  2202. }
  2203. if skippy < 0 {
  2204. return ErrInvalidLengthUserResource
  2205. }
  2206. if (iNdEx + skippy) > l {
  2207. return io.ErrUnexpectedEOF
  2208. }
  2209. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  2210. iNdEx += skippy
  2211. }
  2212. }
  2213. if iNdEx > l {
  2214. return io.ErrUnexpectedEOF
  2215. }
  2216. return nil
  2217. }
  2218. func (m *UserResourceListResp_List) Unmarshal(dAtA []byte) error {
  2219. l := len(dAtA)
  2220. iNdEx := 0
  2221. for iNdEx < l {
  2222. preIndex := iNdEx
  2223. var wire uint64
  2224. for shift := uint(0); ; shift += 7 {
  2225. if shift >= 64 {
  2226. return ErrIntOverflowUserResource
  2227. }
  2228. if iNdEx >= l {
  2229. return io.ErrUnexpectedEOF
  2230. }
  2231. b := dAtA[iNdEx]
  2232. iNdEx++
  2233. wire |= (uint64(b) & 0x7F) << shift
  2234. if b < 0x80 {
  2235. break
  2236. }
  2237. }
  2238. fieldNum := int32(wire >> 3)
  2239. wireType := int(wire & 0x7)
  2240. if wireType == 4 {
  2241. return fmt.Errorf("proto: List: wiretype end group for non-group")
  2242. }
  2243. if fieldNum <= 0 {
  2244. return fmt.Errorf("proto: List: illegal tag %d (wire type %d)", fieldNum, wire)
  2245. }
  2246. switch fieldNum {
  2247. case 1:
  2248. if wireType != 0 {
  2249. return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
  2250. }
  2251. m.Id = 0
  2252. for shift := uint(0); ; shift += 7 {
  2253. if shift >= 64 {
  2254. return ErrIntOverflowUserResource
  2255. }
  2256. if iNdEx >= l {
  2257. return io.ErrUnexpectedEOF
  2258. }
  2259. b := dAtA[iNdEx]
  2260. iNdEx++
  2261. m.Id |= (int32(b) & 0x7F) << shift
  2262. if b < 0x80 {
  2263. break
  2264. }
  2265. }
  2266. case 2:
  2267. if wireType != 0 {
  2268. return fmt.Errorf("proto: wrong wireType = %d for field ResType", wireType)
  2269. }
  2270. m.ResType = 0
  2271. for shift := uint(0); ; shift += 7 {
  2272. if shift >= 64 {
  2273. return ErrIntOverflowUserResource
  2274. }
  2275. if iNdEx >= l {
  2276. return io.ErrUnexpectedEOF
  2277. }
  2278. b := dAtA[iNdEx]
  2279. iNdEx++
  2280. m.ResType |= (int32(b) & 0x7F) << shift
  2281. if b < 0x80 {
  2282. break
  2283. }
  2284. }
  2285. case 3:
  2286. if wireType != 0 {
  2287. return fmt.Errorf("proto: wrong wireType = %d for field CustomId", wireType)
  2288. }
  2289. m.CustomId = 0
  2290. for shift := uint(0); ; shift += 7 {
  2291. if shift >= 64 {
  2292. return ErrIntOverflowUserResource
  2293. }
  2294. if iNdEx >= l {
  2295. return io.ErrUnexpectedEOF
  2296. }
  2297. b := dAtA[iNdEx]
  2298. iNdEx++
  2299. m.CustomId |= (int32(b) & 0x7F) << shift
  2300. if b < 0x80 {
  2301. break
  2302. }
  2303. }
  2304. case 4:
  2305. if wireType != 2 {
  2306. return fmt.Errorf("proto: wrong wireType = %d for field Title", wireType)
  2307. }
  2308. var stringLen uint64
  2309. for shift := uint(0); ; shift += 7 {
  2310. if shift >= 64 {
  2311. return ErrIntOverflowUserResource
  2312. }
  2313. if iNdEx >= l {
  2314. return io.ErrUnexpectedEOF
  2315. }
  2316. b := dAtA[iNdEx]
  2317. iNdEx++
  2318. stringLen |= (uint64(b) & 0x7F) << shift
  2319. if b < 0x80 {
  2320. break
  2321. }
  2322. }
  2323. intStringLen := int(stringLen)
  2324. if intStringLen < 0 {
  2325. return ErrInvalidLengthUserResource
  2326. }
  2327. postIndex := iNdEx + intStringLen
  2328. if postIndex > l {
  2329. return io.ErrUnexpectedEOF
  2330. }
  2331. m.Title = string(dAtA[iNdEx:postIndex])
  2332. iNdEx = postIndex
  2333. case 5:
  2334. if wireType != 2 {
  2335. return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType)
  2336. }
  2337. var stringLen uint64
  2338. for shift := uint(0); ; shift += 7 {
  2339. if shift >= 64 {
  2340. return ErrIntOverflowUserResource
  2341. }
  2342. if iNdEx >= l {
  2343. return io.ErrUnexpectedEOF
  2344. }
  2345. b := dAtA[iNdEx]
  2346. iNdEx++
  2347. stringLen |= (uint64(b) & 0x7F) << shift
  2348. if b < 0x80 {
  2349. break
  2350. }
  2351. }
  2352. intStringLen := int(stringLen)
  2353. if intStringLen < 0 {
  2354. return ErrInvalidLengthUserResource
  2355. }
  2356. postIndex := iNdEx + intStringLen
  2357. if postIndex > l {
  2358. return io.ErrUnexpectedEOF
  2359. }
  2360. m.Url = string(dAtA[iNdEx:postIndex])
  2361. iNdEx = postIndex
  2362. case 6:
  2363. if wireType != 0 {
  2364. return fmt.Errorf("proto: wrong wireType = %d for field Weight", wireType)
  2365. }
  2366. m.Weight = 0
  2367. for shift := uint(0); ; shift += 7 {
  2368. if shift >= 64 {
  2369. return ErrIntOverflowUserResource
  2370. }
  2371. if iNdEx >= l {
  2372. return io.ErrUnexpectedEOF
  2373. }
  2374. b := dAtA[iNdEx]
  2375. iNdEx++
  2376. m.Weight |= (int32(b) & 0x7F) << shift
  2377. if b < 0x80 {
  2378. break
  2379. }
  2380. }
  2381. case 7:
  2382. if wireType != 2 {
  2383. return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType)
  2384. }
  2385. var stringLen uint64
  2386. for shift := uint(0); ; shift += 7 {
  2387. if shift >= 64 {
  2388. return ErrIntOverflowUserResource
  2389. }
  2390. if iNdEx >= l {
  2391. return io.ErrUnexpectedEOF
  2392. }
  2393. b := dAtA[iNdEx]
  2394. iNdEx++
  2395. stringLen |= (uint64(b) & 0x7F) << shift
  2396. if b < 0x80 {
  2397. break
  2398. }
  2399. }
  2400. intStringLen := int(stringLen)
  2401. if intStringLen < 0 {
  2402. return ErrInvalidLengthUserResource
  2403. }
  2404. postIndex := iNdEx + intStringLen
  2405. if postIndex > l {
  2406. return io.ErrUnexpectedEOF
  2407. }
  2408. m.Creator = string(dAtA[iNdEx:postIndex])
  2409. iNdEx = postIndex
  2410. case 8:
  2411. if wireType != 0 {
  2412. return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
  2413. }
  2414. m.Status = 0
  2415. for shift := uint(0); ; shift += 7 {
  2416. if shift >= 64 {
  2417. return ErrIntOverflowUserResource
  2418. }
  2419. if iNdEx >= l {
  2420. return io.ErrUnexpectedEOF
  2421. }
  2422. b := dAtA[iNdEx]
  2423. iNdEx++
  2424. m.Status |= (int32(b) & 0x7F) << shift
  2425. if b < 0x80 {
  2426. break
  2427. }
  2428. }
  2429. case 9:
  2430. if wireType != 2 {
  2431. return fmt.Errorf("proto: wrong wireType = %d for field Ctime", wireType)
  2432. }
  2433. var stringLen uint64
  2434. for shift := uint(0); ; shift += 7 {
  2435. if shift >= 64 {
  2436. return ErrIntOverflowUserResource
  2437. }
  2438. if iNdEx >= l {
  2439. return io.ErrUnexpectedEOF
  2440. }
  2441. b := dAtA[iNdEx]
  2442. iNdEx++
  2443. stringLen |= (uint64(b) & 0x7F) << shift
  2444. if b < 0x80 {
  2445. break
  2446. }
  2447. }
  2448. intStringLen := int(stringLen)
  2449. if intStringLen < 0 {
  2450. return ErrInvalidLengthUserResource
  2451. }
  2452. postIndex := iNdEx + intStringLen
  2453. if postIndex > l {
  2454. return io.ErrUnexpectedEOF
  2455. }
  2456. m.Ctime = string(dAtA[iNdEx:postIndex])
  2457. iNdEx = postIndex
  2458. case 10:
  2459. if wireType != 2 {
  2460. return fmt.Errorf("proto: wrong wireType = %d for field Mtime", wireType)
  2461. }
  2462. var stringLen uint64
  2463. for shift := uint(0); ; shift += 7 {
  2464. if shift >= 64 {
  2465. return ErrIntOverflowUserResource
  2466. }
  2467. if iNdEx >= l {
  2468. return io.ErrUnexpectedEOF
  2469. }
  2470. b := dAtA[iNdEx]
  2471. iNdEx++
  2472. stringLen |= (uint64(b) & 0x7F) << shift
  2473. if b < 0x80 {
  2474. break
  2475. }
  2476. }
  2477. intStringLen := int(stringLen)
  2478. if intStringLen < 0 {
  2479. return ErrInvalidLengthUserResource
  2480. }
  2481. postIndex := iNdEx + intStringLen
  2482. if postIndex > l {
  2483. return io.ErrUnexpectedEOF
  2484. }
  2485. m.Mtime = string(dAtA[iNdEx:postIndex])
  2486. iNdEx = postIndex
  2487. default:
  2488. iNdEx = preIndex
  2489. skippy, err := skipUserResource(dAtA[iNdEx:])
  2490. if err != nil {
  2491. return err
  2492. }
  2493. if skippy < 0 {
  2494. return ErrInvalidLengthUserResource
  2495. }
  2496. if (iNdEx + skippy) > l {
  2497. return io.ErrUnexpectedEOF
  2498. }
  2499. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  2500. iNdEx += skippy
  2501. }
  2502. }
  2503. if iNdEx > l {
  2504. return io.ErrUnexpectedEOF
  2505. }
  2506. return nil
  2507. }
  2508. func (m *UserResourceSetStatusReq) Unmarshal(dAtA []byte) error {
  2509. l := len(dAtA)
  2510. iNdEx := 0
  2511. for iNdEx < l {
  2512. preIndex := iNdEx
  2513. var wire uint64
  2514. for shift := uint(0); ; shift += 7 {
  2515. if shift >= 64 {
  2516. return ErrIntOverflowUserResource
  2517. }
  2518. if iNdEx >= l {
  2519. return io.ErrUnexpectedEOF
  2520. }
  2521. b := dAtA[iNdEx]
  2522. iNdEx++
  2523. wire |= (uint64(b) & 0x7F) << shift
  2524. if b < 0x80 {
  2525. break
  2526. }
  2527. }
  2528. fieldNum := int32(wire >> 3)
  2529. wireType := int(wire & 0x7)
  2530. if wireType == 4 {
  2531. return fmt.Errorf("proto: UserResourceSetStatusReq: wiretype end group for non-group")
  2532. }
  2533. if fieldNum <= 0 {
  2534. return fmt.Errorf("proto: UserResourceSetStatusReq: illegal tag %d (wire type %d)", fieldNum, wire)
  2535. }
  2536. switch fieldNum {
  2537. case 1:
  2538. if wireType != 0 {
  2539. return fmt.Errorf("proto: wrong wireType = %d for field ResType", wireType)
  2540. }
  2541. m.ResType = 0
  2542. for shift := uint(0); ; shift += 7 {
  2543. if shift >= 64 {
  2544. return ErrIntOverflowUserResource
  2545. }
  2546. if iNdEx >= l {
  2547. return io.ErrUnexpectedEOF
  2548. }
  2549. b := dAtA[iNdEx]
  2550. iNdEx++
  2551. m.ResType |= (int32(b) & 0x7F) << shift
  2552. if b < 0x80 {
  2553. break
  2554. }
  2555. }
  2556. case 2:
  2557. if wireType != 0 {
  2558. return fmt.Errorf("proto: wrong wireType = %d for field CustomId", wireType)
  2559. }
  2560. m.CustomId = 0
  2561. for shift := uint(0); ; shift += 7 {
  2562. if shift >= 64 {
  2563. return ErrIntOverflowUserResource
  2564. }
  2565. if iNdEx >= l {
  2566. return io.ErrUnexpectedEOF
  2567. }
  2568. b := dAtA[iNdEx]
  2569. iNdEx++
  2570. m.CustomId |= (int32(b) & 0x7F) << shift
  2571. if b < 0x80 {
  2572. break
  2573. }
  2574. }
  2575. case 3:
  2576. if wireType != 0 {
  2577. return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
  2578. }
  2579. m.Status = 0
  2580. for shift := uint(0); ; shift += 7 {
  2581. if shift >= 64 {
  2582. return ErrIntOverflowUserResource
  2583. }
  2584. if iNdEx >= l {
  2585. return io.ErrUnexpectedEOF
  2586. }
  2587. b := dAtA[iNdEx]
  2588. iNdEx++
  2589. m.Status |= (int32(b) & 0x7F) << shift
  2590. if b < 0x80 {
  2591. break
  2592. }
  2593. }
  2594. default:
  2595. iNdEx = preIndex
  2596. skippy, err := skipUserResource(dAtA[iNdEx:])
  2597. if err != nil {
  2598. return err
  2599. }
  2600. if skippy < 0 {
  2601. return ErrInvalidLengthUserResource
  2602. }
  2603. if (iNdEx + skippy) > l {
  2604. return io.ErrUnexpectedEOF
  2605. }
  2606. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  2607. iNdEx += skippy
  2608. }
  2609. }
  2610. if iNdEx > l {
  2611. return io.ErrUnexpectedEOF
  2612. }
  2613. return nil
  2614. }
  2615. func (m *UserResourceSetStatusResp) Unmarshal(dAtA []byte) error {
  2616. l := len(dAtA)
  2617. iNdEx := 0
  2618. for iNdEx < l {
  2619. preIndex := iNdEx
  2620. var wire uint64
  2621. for shift := uint(0); ; shift += 7 {
  2622. if shift >= 64 {
  2623. return ErrIntOverflowUserResource
  2624. }
  2625. if iNdEx >= l {
  2626. return io.ErrUnexpectedEOF
  2627. }
  2628. b := dAtA[iNdEx]
  2629. iNdEx++
  2630. wire |= (uint64(b) & 0x7F) << shift
  2631. if b < 0x80 {
  2632. break
  2633. }
  2634. }
  2635. fieldNum := int32(wire >> 3)
  2636. wireType := int(wire & 0x7)
  2637. if wireType == 4 {
  2638. return fmt.Errorf("proto: UserResourceSetStatusResp: wiretype end group for non-group")
  2639. }
  2640. if fieldNum <= 0 {
  2641. return fmt.Errorf("proto: UserResourceSetStatusResp: illegal tag %d (wire type %d)", fieldNum, wire)
  2642. }
  2643. switch fieldNum {
  2644. default:
  2645. iNdEx = preIndex
  2646. skippy, err := skipUserResource(dAtA[iNdEx:])
  2647. if err != nil {
  2648. return err
  2649. }
  2650. if skippy < 0 {
  2651. return ErrInvalidLengthUserResource
  2652. }
  2653. if (iNdEx + skippy) > l {
  2654. return io.ErrUnexpectedEOF
  2655. }
  2656. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  2657. iNdEx += skippy
  2658. }
  2659. }
  2660. if iNdEx > l {
  2661. return io.ErrUnexpectedEOF
  2662. }
  2663. return nil
  2664. }
  2665. func (m *UserResourceGetSingleReq) Unmarshal(dAtA []byte) error {
  2666. l := len(dAtA)
  2667. iNdEx := 0
  2668. for iNdEx < l {
  2669. preIndex := iNdEx
  2670. var wire uint64
  2671. for shift := uint(0); ; shift += 7 {
  2672. if shift >= 64 {
  2673. return ErrIntOverflowUserResource
  2674. }
  2675. if iNdEx >= l {
  2676. return io.ErrUnexpectedEOF
  2677. }
  2678. b := dAtA[iNdEx]
  2679. iNdEx++
  2680. wire |= (uint64(b) & 0x7F) << shift
  2681. if b < 0x80 {
  2682. break
  2683. }
  2684. }
  2685. fieldNum := int32(wire >> 3)
  2686. wireType := int(wire & 0x7)
  2687. if wireType == 4 {
  2688. return fmt.Errorf("proto: UserResourceGetSingleReq: wiretype end group for non-group")
  2689. }
  2690. if fieldNum <= 0 {
  2691. return fmt.Errorf("proto: UserResourceGetSingleReq: illegal tag %d (wire type %d)", fieldNum, wire)
  2692. }
  2693. switch fieldNum {
  2694. case 1:
  2695. if wireType != 0 {
  2696. return fmt.Errorf("proto: wrong wireType = %d for field ResType", wireType)
  2697. }
  2698. m.ResType = 0
  2699. for shift := uint(0); ; shift += 7 {
  2700. if shift >= 64 {
  2701. return ErrIntOverflowUserResource
  2702. }
  2703. if iNdEx >= l {
  2704. return io.ErrUnexpectedEOF
  2705. }
  2706. b := dAtA[iNdEx]
  2707. iNdEx++
  2708. m.ResType |= (int32(b) & 0x7F) << shift
  2709. if b < 0x80 {
  2710. break
  2711. }
  2712. }
  2713. case 2:
  2714. if wireType != 0 {
  2715. return fmt.Errorf("proto: wrong wireType = %d for field CustomId", wireType)
  2716. }
  2717. m.CustomId = 0
  2718. for shift := uint(0); ; shift += 7 {
  2719. if shift >= 64 {
  2720. return ErrIntOverflowUserResource
  2721. }
  2722. if iNdEx >= l {
  2723. return io.ErrUnexpectedEOF
  2724. }
  2725. b := dAtA[iNdEx]
  2726. iNdEx++
  2727. m.CustomId |= (int32(b) & 0x7F) << shift
  2728. if b < 0x80 {
  2729. break
  2730. }
  2731. }
  2732. default:
  2733. iNdEx = preIndex
  2734. skippy, err := skipUserResource(dAtA[iNdEx:])
  2735. if err != nil {
  2736. return err
  2737. }
  2738. if skippy < 0 {
  2739. return ErrInvalidLengthUserResource
  2740. }
  2741. if (iNdEx + skippy) > l {
  2742. return io.ErrUnexpectedEOF
  2743. }
  2744. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  2745. iNdEx += skippy
  2746. }
  2747. }
  2748. if iNdEx > l {
  2749. return io.ErrUnexpectedEOF
  2750. }
  2751. return nil
  2752. }
  2753. func (m *UserResourceGetSingleResp) Unmarshal(dAtA []byte) error {
  2754. l := len(dAtA)
  2755. iNdEx := 0
  2756. for iNdEx < l {
  2757. preIndex := iNdEx
  2758. var wire uint64
  2759. for shift := uint(0); ; shift += 7 {
  2760. if shift >= 64 {
  2761. return ErrIntOverflowUserResource
  2762. }
  2763. if iNdEx >= l {
  2764. return io.ErrUnexpectedEOF
  2765. }
  2766. b := dAtA[iNdEx]
  2767. iNdEx++
  2768. wire |= (uint64(b) & 0x7F) << shift
  2769. if b < 0x80 {
  2770. break
  2771. }
  2772. }
  2773. fieldNum := int32(wire >> 3)
  2774. wireType := int(wire & 0x7)
  2775. if wireType == 4 {
  2776. return fmt.Errorf("proto: UserResourceGetSingleResp: wiretype end group for non-group")
  2777. }
  2778. if fieldNum <= 0 {
  2779. return fmt.Errorf("proto: UserResourceGetSingleResp: illegal tag %d (wire type %d)", fieldNum, wire)
  2780. }
  2781. switch fieldNum {
  2782. case 1:
  2783. if wireType != 0 {
  2784. return fmt.Errorf("proto: wrong wireType = %d for field Id", wireType)
  2785. }
  2786. m.Id = 0
  2787. for shift := uint(0); ; shift += 7 {
  2788. if shift >= 64 {
  2789. return ErrIntOverflowUserResource
  2790. }
  2791. if iNdEx >= l {
  2792. return io.ErrUnexpectedEOF
  2793. }
  2794. b := dAtA[iNdEx]
  2795. iNdEx++
  2796. m.Id |= (int32(b) & 0x7F) << shift
  2797. if b < 0x80 {
  2798. break
  2799. }
  2800. }
  2801. case 2:
  2802. if wireType != 0 {
  2803. return fmt.Errorf("proto: wrong wireType = %d for field ResType", wireType)
  2804. }
  2805. m.ResType = 0
  2806. for shift := uint(0); ; shift += 7 {
  2807. if shift >= 64 {
  2808. return ErrIntOverflowUserResource
  2809. }
  2810. if iNdEx >= l {
  2811. return io.ErrUnexpectedEOF
  2812. }
  2813. b := dAtA[iNdEx]
  2814. iNdEx++
  2815. m.ResType |= (int32(b) & 0x7F) << shift
  2816. if b < 0x80 {
  2817. break
  2818. }
  2819. }
  2820. case 3:
  2821. if wireType != 0 {
  2822. return fmt.Errorf("proto: wrong wireType = %d for field CustomId", wireType)
  2823. }
  2824. m.CustomId = 0
  2825. for shift := uint(0); ; shift += 7 {
  2826. if shift >= 64 {
  2827. return ErrIntOverflowUserResource
  2828. }
  2829. if iNdEx >= l {
  2830. return io.ErrUnexpectedEOF
  2831. }
  2832. b := dAtA[iNdEx]
  2833. iNdEx++
  2834. m.CustomId |= (int32(b) & 0x7F) << shift
  2835. if b < 0x80 {
  2836. break
  2837. }
  2838. }
  2839. case 4:
  2840. if wireType != 2 {
  2841. return fmt.Errorf("proto: wrong wireType = %d for field Title", wireType)
  2842. }
  2843. var stringLen uint64
  2844. for shift := uint(0); ; shift += 7 {
  2845. if shift >= 64 {
  2846. return ErrIntOverflowUserResource
  2847. }
  2848. if iNdEx >= l {
  2849. return io.ErrUnexpectedEOF
  2850. }
  2851. b := dAtA[iNdEx]
  2852. iNdEx++
  2853. stringLen |= (uint64(b) & 0x7F) << shift
  2854. if b < 0x80 {
  2855. break
  2856. }
  2857. }
  2858. intStringLen := int(stringLen)
  2859. if intStringLen < 0 {
  2860. return ErrInvalidLengthUserResource
  2861. }
  2862. postIndex := iNdEx + intStringLen
  2863. if postIndex > l {
  2864. return io.ErrUnexpectedEOF
  2865. }
  2866. m.Title = string(dAtA[iNdEx:postIndex])
  2867. iNdEx = postIndex
  2868. case 5:
  2869. if wireType != 2 {
  2870. return fmt.Errorf("proto: wrong wireType = %d for field Url", wireType)
  2871. }
  2872. var stringLen uint64
  2873. for shift := uint(0); ; shift += 7 {
  2874. if shift >= 64 {
  2875. return ErrIntOverflowUserResource
  2876. }
  2877. if iNdEx >= l {
  2878. return io.ErrUnexpectedEOF
  2879. }
  2880. b := dAtA[iNdEx]
  2881. iNdEx++
  2882. stringLen |= (uint64(b) & 0x7F) << shift
  2883. if b < 0x80 {
  2884. break
  2885. }
  2886. }
  2887. intStringLen := int(stringLen)
  2888. if intStringLen < 0 {
  2889. return ErrInvalidLengthUserResource
  2890. }
  2891. postIndex := iNdEx + intStringLen
  2892. if postIndex > l {
  2893. return io.ErrUnexpectedEOF
  2894. }
  2895. m.Url = string(dAtA[iNdEx:postIndex])
  2896. iNdEx = postIndex
  2897. case 6:
  2898. if wireType != 0 {
  2899. return fmt.Errorf("proto: wrong wireType = %d for field Weight", wireType)
  2900. }
  2901. m.Weight = 0
  2902. for shift := uint(0); ; shift += 7 {
  2903. if shift >= 64 {
  2904. return ErrIntOverflowUserResource
  2905. }
  2906. if iNdEx >= l {
  2907. return io.ErrUnexpectedEOF
  2908. }
  2909. b := dAtA[iNdEx]
  2910. iNdEx++
  2911. m.Weight |= (int32(b) & 0x7F) << shift
  2912. if b < 0x80 {
  2913. break
  2914. }
  2915. }
  2916. case 7:
  2917. if wireType != 2 {
  2918. return fmt.Errorf("proto: wrong wireType = %d for field Creator", wireType)
  2919. }
  2920. var stringLen uint64
  2921. for shift := uint(0); ; shift += 7 {
  2922. if shift >= 64 {
  2923. return ErrIntOverflowUserResource
  2924. }
  2925. if iNdEx >= l {
  2926. return io.ErrUnexpectedEOF
  2927. }
  2928. b := dAtA[iNdEx]
  2929. iNdEx++
  2930. stringLen |= (uint64(b) & 0x7F) << shift
  2931. if b < 0x80 {
  2932. break
  2933. }
  2934. }
  2935. intStringLen := int(stringLen)
  2936. if intStringLen < 0 {
  2937. return ErrInvalidLengthUserResource
  2938. }
  2939. postIndex := iNdEx + intStringLen
  2940. if postIndex > l {
  2941. return io.ErrUnexpectedEOF
  2942. }
  2943. m.Creator = string(dAtA[iNdEx:postIndex])
  2944. iNdEx = postIndex
  2945. case 8:
  2946. if wireType != 0 {
  2947. return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType)
  2948. }
  2949. m.Status = 0
  2950. for shift := uint(0); ; shift += 7 {
  2951. if shift >= 64 {
  2952. return ErrIntOverflowUserResource
  2953. }
  2954. if iNdEx >= l {
  2955. return io.ErrUnexpectedEOF
  2956. }
  2957. b := dAtA[iNdEx]
  2958. iNdEx++
  2959. m.Status |= (int32(b) & 0x7F) << shift
  2960. if b < 0x80 {
  2961. break
  2962. }
  2963. }
  2964. case 9:
  2965. if wireType != 2 {
  2966. return fmt.Errorf("proto: wrong wireType = %d for field Ctime", wireType)
  2967. }
  2968. var stringLen uint64
  2969. for shift := uint(0); ; shift += 7 {
  2970. if shift >= 64 {
  2971. return ErrIntOverflowUserResource
  2972. }
  2973. if iNdEx >= l {
  2974. return io.ErrUnexpectedEOF
  2975. }
  2976. b := dAtA[iNdEx]
  2977. iNdEx++
  2978. stringLen |= (uint64(b) & 0x7F) << shift
  2979. if b < 0x80 {
  2980. break
  2981. }
  2982. }
  2983. intStringLen := int(stringLen)
  2984. if intStringLen < 0 {
  2985. return ErrInvalidLengthUserResource
  2986. }
  2987. postIndex := iNdEx + intStringLen
  2988. if postIndex > l {
  2989. return io.ErrUnexpectedEOF
  2990. }
  2991. m.Ctime = string(dAtA[iNdEx:postIndex])
  2992. iNdEx = postIndex
  2993. case 10:
  2994. if wireType != 2 {
  2995. return fmt.Errorf("proto: wrong wireType = %d for field Mtime", wireType)
  2996. }
  2997. var stringLen uint64
  2998. for shift := uint(0); ; shift += 7 {
  2999. if shift >= 64 {
  3000. return ErrIntOverflowUserResource
  3001. }
  3002. if iNdEx >= l {
  3003. return io.ErrUnexpectedEOF
  3004. }
  3005. b := dAtA[iNdEx]
  3006. iNdEx++
  3007. stringLen |= (uint64(b) & 0x7F) << shift
  3008. if b < 0x80 {
  3009. break
  3010. }
  3011. }
  3012. intStringLen := int(stringLen)
  3013. if intStringLen < 0 {
  3014. return ErrInvalidLengthUserResource
  3015. }
  3016. postIndex := iNdEx + intStringLen
  3017. if postIndex > l {
  3018. return io.ErrUnexpectedEOF
  3019. }
  3020. m.Mtime = string(dAtA[iNdEx:postIndex])
  3021. iNdEx = postIndex
  3022. default:
  3023. iNdEx = preIndex
  3024. skippy, err := skipUserResource(dAtA[iNdEx:])
  3025. if err != nil {
  3026. return err
  3027. }
  3028. if skippy < 0 {
  3029. return ErrInvalidLengthUserResource
  3030. }
  3031. if (iNdEx + skippy) > l {
  3032. return io.ErrUnexpectedEOF
  3033. }
  3034. m.XXX_unrecognized = append(m.XXX_unrecognized, dAtA[iNdEx:iNdEx+skippy]...)
  3035. iNdEx += skippy
  3036. }
  3037. }
  3038. if iNdEx > l {
  3039. return io.ErrUnexpectedEOF
  3040. }
  3041. return nil
  3042. }
  3043. func skipUserResource(dAtA []byte) (n int, err error) {
  3044. l := len(dAtA)
  3045. iNdEx := 0
  3046. for iNdEx < l {
  3047. var wire uint64
  3048. for shift := uint(0); ; shift += 7 {
  3049. if shift >= 64 {
  3050. return 0, ErrIntOverflowUserResource
  3051. }
  3052. if iNdEx >= l {
  3053. return 0, io.ErrUnexpectedEOF
  3054. }
  3055. b := dAtA[iNdEx]
  3056. iNdEx++
  3057. wire |= (uint64(b) & 0x7F) << shift
  3058. if b < 0x80 {
  3059. break
  3060. }
  3061. }
  3062. wireType := int(wire & 0x7)
  3063. switch wireType {
  3064. case 0:
  3065. for shift := uint(0); ; shift += 7 {
  3066. if shift >= 64 {
  3067. return 0, ErrIntOverflowUserResource
  3068. }
  3069. if iNdEx >= l {
  3070. return 0, io.ErrUnexpectedEOF
  3071. }
  3072. iNdEx++
  3073. if dAtA[iNdEx-1] < 0x80 {
  3074. break
  3075. }
  3076. }
  3077. return iNdEx, nil
  3078. case 1:
  3079. iNdEx += 8
  3080. return iNdEx, nil
  3081. case 2:
  3082. var length int
  3083. for shift := uint(0); ; shift += 7 {
  3084. if shift >= 64 {
  3085. return 0, ErrIntOverflowUserResource
  3086. }
  3087. if iNdEx >= l {
  3088. return 0, io.ErrUnexpectedEOF
  3089. }
  3090. b := dAtA[iNdEx]
  3091. iNdEx++
  3092. length |= (int(b) & 0x7F) << shift
  3093. if b < 0x80 {
  3094. break
  3095. }
  3096. }
  3097. iNdEx += length
  3098. if length < 0 {
  3099. return 0, ErrInvalidLengthUserResource
  3100. }
  3101. return iNdEx, nil
  3102. case 3:
  3103. for {
  3104. var innerWire uint64
  3105. var start int = iNdEx
  3106. for shift := uint(0); ; shift += 7 {
  3107. if shift >= 64 {
  3108. return 0, ErrIntOverflowUserResource
  3109. }
  3110. if iNdEx >= l {
  3111. return 0, io.ErrUnexpectedEOF
  3112. }
  3113. b := dAtA[iNdEx]
  3114. iNdEx++
  3115. innerWire |= (uint64(b) & 0x7F) << shift
  3116. if b < 0x80 {
  3117. break
  3118. }
  3119. }
  3120. innerWireType := int(innerWire & 0x7)
  3121. if innerWireType == 4 {
  3122. break
  3123. }
  3124. next, err := skipUserResource(dAtA[start:])
  3125. if err != nil {
  3126. return 0, err
  3127. }
  3128. iNdEx = start + next
  3129. }
  3130. return iNdEx, nil
  3131. case 4:
  3132. return iNdEx, nil
  3133. case 5:
  3134. iNdEx += 4
  3135. return iNdEx, nil
  3136. default:
  3137. return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
  3138. }
  3139. }
  3140. panic("unreachable")
  3141. }
  3142. var (
  3143. ErrInvalidLengthUserResource = fmt.Errorf("proto: negative length found during unmarshaling")
  3144. ErrIntOverflowUserResource = fmt.Errorf("proto: integer overflow")
  3145. )
  3146. func init() { proto.RegisterFile("user_resource.proto", fileDescriptor_user_resource_4bd0130d4f3d3c5a) }
  3147. var fileDescriptor_user_resource_4bd0130d4f3d3c5a = []byte{
  3148. // 854 bytes of a gzipped FileDescriptorProto
  3149. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0xe3, 0x44,
  3150. 0x14, 0x97, 0xed, 0xfc, 0x9d, 0x74, 0x77, 0xbb, 0xb3, 0xab, 0x95, 0x37, 0x48, 0x99, 0xe0, 0xdd,
  3151. 0xb6, 0x01, 0x16, 0x57, 0x0d, 0x9c, 0x2a, 0x55, 0x82, 0xa0, 0x0a, 0x81, 0x38, 0x20, 0xa7, 0x80,
  3152. 0xe0, 0x12, 0xb9, 0xf1, 0xd4, 0x1d, 0xc9, 0x89, 0x5d, 0xcf, 0x38, 0xa8, 0x7c, 0x0f, 0x3e, 0x02,
  3153. 0x12, 0x57, 0xbe, 0x05, 0x12, 0x17, 0x3e, 0xc1, 0xa8, 0xaa, 0xe0, 0xe2, 0xa3, 0x25, 0xee, 0xc8,
  3154. 0x33, 0xfe, 0x97, 0x36, 0x21, 0x45, 0xf4, 0xd0, 0x03, 0x17, 0xcf, 0xcc, 0xef, 0xfd, 0x99, 0x37,
  3155. 0xef, 0xf7, 0xe6, 0x8d, 0xc1, 0xb3, 0x88, 0xe2, 0x70, 0x12, 0x62, 0xea, 0x47, 0xe1, 0x14, 0x9b,
  3156. 0x41, 0xe8, 0x33, 0x1f, 0x3e, 0xf5, 0xc8, 0x02, 0x9b, 0xe9, 0xc7, 0x76, 0x66, 0x64, 0x6e, 0x2e,
  3157. 0x86, 0xdd, 0xf7, 0x5d, 0xc2, 0xce, 0xa3, 0x53, 0x73, 0xea, 0xcf, 0xf6, 0x5d, 0xdf, 0xf5, 0xf7,
  3158. 0x85, 0xe6, 0x69, 0x74, 0x26, 0x56, 0x62, 0x21, 0x66, 0xd2, 0x83, 0xf1, 0x9b, 0x0a, 0xe0, 0x57,
  3159. 0x14, 0x87, 0x56, 0xe6, 0xf8, 0x63, 0xc7, 0xb1, 0xf0, 0x05, 0x1c, 0x81, 0x56, 0x88, 0xe9, 0x84,
  3160. 0x5d, 0x06, 0x58, 0x57, 0xfa, 0xca, 0xa0, 0x3e, 0xda, 0x4b, 0x38, 0x7a, 0x75, 0xe6, 0x87, 0xb3,
  3161. 0x43, 0x23, 0x97, 0x18, 0xfd, 0x85, 0xed, 0x11, 0xc7, 0x66, 0x38, 0xc5, 0x2e, 0x22, 0x12, 0x62,
  3162. 0xc7, 0xb0, 0x9a, 0x21, 0xa6, 0x27, 0x97, 0x01, 0x86, 0x87, 0xa0, 0xce, 0x08, 0xf3, 0xb0, 0xae,
  3163. 0xf6, 0x95, 0x41, 0x7b, 0xf4, 0x3a, 0xe1, 0xa8, 0x2f, 0x1d, 0x08, 0x78, 0xb5, 0xb5, 0x34, 0x81,
  3164. 0x1f, 0x02, 0x2d, 0x0a, 0x3d, 0x5d, 0x13, 0x96, 0x46, 0xc2, 0x51, 0x4f, 0x5a, 0x46, 0xa1, 0xb7,
  3165. 0xda, 0x2e, 0x55, 0x87, 0x47, 0xa0, 0xf1, 0x3d, 0x26, 0xee, 0x39, 0xd3, 0x6b, 0x22, 0xe6, 0x9d,
  3166. 0x84, 0xa3, 0xb7, 0xa5, 0xa1, 0xc4, 0x57, 0xdb, 0x66, 0x46, 0xf0, 0x23, 0xd0, 0x9c, 0x86, 0xd8,
  3167. 0x66, 0x7e, 0xa8, 0xd7, 0xc5, 0xc6, 0xbb, 0x09, 0x47, 0x86, 0xb4, 0xcf, 0x04, 0x6b, 0x8e, 0x9c,
  3168. 0x4b, 0xbf, 0x05, 0xcf, 0x6e, 0x25, 0x93, 0x06, 0xf0, 0x05, 0x50, 0x89, 0x93, 0xe5, 0xb1, 0x11,
  3169. 0x73, 0xa4, 0x12, 0xc7, 0x52, 0x89, 0x03, 0xdf, 0x05, 0xed, 0x69, 0x44, 0x99, 0x3f, 0x9b, 0x10,
  3170. 0x47, 0x9c, 0xb5, 0x3e, 0x7a, 0x14, 0x73, 0x54, 0x82, 0x56, 0x4b, 0x4e, 0x3f, 0x73, 0x8c, 0x1f,
  3171. 0xd5, 0x65, 0xdf, 0xc7, 0x0e, 0x61, 0xf7, 0xc5, 0xd4, 0x71, 0x35, 0x0e, 0x55, 0x38, 0x19, 0x24,
  3172. 0x1c, 0xbd, 0xce, 0x8e, 0x9e, 0x8b, 0x56, 0x7b, 0x29, 0x42, 0x84, 0xbb, 0x39, 0xe1, 0x92, 0xb6,
  3173. 0xed, 0x84, 0xa3, 0xad, 0x2a, 0xe1, 0x39, 0xb9, 0x7d, 0x49, 0x6e, 0x4d, 0x68, 0x3d, 0x4e, 0x38,
  3174. 0x02, 0x25, 0xb9, 0x92, 0xc8, 0x77, 0x0a, 0x22, 0xeb, 0x22, 0x9a, 0xa7, 0x09, 0x47, 0x8f, 0x96,
  3175. 0x88, 0xcc, 0x49, 0x33, 0x5e, 0x80, 0xe7, 0xb7, 0xd3, 0x42, 0x03, 0xe3, 0x17, 0x65, 0x39, 0x5f,
  3176. 0x5f, 0x10, 0x7a, 0x6f, 0xf9, 0x7a, 0x05, 0x6a, 0x81, 0xed, 0xe2, 0x2c, 0x55, 0x4f, 0x12, 0x8e,
  3177. 0x3a, 0xd2, 0x3e, 0x45, 0x0d, 0x4b, 0x08, 0xe1, 0x01, 0x68, 0xa7, 0xe3, 0x84, 0x92, 0x1f, 0x70,
  3178. 0x46, 0xee, 0xf3, 0x84, 0xa3, 0xed, 0x52, 0x53, 0x88, 0x0c, 0xab, 0x95, 0xce, 0xc7, 0xe9, 0xf4,
  3179. 0xe7, 0xda, 0xf2, 0x61, 0x64, 0xcc, 0x34, 0x80, 0x07, 0xa0, 0x33, 0x8d, 0xc2, 0x10, 0xcf, 0xd9,
  3180. 0x97, 0xe9, 0xbe, 0x32, 0xee, 0x27, 0x31, 0x47, 0x55, 0xd8, 0xaa, 0x2e, 0xa0, 0x09, 0x00, 0xf3,
  3181. 0x99, 0xed, 0x7d, 0xe2, 0x47, 0x73, 0x96, 0x45, 0xfa, 0x38, 0xe6, 0xa8, 0x82, 0x5a, 0x95, 0x39,
  3182. 0xfc, 0x1c, 0xd4, 0x3c, 0x42, 0x99, 0xae, 0xf5, 0xb5, 0x41, 0x67, 0xf8, 0xc6, 0xbc, 0xd5, 0x59,
  3183. 0xcc, 0x55, 0x91, 0x99, 0xe9, 0x64, 0xd4, 0x8a, 0x39, 0x12, 0xd6, 0x96, 0xf8, 0x76, 0xaf, 0x54,
  3184. 0x50, 0x4b, 0x05, 0x6b, 0x0b, 0x7f, 0xaf, 0x42, 0x82, 0x0c, 0x6d, 0x2b, 0xe6, 0xa8, 0xc0, 0xca,
  3185. 0x4c, 0xff, 0x8b, 0x1b, 0x02, 0x51, 0x5e, 0x7e, 0xb2, 0xb0, 0xda, 0x31, 0x47, 0x12, 0xc8, 0xeb,
  3186. 0xee, 0xa5, 0xac, 0x3b, 0x79, 0xb7, 0x9b, 0x31, 0x47, 0xe9, 0x52, 0x16, 0x9c, 0x51, 0x14, 0x5c,
  3187. 0x43, 0x6c, 0x02, 0x62, 0x8e, 0x32, 0xa4, 0x68, 0x0f, 0x3b, 0x65, 0x7b, 0x68, 0x0a, 0x17, 0x9d,
  3188. 0x98, 0xa3, 0x1c, 0x2a, 0x7a, 0x40, 0xea, 0x8a, 0x32, 0x9b, 0x45, 0x54, 0x6f, 0x95, 0xae, 0x24,
  3189. 0x62, 0x65, 0x63, 0x1a, 0xea, 0x94, 0x91, 0x19, 0xd6, 0xdb, 0x65, 0xa8, 0x02, 0xb0, 0xe4, 0x90,
  3190. 0x2a, 0xcc, 0x84, 0x02, 0x28, 0x15, 0x66, 0x52, 0x41, 0x0c, 0xc6, 0x1f, 0x0a, 0xd0, 0xab, 0x84,
  3191. 0x8c, 0x31, 0x1b, 0xcb, 0x3d, 0x1e, 0x56, 0x4f, 0x38, 0x2a, 0xb2, 0xa1, 0xdd, 0x6c, 0xc9, 0x12,
  3192. 0x5f, 0xd3, 0x92, 0x33, 0xe1, 0x5b, 0xe0, 0xe5, 0x9a, 0x53, 0xd2, 0xc0, 0xf8, 0xe9, 0x46, 0x0e,
  3193. 0x3e, 0xc5, 0x6c, 0x4c, 0xe6, 0xae, 0x87, 0x1f, 0x56, 0x0e, 0x8c, 0xbf, 0xd4, 0xe5, 0x53, 0x54,
  3194. 0xe2, 0xfc, 0x87, 0xc7, 0xe1, 0xff, 0x3b, 0xf2, 0x1f, 0xef, 0xc8, 0xf0, 0x4f, 0x0d, 0x6c, 0x55,
  3195. 0xf3, 0x0e, 0x4f, 0x80, 0x66, 0x3b, 0x0e, 0xdc, 0xd9, 0xd0, 0xdc, 0xe4, 0x3f, 0x50, 0x77, 0xf7,
  3196. 0x2e, 0x6a, 0x34, 0x80, 0xdf, 0x80, 0x1a, 0x76, 0x08, 0x83, 0x9b, 0xf4, 0xb3, 0x17, 0xbb, 0xbb,
  3197. 0x77, 0x27, 0x3d, 0x1a, 0xc0, 0xaf, 0x81, 0xe6, 0xe2, 0xcd, 0x7e, 0xb3, 0x97, 0x6d, 0xa3, 0xdf,
  3198. 0xe2, 0x35, 0x39, 0x03, 0x6d, 0x9a, 0x5f, 0x24, 0xf8, 0xde, 0x06, 0xab, 0x6a, 0x63, 0xe9, 0xbe,
  3199. 0xb9, 0xbb, 0xb2, 0xdc, 0xc7, 0xcd, 0x4b, 0x7d, 0xe3, 0x3e, 0xd5, 0xcb, 0xbb, 0x71, 0x9f, 0xa5,
  3200. 0x1b, 0x34, 0xda, 0xfe, 0xf5, 0xba, 0xa7, 0xfc, 0x7e, 0xdd, 0x53, 0xae, 0xae, 0x7b, 0xca, 0x77,
  3201. 0xea, 0x62, 0x78, 0xda, 0x10, 0x3f, 0xb7, 0x1f, 0xfc, 0x1d, 0x00, 0x00, 0xff, 0xff, 0x4a, 0xb5,
  3202. 0x83, 0xfe, 0x35, 0x0b, 0x00, 0x00,
  3203. }