messages.js 38 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315
  1. "use strict";
  2. Object.defineProperty(exports, "__esModule", { value: true });
  3. exports.Nfsv4OpenDowngradeRequest = exports.Nfsv4OpenConfirmResponse = exports.Nfsv4OpenConfirmResOk = exports.Nfsv4OpenConfirmRequest = exports.Nfsv4OpenattrResponse = exports.Nfsv4OpenattrRequest = exports.Nfsv4OpenResponse = exports.Nfsv4OpenResOk = exports.Nfsv4OpenRequest = exports.Nfsv4NverifyResponse = exports.Nfsv4NverifyRequest = exports.Nfsv4LookuppResponse = exports.Nfsv4LookuppRequest = exports.Nfsv4LookupResponse = exports.Nfsv4LookupRequest = exports.Nfsv4LockuResponse = exports.Nfsv4LockuResOk = exports.Nfsv4LockuRequest = exports.Nfsv4LocktResponse = exports.Nfsv4LocktResDenied = exports.Nfsv4LocktRequest = exports.Nfsv4LockResponse = exports.Nfsv4LockResDenied = exports.Nfsv4LockResOk = exports.Nfsv4LockRequest = exports.Nfsv4LinkResponse = exports.Nfsv4LinkResOk = exports.Nfsv4LinkRequest = exports.Nfsv4GetfhResponse = exports.Nfsv4GetfhResOk = exports.Nfsv4GetfhRequest = exports.Nfsv4GetattrResponse = exports.Nfsv4GetattrResOk = exports.Nfsv4GetattrRequest = exports.Nfsv4DelegreturnResponse = exports.Nfsv4DelegreturnRequest = exports.Nfsv4DelegpurgeResponse = exports.Nfsv4DelegpurgeRequest = exports.Nfsv4CreateResponse = exports.Nfsv4CreateResOk = exports.Nfsv4CreateRequest = exports.Nfsv4CommitResponse = exports.Nfsv4CommitResOk = exports.Nfsv4CommitRequest = exports.Nfsv4CloseResponse = exports.Nfsv4CloseResOk = exports.Nfsv4CloseRequest = exports.Nfsv4AccessResponse = exports.Nfsv4AccessResOk = exports.Nfsv4AccessRequest = void 0;
  4. exports.Nfsv4CompoundRequest = exports.Nfsv4IllegalResponse = exports.Nfsv4IllegalRequest = exports.Nfsv4ReleaseLockOwnerResponse = exports.Nfsv4ReleaseLockOwnerRequest = exports.Nfsv4WriteResponse = exports.Nfsv4WriteResOk = exports.Nfsv4WriteRequest = exports.Nfsv4VerifyResponse = exports.Nfsv4VerifyRequest = exports.Nfsv4SetclientidConfirmResponse = exports.Nfsv4SetclientidConfirmRequest = exports.Nfsv4SetclientidResponse = exports.Nfsv4SetclientidResOk = exports.Nfsv4SetclientidRequest = exports.Nfsv4SetattrResponse = exports.Nfsv4SetattrResOk = exports.Nfsv4SetattrRequest = exports.Nfsv4SecinfoResponse = exports.Nfsv4SecinfoResOk = exports.Nfsv4SecinfoRequest = exports.Nfsv4SavefhResponse = exports.Nfsv4SavefhRequest = exports.Nfsv4RestorefhResponse = exports.Nfsv4RestorefhRequest = exports.Nfsv4RenewResponse = exports.Nfsv4RenewRequest = exports.Nfsv4RenameResponse = exports.Nfsv4RenameResOk = exports.Nfsv4RenameRequest = exports.Nfsv4RemoveResponse = exports.Nfsv4RemoveResOk = exports.Nfsv4RemoveRequest = exports.Nfsv4ReadlinkResponse = exports.Nfsv4ReadlinkResOk = exports.Nfsv4ReadlinkRequest = exports.Nfsv4ReaddirResponse = exports.Nfsv4ReaddirResOk = exports.Nfsv4ReaddirRequest = exports.Nfsv4ReadResponse = exports.Nfsv4ReadResOk = exports.Nfsv4ReadRequest = exports.Nfsv4PutrootfhResponse = exports.Nfsv4PutrootfhRequest = exports.Nfsv4PutpubfhResponse = exports.Nfsv4PutpubfhRequest = exports.Nfsv4PutfhResponse = exports.Nfsv4PutfhRequest = exports.Nfsv4OpenDowngradeResponse = exports.Nfsv4OpenDowngradeResOk = void 0;
  5. exports.Nfsv4CbCompoundResponse = exports.Nfsv4CbCompoundRequest = exports.Nfsv4CbIllegalResponse = exports.Nfsv4CbIllegalRequest = exports.Nfsv4CbRecallResponse = exports.Nfsv4CbRecallRequest = exports.Nfsv4CbGetattrResponse = exports.Nfsv4CbGetattrResOk = exports.Nfsv4CbGetattrRequest = exports.Nfsv4CompoundResponse = void 0;
  6. const tslib_1 = require("tslib");
  7. const structs = tslib_1.__importStar(require("./structs"));
  8. class Nfsv4AccessRequest {
  9. static decode(xdr) {
  10. const access = xdr.readUnsignedInt();
  11. return new Nfsv4AccessRequest(access);
  12. }
  13. constructor(access) {
  14. this.access = access;
  15. }
  16. encode(xdr) {
  17. xdr.writeUnsignedInt(3);
  18. xdr.writeUnsignedInt(this.access);
  19. }
  20. }
  21. exports.Nfsv4AccessRequest = Nfsv4AccessRequest;
  22. class Nfsv4AccessResOk {
  23. constructor(supported, access) {
  24. this.supported = supported;
  25. this.access = access;
  26. }
  27. encode(xdr) {
  28. xdr.writeUnsignedInt(this.supported);
  29. xdr.writeUnsignedInt(this.access);
  30. }
  31. }
  32. exports.Nfsv4AccessResOk = Nfsv4AccessResOk;
  33. class Nfsv4AccessResponse {
  34. constructor(status, resok) {
  35. this.status = status;
  36. this.resok = resok;
  37. }
  38. encode(xdr) {
  39. xdr.writeUnsignedInt(3);
  40. xdr.writeUnsignedInt(this.status);
  41. if (this.status === 0)
  42. this.resok?.encode(xdr);
  43. }
  44. }
  45. exports.Nfsv4AccessResponse = Nfsv4AccessResponse;
  46. class Nfsv4CloseRequest {
  47. static decode(xdr) {
  48. const seqid = xdr.readUnsignedInt();
  49. const openStateid = structs.Nfsv4Stateid.decode(xdr);
  50. return new Nfsv4CloseRequest(seqid, openStateid);
  51. }
  52. constructor(seqid, openStateid) {
  53. this.seqid = seqid;
  54. this.openStateid = openStateid;
  55. }
  56. encode(xdr) {
  57. xdr.writeUnsignedInt(4);
  58. xdr.writeUnsignedInt(this.seqid);
  59. this.openStateid.encode(xdr);
  60. }
  61. }
  62. exports.Nfsv4CloseRequest = Nfsv4CloseRequest;
  63. class Nfsv4CloseResOk {
  64. constructor(openStateid) {
  65. this.openStateid = openStateid;
  66. }
  67. encode(xdr) {
  68. this.openStateid.encode(xdr);
  69. }
  70. }
  71. exports.Nfsv4CloseResOk = Nfsv4CloseResOk;
  72. class Nfsv4CloseResponse {
  73. constructor(status, resok) {
  74. this.status = status;
  75. this.resok = resok;
  76. }
  77. encode(xdr) {
  78. xdr.writeUnsignedInt(4);
  79. xdr.writeUnsignedInt(this.status);
  80. if (this.status === 0)
  81. this.resok?.encode(xdr);
  82. }
  83. }
  84. exports.Nfsv4CloseResponse = Nfsv4CloseResponse;
  85. class Nfsv4CommitRequest {
  86. static decode(xdr) {
  87. const offset = xdr.readUnsignedHyper();
  88. const count = xdr.readUnsignedInt();
  89. return new Nfsv4CommitRequest(offset, count);
  90. }
  91. constructor(offset, count) {
  92. this.offset = offset;
  93. this.count = count;
  94. }
  95. encode(xdr) {
  96. xdr.writeUnsignedInt(5);
  97. xdr.writeUnsignedHyper(this.offset);
  98. xdr.writeUnsignedInt(this.count);
  99. }
  100. }
  101. exports.Nfsv4CommitRequest = Nfsv4CommitRequest;
  102. class Nfsv4CommitResOk {
  103. constructor(writeverf) {
  104. this.writeverf = writeverf;
  105. }
  106. encode(xdr) {
  107. this.writeverf.encode(xdr);
  108. }
  109. }
  110. exports.Nfsv4CommitResOk = Nfsv4CommitResOk;
  111. class Nfsv4CommitResponse {
  112. constructor(status, resok) {
  113. this.status = status;
  114. this.resok = resok;
  115. }
  116. encode(xdr) {
  117. xdr.writeUnsignedInt(5);
  118. xdr.writeUnsignedInt(this.status);
  119. if (this.status === 0)
  120. this.resok?.encode(xdr);
  121. }
  122. }
  123. exports.Nfsv4CommitResponse = Nfsv4CommitResponse;
  124. class Nfsv4CreateRequest {
  125. constructor(objtype, objname, createattrs) {
  126. this.objtype = objtype;
  127. this.objname = objname;
  128. this.createattrs = createattrs;
  129. }
  130. encode(xdr) {
  131. xdr.writeUnsignedInt(6);
  132. this.objtype.encode(xdr);
  133. xdr.writeStr(this.objname);
  134. this.createattrs.encode(xdr);
  135. }
  136. }
  137. exports.Nfsv4CreateRequest = Nfsv4CreateRequest;
  138. class Nfsv4CreateResOk {
  139. constructor(cinfo, attrset) {
  140. this.cinfo = cinfo;
  141. this.attrset = attrset;
  142. }
  143. encode(xdr) {
  144. this.cinfo.encode(xdr);
  145. this.attrset.encode(xdr);
  146. }
  147. }
  148. exports.Nfsv4CreateResOk = Nfsv4CreateResOk;
  149. class Nfsv4CreateResponse {
  150. constructor(status, resok) {
  151. this.status = status;
  152. this.resok = resok;
  153. }
  154. encode(xdr) {
  155. xdr.writeUnsignedInt(6);
  156. xdr.writeUnsignedInt(this.status);
  157. if (this.status === 0)
  158. this.resok?.encode(xdr);
  159. }
  160. }
  161. exports.Nfsv4CreateResponse = Nfsv4CreateResponse;
  162. class Nfsv4DelegpurgeRequest {
  163. static decode(xdr) {
  164. const clientid = xdr.readUnsignedHyper();
  165. return new Nfsv4DelegpurgeRequest(clientid);
  166. }
  167. constructor(clientid) {
  168. this.clientid = clientid;
  169. }
  170. encode(xdr) {
  171. xdr.writeUnsignedInt(7);
  172. xdr.writeUnsignedHyper(this.clientid);
  173. }
  174. }
  175. exports.Nfsv4DelegpurgeRequest = Nfsv4DelegpurgeRequest;
  176. class Nfsv4DelegpurgeResponse {
  177. constructor(status) {
  178. this.status = status;
  179. }
  180. encode(xdr) {
  181. xdr.writeUnsignedInt(7);
  182. xdr.writeUnsignedInt(this.status);
  183. }
  184. }
  185. exports.Nfsv4DelegpurgeResponse = Nfsv4DelegpurgeResponse;
  186. class Nfsv4DelegreturnRequest {
  187. static decode(xdr) {
  188. const delegStateid = structs.Nfsv4Stateid.decode(xdr);
  189. return new Nfsv4DelegreturnRequest(delegStateid);
  190. }
  191. constructor(delegStateid) {
  192. this.delegStateid = delegStateid;
  193. }
  194. encode(xdr) {
  195. xdr.writeUnsignedInt(8);
  196. this.delegStateid.encode(xdr);
  197. }
  198. }
  199. exports.Nfsv4DelegreturnRequest = Nfsv4DelegreturnRequest;
  200. class Nfsv4DelegreturnResponse {
  201. constructor(status) {
  202. this.status = status;
  203. }
  204. encode(xdr) {
  205. xdr.writeUnsignedInt(8);
  206. xdr.writeUnsignedInt(this.status);
  207. }
  208. }
  209. exports.Nfsv4DelegreturnResponse = Nfsv4DelegreturnResponse;
  210. class Nfsv4GetattrRequest {
  211. constructor(attrRequest) {
  212. this.attrRequest = attrRequest;
  213. }
  214. encode(xdr) {
  215. xdr.writeUnsignedInt(9);
  216. this.attrRequest.encode(xdr);
  217. }
  218. }
  219. exports.Nfsv4GetattrRequest = Nfsv4GetattrRequest;
  220. class Nfsv4GetattrResOk {
  221. constructor(objAttributes) {
  222. this.objAttributes = objAttributes;
  223. }
  224. encode(xdr) {
  225. this.objAttributes.encode(xdr);
  226. }
  227. }
  228. exports.Nfsv4GetattrResOk = Nfsv4GetattrResOk;
  229. class Nfsv4GetattrResponse {
  230. constructor(status, resok) {
  231. this.status = status;
  232. this.resok = resok;
  233. }
  234. encode(xdr) {
  235. xdr.writeUnsignedInt(9);
  236. xdr.writeUnsignedInt(this.status);
  237. if (this.status === 0)
  238. this.resok?.encode(xdr);
  239. }
  240. }
  241. exports.Nfsv4GetattrResponse = Nfsv4GetattrResponse;
  242. class Nfsv4GetfhRequest {
  243. encode(xdr) {
  244. xdr.writeUnsignedInt(10);
  245. }
  246. }
  247. exports.Nfsv4GetfhRequest = Nfsv4GetfhRequest;
  248. class Nfsv4GetfhResOk {
  249. constructor(object) {
  250. this.object = object;
  251. }
  252. encode(xdr) {
  253. this.object.encode(xdr);
  254. }
  255. }
  256. exports.Nfsv4GetfhResOk = Nfsv4GetfhResOk;
  257. class Nfsv4GetfhResponse {
  258. constructor(status, resok) {
  259. this.status = status;
  260. this.resok = resok;
  261. }
  262. encode(xdr) {
  263. xdr.writeUnsignedInt(10);
  264. xdr.writeUnsignedInt(this.status);
  265. if (this.status === 0)
  266. this.resok?.encode(xdr);
  267. }
  268. }
  269. exports.Nfsv4GetfhResponse = Nfsv4GetfhResponse;
  270. class Nfsv4LinkRequest {
  271. constructor(newname) {
  272. this.newname = newname;
  273. }
  274. encode(xdr) {
  275. xdr.writeUnsignedInt(11);
  276. xdr.writeStr(this.newname);
  277. }
  278. }
  279. exports.Nfsv4LinkRequest = Nfsv4LinkRequest;
  280. class Nfsv4LinkResOk {
  281. constructor(cinfo) {
  282. this.cinfo = cinfo;
  283. }
  284. encode(xdr) {
  285. this.cinfo.encode(xdr);
  286. }
  287. }
  288. exports.Nfsv4LinkResOk = Nfsv4LinkResOk;
  289. class Nfsv4LinkResponse {
  290. constructor(status, resok) {
  291. this.status = status;
  292. this.resok = resok;
  293. }
  294. encode(xdr) {
  295. xdr.writeUnsignedInt(11);
  296. xdr.writeUnsignedInt(this.status);
  297. if (this.status === 0)
  298. this.resok?.encode(xdr);
  299. }
  300. }
  301. exports.Nfsv4LinkResponse = Nfsv4LinkResponse;
  302. class Nfsv4LockRequest {
  303. constructor(locktype, reclaim, offset, length, locker) {
  304. this.locktype = locktype;
  305. this.reclaim = reclaim;
  306. this.offset = offset;
  307. this.length = length;
  308. this.locker = locker;
  309. }
  310. encode(xdr) {
  311. xdr.writeUnsignedInt(12);
  312. xdr.writeUnsignedInt(this.locktype);
  313. xdr.writeBoolean(this.reclaim);
  314. xdr.writeUnsignedHyper(this.offset);
  315. xdr.writeUnsignedHyper(this.length);
  316. this.locker.encode(xdr);
  317. }
  318. }
  319. exports.Nfsv4LockRequest = Nfsv4LockRequest;
  320. class Nfsv4LockResOk {
  321. constructor(lockStateid) {
  322. this.lockStateid = lockStateid;
  323. }
  324. encode(xdr) {
  325. this.lockStateid.encode(xdr);
  326. }
  327. }
  328. exports.Nfsv4LockResOk = Nfsv4LockResOk;
  329. class Nfsv4LockResDenied {
  330. constructor(offset, length, locktype, owner) {
  331. this.offset = offset;
  332. this.length = length;
  333. this.locktype = locktype;
  334. this.owner = owner;
  335. }
  336. encode(xdr) {
  337. xdr.writeUnsignedHyper(this.offset);
  338. xdr.writeUnsignedHyper(this.length);
  339. xdr.writeUnsignedInt(this.locktype);
  340. this.owner.encode(xdr);
  341. }
  342. }
  343. exports.Nfsv4LockResDenied = Nfsv4LockResDenied;
  344. class Nfsv4LockResponse {
  345. constructor(status, resok, denied) {
  346. this.status = status;
  347. this.resok = resok;
  348. this.denied = denied;
  349. }
  350. encode(xdr) {
  351. xdr.writeUnsignedInt(12);
  352. xdr.writeUnsignedInt(this.status);
  353. if (this.status === 0 && this.resok) {
  354. this.resok.encode(xdr);
  355. }
  356. else if (this.denied) {
  357. this.denied.encode(xdr);
  358. }
  359. }
  360. }
  361. exports.Nfsv4LockResponse = Nfsv4LockResponse;
  362. class Nfsv4LocktRequest {
  363. constructor(locktype, offset, length, owner) {
  364. this.locktype = locktype;
  365. this.offset = offset;
  366. this.length = length;
  367. this.owner = owner;
  368. }
  369. encode(xdr) {
  370. xdr.writeUnsignedInt(13);
  371. xdr.writeUnsignedInt(this.locktype);
  372. xdr.writeUnsignedHyper(this.offset);
  373. xdr.writeUnsignedHyper(this.length);
  374. this.owner.encode(xdr);
  375. }
  376. }
  377. exports.Nfsv4LocktRequest = Nfsv4LocktRequest;
  378. class Nfsv4LocktResDenied {
  379. constructor(offset, length, locktype, owner) {
  380. this.offset = offset;
  381. this.length = length;
  382. this.locktype = locktype;
  383. this.owner = owner;
  384. }
  385. encode(xdr) {
  386. xdr.writeUnsignedHyper(this.offset);
  387. xdr.writeUnsignedHyper(this.length);
  388. xdr.writeUnsignedInt(this.locktype);
  389. this.owner.encode(xdr);
  390. }
  391. }
  392. exports.Nfsv4LocktResDenied = Nfsv4LocktResDenied;
  393. class Nfsv4LocktResponse {
  394. constructor(status, denied) {
  395. this.status = status;
  396. this.denied = denied;
  397. }
  398. encode(xdr) {
  399. xdr.writeUnsignedInt(13);
  400. xdr.writeUnsignedInt(this.status);
  401. this.denied?.encode(xdr);
  402. }
  403. }
  404. exports.Nfsv4LocktResponse = Nfsv4LocktResponse;
  405. class Nfsv4LockuRequest {
  406. constructor(locktype, seqid, lockStateid, offset, length) {
  407. this.locktype = locktype;
  408. this.seqid = seqid;
  409. this.lockStateid = lockStateid;
  410. this.offset = offset;
  411. this.length = length;
  412. }
  413. encode(xdr) {
  414. xdr.writeUnsignedInt(14);
  415. xdr.writeUnsignedInt(this.locktype);
  416. xdr.writeUnsignedInt(this.seqid);
  417. this.lockStateid.encode(xdr);
  418. xdr.writeUnsignedHyper(this.offset);
  419. xdr.writeUnsignedHyper(this.length);
  420. }
  421. }
  422. exports.Nfsv4LockuRequest = Nfsv4LockuRequest;
  423. class Nfsv4LockuResOk {
  424. constructor(lockStateid) {
  425. this.lockStateid = lockStateid;
  426. }
  427. encode(xdr) {
  428. this.lockStateid.encode(xdr);
  429. }
  430. }
  431. exports.Nfsv4LockuResOk = Nfsv4LockuResOk;
  432. class Nfsv4LockuResponse {
  433. constructor(status, resok) {
  434. this.status = status;
  435. this.resok = resok;
  436. }
  437. encode(xdr) {
  438. xdr.writeUnsignedInt(14);
  439. xdr.writeUnsignedInt(this.status);
  440. if (this.status === 0)
  441. this.resok?.encode(xdr);
  442. }
  443. }
  444. exports.Nfsv4LockuResponse = Nfsv4LockuResponse;
  445. class Nfsv4LookupRequest {
  446. constructor(objname) {
  447. this.objname = objname;
  448. }
  449. encode(xdr) {
  450. xdr.writeUnsignedInt(15);
  451. xdr.writeStr(this.objname);
  452. }
  453. }
  454. exports.Nfsv4LookupRequest = Nfsv4LookupRequest;
  455. class Nfsv4LookupResponse {
  456. constructor(status) {
  457. this.status = status;
  458. }
  459. encode(xdr) {
  460. xdr.writeUnsignedInt(15);
  461. xdr.writeUnsignedInt(this.status);
  462. }
  463. }
  464. exports.Nfsv4LookupResponse = Nfsv4LookupResponse;
  465. class Nfsv4LookuppRequest {
  466. encode(xdr) {
  467. xdr.writeUnsignedInt(16);
  468. }
  469. }
  470. exports.Nfsv4LookuppRequest = Nfsv4LookuppRequest;
  471. class Nfsv4LookuppResponse {
  472. constructor(status) {
  473. this.status = status;
  474. }
  475. encode(xdr) {
  476. xdr.writeUnsignedInt(16);
  477. xdr.writeUnsignedInt(this.status);
  478. }
  479. }
  480. exports.Nfsv4LookuppResponse = Nfsv4LookuppResponse;
  481. class Nfsv4NverifyRequest {
  482. constructor(objAttributes) {
  483. this.objAttributes = objAttributes;
  484. }
  485. encode(xdr) {
  486. xdr.writeUnsignedInt(17);
  487. this.objAttributes.encode(xdr);
  488. }
  489. }
  490. exports.Nfsv4NverifyRequest = Nfsv4NverifyRequest;
  491. class Nfsv4NverifyResponse {
  492. constructor(status) {
  493. this.status = status;
  494. }
  495. encode(xdr) {
  496. xdr.writeUnsignedInt(17);
  497. xdr.writeUnsignedInt(this.status);
  498. }
  499. }
  500. exports.Nfsv4NverifyResponse = Nfsv4NverifyResponse;
  501. class Nfsv4OpenRequest {
  502. constructor(seqid, shareAccess, shareDeny, owner, openhow, claim) {
  503. this.seqid = seqid;
  504. this.shareAccess = shareAccess;
  505. this.shareDeny = shareDeny;
  506. this.owner = owner;
  507. this.openhow = openhow;
  508. this.claim = claim;
  509. }
  510. encode(xdr) {
  511. xdr.writeUnsignedInt(18);
  512. xdr.writeUnsignedInt(this.seqid);
  513. xdr.writeUnsignedInt(this.shareAccess);
  514. xdr.writeUnsignedInt(this.shareDeny);
  515. this.owner.encode(xdr);
  516. this.openhow.encode(xdr);
  517. this.claim.encode(xdr);
  518. }
  519. }
  520. exports.Nfsv4OpenRequest = Nfsv4OpenRequest;
  521. class Nfsv4OpenResOk {
  522. constructor(stateid, cinfo, rflags, attrset, delegation) {
  523. this.stateid = stateid;
  524. this.cinfo = cinfo;
  525. this.rflags = rflags;
  526. this.attrset = attrset;
  527. this.delegation = delegation;
  528. }
  529. encode(xdr) {
  530. this.stateid.encode(xdr);
  531. this.cinfo.encode(xdr);
  532. xdr.writeUnsignedInt(this.rflags);
  533. this.attrset.encode(xdr);
  534. this.delegation.encode(xdr);
  535. }
  536. }
  537. exports.Nfsv4OpenResOk = Nfsv4OpenResOk;
  538. class Nfsv4OpenResponse {
  539. constructor(status, resok) {
  540. this.status = status;
  541. this.resok = resok;
  542. }
  543. encode(xdr) {
  544. xdr.writeUnsignedInt(18);
  545. xdr.writeUnsignedInt(this.status);
  546. if (this.status === 0 && this.resok) {
  547. this.resok.encode(xdr);
  548. }
  549. }
  550. }
  551. exports.Nfsv4OpenResponse = Nfsv4OpenResponse;
  552. class Nfsv4OpenattrRequest {
  553. constructor(createdir) {
  554. this.createdir = createdir;
  555. }
  556. encode(xdr) {
  557. xdr.writeUnsignedInt(19);
  558. xdr.writeBoolean(this.createdir);
  559. }
  560. }
  561. exports.Nfsv4OpenattrRequest = Nfsv4OpenattrRequest;
  562. class Nfsv4OpenattrResponse {
  563. constructor(status) {
  564. this.status = status;
  565. }
  566. encode(xdr) {
  567. xdr.writeUnsignedInt(19);
  568. xdr.writeUnsignedInt(this.status);
  569. }
  570. }
  571. exports.Nfsv4OpenattrResponse = Nfsv4OpenattrResponse;
  572. class Nfsv4OpenConfirmRequest {
  573. constructor(openStateid, seqid) {
  574. this.openStateid = openStateid;
  575. this.seqid = seqid;
  576. }
  577. encode(xdr) {
  578. xdr.writeUnsignedInt(20);
  579. this.openStateid.encode(xdr);
  580. xdr.writeUnsignedInt(this.seqid);
  581. }
  582. }
  583. exports.Nfsv4OpenConfirmRequest = Nfsv4OpenConfirmRequest;
  584. class Nfsv4OpenConfirmResOk {
  585. constructor(openStateid) {
  586. this.openStateid = openStateid;
  587. }
  588. encode(xdr) {
  589. this.openStateid.encode(xdr);
  590. }
  591. }
  592. exports.Nfsv4OpenConfirmResOk = Nfsv4OpenConfirmResOk;
  593. class Nfsv4OpenConfirmResponse {
  594. constructor(status, resok) {
  595. this.status = status;
  596. this.resok = resok;
  597. }
  598. encode(xdr) {
  599. xdr.writeUnsignedInt(20);
  600. xdr.writeUnsignedInt(this.status);
  601. if (this.status === 0 && this.resok) {
  602. this.resok.encode(xdr);
  603. }
  604. }
  605. }
  606. exports.Nfsv4OpenConfirmResponse = Nfsv4OpenConfirmResponse;
  607. class Nfsv4OpenDowngradeRequest {
  608. constructor(openStateid, seqid, shareAccess, shareDeny) {
  609. this.openStateid = openStateid;
  610. this.seqid = seqid;
  611. this.shareAccess = shareAccess;
  612. this.shareDeny = shareDeny;
  613. }
  614. encode(xdr) {
  615. xdr.writeUnsignedInt(21);
  616. this.openStateid.encode(xdr);
  617. xdr.writeUnsignedInt(this.seqid);
  618. xdr.writeUnsignedInt(this.shareAccess);
  619. xdr.writeUnsignedInt(this.shareDeny);
  620. }
  621. }
  622. exports.Nfsv4OpenDowngradeRequest = Nfsv4OpenDowngradeRequest;
  623. class Nfsv4OpenDowngradeResOk {
  624. constructor(openStateid) {
  625. this.openStateid = openStateid;
  626. }
  627. encode(xdr) {
  628. this.openStateid.encode(xdr);
  629. }
  630. }
  631. exports.Nfsv4OpenDowngradeResOk = Nfsv4OpenDowngradeResOk;
  632. class Nfsv4OpenDowngradeResponse {
  633. constructor(status, resok) {
  634. this.status = status;
  635. this.resok = resok;
  636. }
  637. encode(xdr) {
  638. xdr.writeUnsignedInt(21);
  639. xdr.writeUnsignedInt(this.status);
  640. if (this.status === 0 && this.resok) {
  641. this.resok.encode(xdr);
  642. }
  643. }
  644. }
  645. exports.Nfsv4OpenDowngradeResponse = Nfsv4OpenDowngradeResponse;
  646. class Nfsv4PutfhRequest {
  647. constructor(object) {
  648. this.object = object;
  649. }
  650. encode(xdr) {
  651. xdr.writeUnsignedInt(22);
  652. this.object.encode(xdr);
  653. }
  654. }
  655. exports.Nfsv4PutfhRequest = Nfsv4PutfhRequest;
  656. class Nfsv4PutfhResponse {
  657. constructor(status) {
  658. this.status = status;
  659. }
  660. encode(xdr) {
  661. xdr.writeUnsignedInt(22);
  662. xdr.writeUnsignedInt(this.status);
  663. }
  664. }
  665. exports.Nfsv4PutfhResponse = Nfsv4PutfhResponse;
  666. class Nfsv4PutpubfhRequest {
  667. encode(xdr) {
  668. xdr.writeUnsignedInt(23);
  669. }
  670. }
  671. exports.Nfsv4PutpubfhRequest = Nfsv4PutpubfhRequest;
  672. class Nfsv4PutpubfhResponse {
  673. static decode(xdr) {
  674. const status = xdr.readUnsignedInt();
  675. return new Nfsv4PutpubfhResponse(status);
  676. }
  677. constructor(status) {
  678. this.status = status;
  679. }
  680. encode(xdr) {
  681. xdr.writeUnsignedInt(23);
  682. xdr.writeUnsignedInt(this.status);
  683. }
  684. }
  685. exports.Nfsv4PutpubfhResponse = Nfsv4PutpubfhResponse;
  686. class Nfsv4PutrootfhRequest {
  687. encode(xdr) {
  688. xdr.writeUnsignedInt(24);
  689. }
  690. }
  691. exports.Nfsv4PutrootfhRequest = Nfsv4PutrootfhRequest;
  692. class Nfsv4PutrootfhResponse {
  693. constructor(status) {
  694. this.status = status;
  695. }
  696. encode(xdr) {
  697. xdr.writeUnsignedInt(24);
  698. xdr.writeUnsignedInt(this.status);
  699. }
  700. }
  701. exports.Nfsv4PutrootfhResponse = Nfsv4PutrootfhResponse;
  702. class Nfsv4ReadRequest {
  703. constructor(stateid, offset, count) {
  704. this.stateid = stateid;
  705. this.offset = offset;
  706. this.count = count;
  707. }
  708. encode(xdr) {
  709. xdr.writeUnsignedInt(25);
  710. this.stateid.encode(xdr);
  711. xdr.writeUnsignedHyper(this.offset);
  712. xdr.writeUnsignedInt(this.count);
  713. }
  714. }
  715. exports.Nfsv4ReadRequest = Nfsv4ReadRequest;
  716. class Nfsv4ReadResOk {
  717. constructor(eof, data) {
  718. this.eof = eof;
  719. this.data = data;
  720. }
  721. encode(xdr) {
  722. xdr.writeBoolean(this.eof);
  723. xdr.writeVarlenOpaque(this.data);
  724. }
  725. }
  726. exports.Nfsv4ReadResOk = Nfsv4ReadResOk;
  727. class Nfsv4ReadResponse {
  728. constructor(status, resok) {
  729. this.status = status;
  730. this.resok = resok;
  731. }
  732. encode(xdr) {
  733. xdr.writeUnsignedInt(25);
  734. xdr.writeUnsignedInt(this.status);
  735. if (this.status === 0 && this.resok) {
  736. this.resok.encode(xdr);
  737. }
  738. }
  739. }
  740. exports.Nfsv4ReadResponse = Nfsv4ReadResponse;
  741. class Nfsv4ReaddirRequest {
  742. constructor(cookie, cookieverf, dircount, maxcount, attrRequest) {
  743. this.cookie = cookie;
  744. this.cookieverf = cookieverf;
  745. this.dircount = dircount;
  746. this.maxcount = maxcount;
  747. this.attrRequest = attrRequest;
  748. }
  749. encode(xdr) {
  750. xdr.writeUnsignedInt(26);
  751. xdr.writeUnsignedHyper(this.cookie);
  752. this.cookieverf.encode(xdr);
  753. xdr.writeUnsignedInt(this.dircount);
  754. xdr.writeUnsignedInt(this.maxcount);
  755. this.attrRequest.encode(xdr);
  756. }
  757. }
  758. exports.Nfsv4ReaddirRequest = Nfsv4ReaddirRequest;
  759. class Nfsv4ReaddirResOk {
  760. constructor(cookieverf, entries, eof) {
  761. this.cookieverf = cookieverf;
  762. this.entries = entries;
  763. this.eof = eof;
  764. }
  765. encode(xdr) {
  766. this.cookieverf.encode(xdr);
  767. const entries = this.entries;
  768. const length = entries.length;
  769. for (let i = 0; i < length; i++) {
  770. const entry = entries[i];
  771. xdr.writeBoolean(true);
  772. entry.encode(xdr);
  773. }
  774. xdr.writeBoolean(false);
  775. xdr.writeBoolean(this.eof);
  776. }
  777. }
  778. exports.Nfsv4ReaddirResOk = Nfsv4ReaddirResOk;
  779. class Nfsv4ReaddirResponse {
  780. constructor(status, resok) {
  781. this.status = status;
  782. this.resok = resok;
  783. }
  784. encode(xdr) {
  785. xdr.writeUnsignedInt(26);
  786. xdr.writeUnsignedInt(this.status);
  787. if (this.status === 0 && this.resok) {
  788. this.resok.encode(xdr);
  789. }
  790. }
  791. }
  792. exports.Nfsv4ReaddirResponse = Nfsv4ReaddirResponse;
  793. class Nfsv4ReadlinkRequest {
  794. encode(xdr) {
  795. xdr.writeUnsignedInt(27);
  796. }
  797. }
  798. exports.Nfsv4ReadlinkRequest = Nfsv4ReadlinkRequest;
  799. class Nfsv4ReadlinkResOk {
  800. constructor(link) {
  801. this.link = link;
  802. }
  803. encode(xdr) {
  804. xdr.writeStr(this.link);
  805. }
  806. }
  807. exports.Nfsv4ReadlinkResOk = Nfsv4ReadlinkResOk;
  808. class Nfsv4ReadlinkResponse {
  809. constructor(status, resok) {
  810. this.status = status;
  811. this.resok = resok;
  812. }
  813. encode(xdr) {
  814. xdr.writeUnsignedInt(27);
  815. xdr.writeUnsignedInt(this.status);
  816. if (this.status === 0 && this.resok) {
  817. this.resok.encode(xdr);
  818. }
  819. }
  820. }
  821. exports.Nfsv4ReadlinkResponse = Nfsv4ReadlinkResponse;
  822. class Nfsv4RemoveRequest {
  823. constructor(target) {
  824. this.target = target;
  825. }
  826. encode(xdr) {
  827. xdr.writeUnsignedInt(28);
  828. xdr.writeStr(this.target);
  829. }
  830. }
  831. exports.Nfsv4RemoveRequest = Nfsv4RemoveRequest;
  832. class Nfsv4RemoveResOk {
  833. constructor(cinfo) {
  834. this.cinfo = cinfo;
  835. }
  836. encode(xdr) {
  837. this.cinfo.encode(xdr);
  838. }
  839. }
  840. exports.Nfsv4RemoveResOk = Nfsv4RemoveResOk;
  841. class Nfsv4RemoveResponse {
  842. constructor(status, resok) {
  843. this.status = status;
  844. this.resok = resok;
  845. }
  846. encode(xdr) {
  847. xdr.writeUnsignedInt(28);
  848. xdr.writeUnsignedInt(this.status);
  849. if (this.status === 0 && this.resok) {
  850. this.resok.encode(xdr);
  851. }
  852. }
  853. }
  854. exports.Nfsv4RemoveResponse = Nfsv4RemoveResponse;
  855. class Nfsv4RenameRequest {
  856. constructor(oldname, newname) {
  857. this.oldname = oldname;
  858. this.newname = newname;
  859. }
  860. encode(xdr) {
  861. xdr.writeUnsignedInt(29);
  862. xdr.writeStr(this.oldname);
  863. xdr.writeStr(this.newname);
  864. }
  865. }
  866. exports.Nfsv4RenameRequest = Nfsv4RenameRequest;
  867. class Nfsv4RenameResOk {
  868. constructor(sourceCinfo, targetCinfo) {
  869. this.sourceCinfo = sourceCinfo;
  870. this.targetCinfo = targetCinfo;
  871. }
  872. encode(xdr) {
  873. this.sourceCinfo.encode(xdr);
  874. this.targetCinfo.encode(xdr);
  875. }
  876. }
  877. exports.Nfsv4RenameResOk = Nfsv4RenameResOk;
  878. class Nfsv4RenameResponse {
  879. constructor(status, resok) {
  880. this.status = status;
  881. this.resok = resok;
  882. }
  883. encode(xdr) {
  884. xdr.writeUnsignedInt(29);
  885. xdr.writeUnsignedInt(this.status);
  886. if (this.status === 0)
  887. this.resok?.encode(xdr);
  888. }
  889. }
  890. exports.Nfsv4RenameResponse = Nfsv4RenameResponse;
  891. class Nfsv4RenewRequest {
  892. constructor(clientid) {
  893. this.clientid = clientid;
  894. }
  895. encode(xdr) {
  896. xdr.writeUnsignedInt(30);
  897. xdr.writeUnsignedHyper(this.clientid);
  898. }
  899. }
  900. exports.Nfsv4RenewRequest = Nfsv4RenewRequest;
  901. class Nfsv4RenewResponse {
  902. constructor(status) {
  903. this.status = status;
  904. }
  905. encode(xdr) {
  906. xdr.writeUnsignedInt(30);
  907. xdr.writeUnsignedInt(this.status);
  908. }
  909. }
  910. exports.Nfsv4RenewResponse = Nfsv4RenewResponse;
  911. class Nfsv4RestorefhRequest {
  912. encode(xdr) {
  913. xdr.writeUnsignedInt(31);
  914. }
  915. }
  916. exports.Nfsv4RestorefhRequest = Nfsv4RestorefhRequest;
  917. class Nfsv4RestorefhResponse {
  918. constructor(status) {
  919. this.status = status;
  920. }
  921. encode(xdr) {
  922. xdr.writeUnsignedInt(31);
  923. xdr.writeUnsignedInt(this.status);
  924. }
  925. }
  926. exports.Nfsv4RestorefhResponse = Nfsv4RestorefhResponse;
  927. class Nfsv4SavefhRequest {
  928. encode(xdr) {
  929. xdr.writeUnsignedInt(32);
  930. }
  931. }
  932. exports.Nfsv4SavefhRequest = Nfsv4SavefhRequest;
  933. class Nfsv4SavefhResponse {
  934. constructor(status) {
  935. this.status = status;
  936. }
  937. encode(xdr) {
  938. xdr.writeUnsignedInt(32);
  939. xdr.writeUnsignedInt(this.status);
  940. }
  941. }
  942. exports.Nfsv4SavefhResponse = Nfsv4SavefhResponse;
  943. class Nfsv4SecinfoRequest {
  944. constructor(name) {
  945. this.name = name;
  946. }
  947. encode(xdr) {
  948. xdr.writeUnsignedInt(33);
  949. xdr.writeStr(this.name);
  950. }
  951. }
  952. exports.Nfsv4SecinfoRequest = Nfsv4SecinfoRequest;
  953. class Nfsv4SecinfoResOk {
  954. constructor(flavors) {
  955. this.flavors = flavors;
  956. }
  957. encode(xdr) {
  958. const flavors = this.flavors;
  959. const len = flavors.length;
  960. xdr.writeUnsignedInt(len);
  961. for (let i = 0; i < len; i++)
  962. flavors[i].encode(xdr);
  963. }
  964. }
  965. exports.Nfsv4SecinfoResOk = Nfsv4SecinfoResOk;
  966. class Nfsv4SecinfoResponse {
  967. constructor(status, resok) {
  968. this.status = status;
  969. this.resok = resok;
  970. }
  971. encode(xdr) {
  972. xdr.writeUnsignedInt(33);
  973. xdr.writeUnsignedInt(this.status);
  974. if (this.status === 0 && this.resok)
  975. this.resok.encode(xdr);
  976. }
  977. }
  978. exports.Nfsv4SecinfoResponse = Nfsv4SecinfoResponse;
  979. class Nfsv4SetattrRequest {
  980. constructor(stateid, objAttributes) {
  981. this.stateid = stateid;
  982. this.objAttributes = objAttributes;
  983. }
  984. encode(xdr) {
  985. xdr.writeUnsignedInt(34);
  986. this.stateid.encode(xdr);
  987. this.objAttributes.encode(xdr);
  988. }
  989. }
  990. exports.Nfsv4SetattrRequest = Nfsv4SetattrRequest;
  991. class Nfsv4SetattrResOk {
  992. constructor(attrsset) {
  993. this.attrsset = attrsset;
  994. }
  995. encode(xdr) {
  996. this.attrsset.encode(xdr);
  997. }
  998. }
  999. exports.Nfsv4SetattrResOk = Nfsv4SetattrResOk;
  1000. class Nfsv4SetattrResponse {
  1001. constructor(status, resok) {
  1002. this.status = status;
  1003. this.resok = resok;
  1004. }
  1005. encode(xdr) {
  1006. xdr.writeUnsignedInt(34);
  1007. xdr.writeUnsignedInt(this.status);
  1008. this.resok?.encode(xdr);
  1009. }
  1010. }
  1011. exports.Nfsv4SetattrResponse = Nfsv4SetattrResponse;
  1012. class Nfsv4SetclientidRequest {
  1013. constructor(client, callback, callbackIdent) {
  1014. this.client = client;
  1015. this.callback = callback;
  1016. this.callbackIdent = callbackIdent;
  1017. }
  1018. encode(xdr) {
  1019. xdr.writeUnsignedInt(35);
  1020. this.client.encode(xdr);
  1021. this.callback.encode(xdr);
  1022. xdr.writeUnsignedInt(this.callbackIdent);
  1023. }
  1024. }
  1025. exports.Nfsv4SetclientidRequest = Nfsv4SetclientidRequest;
  1026. class Nfsv4SetclientidResOk {
  1027. constructor(clientid, setclientidConfirm) {
  1028. this.clientid = clientid;
  1029. this.setclientidConfirm = setclientidConfirm;
  1030. }
  1031. encode(xdr) {
  1032. xdr.writeUnsignedHyper(this.clientid);
  1033. this.setclientidConfirm.encode(xdr);
  1034. }
  1035. }
  1036. exports.Nfsv4SetclientidResOk = Nfsv4SetclientidResOk;
  1037. class Nfsv4SetclientidResponse {
  1038. constructor(status, resok) {
  1039. this.status = status;
  1040. this.resok = resok;
  1041. }
  1042. encode(xdr) {
  1043. xdr.writeUnsignedInt(35);
  1044. xdr.writeUnsignedInt(this.status);
  1045. if (this.status === 0)
  1046. this.resok?.encode(xdr);
  1047. }
  1048. }
  1049. exports.Nfsv4SetclientidResponse = Nfsv4SetclientidResponse;
  1050. class Nfsv4SetclientidConfirmRequest {
  1051. constructor(clientid, setclientidConfirm) {
  1052. this.clientid = clientid;
  1053. this.setclientidConfirm = setclientidConfirm;
  1054. }
  1055. encode(xdr) {
  1056. xdr.writeUnsignedInt(36);
  1057. xdr.writeUnsignedHyper(this.clientid);
  1058. this.setclientidConfirm.encode(xdr);
  1059. }
  1060. }
  1061. exports.Nfsv4SetclientidConfirmRequest = Nfsv4SetclientidConfirmRequest;
  1062. class Nfsv4SetclientidConfirmResponse {
  1063. constructor(status) {
  1064. this.status = status;
  1065. }
  1066. encode(xdr) {
  1067. xdr.writeUnsignedInt(36);
  1068. xdr.writeUnsignedInt(this.status);
  1069. }
  1070. }
  1071. exports.Nfsv4SetclientidConfirmResponse = Nfsv4SetclientidConfirmResponse;
  1072. class Nfsv4VerifyRequest {
  1073. constructor(objAttributes) {
  1074. this.objAttributes = objAttributes;
  1075. }
  1076. encode(xdr) {
  1077. xdr.writeUnsignedInt(37);
  1078. this.objAttributes.encode(xdr);
  1079. }
  1080. }
  1081. exports.Nfsv4VerifyRequest = Nfsv4VerifyRequest;
  1082. class Nfsv4VerifyResponse {
  1083. constructor(status) {
  1084. this.status = status;
  1085. }
  1086. encode(xdr) {
  1087. xdr.writeUnsignedInt(37);
  1088. xdr.writeUnsignedInt(this.status);
  1089. }
  1090. }
  1091. exports.Nfsv4VerifyResponse = Nfsv4VerifyResponse;
  1092. class Nfsv4WriteRequest {
  1093. constructor(stateid, offset, stable, data) {
  1094. this.stateid = stateid;
  1095. this.offset = offset;
  1096. this.stable = stable;
  1097. this.data = data;
  1098. }
  1099. encode(xdr) {
  1100. xdr.writeUnsignedInt(38);
  1101. this.stateid.encode(xdr);
  1102. xdr.writeUnsignedHyper(this.offset);
  1103. xdr.writeUnsignedInt(this.stable);
  1104. xdr.writeVarlenOpaque(this.data);
  1105. }
  1106. }
  1107. exports.Nfsv4WriteRequest = Nfsv4WriteRequest;
  1108. class Nfsv4WriteResOk {
  1109. constructor(count, committed, writeverf) {
  1110. this.count = count;
  1111. this.committed = committed;
  1112. this.writeverf = writeverf;
  1113. }
  1114. encode(xdr) {
  1115. xdr.writeUnsignedInt(this.count);
  1116. xdr.writeUnsignedInt(this.committed);
  1117. this.writeverf.encode(xdr);
  1118. }
  1119. }
  1120. exports.Nfsv4WriteResOk = Nfsv4WriteResOk;
  1121. class Nfsv4WriteResponse {
  1122. constructor(status, resok) {
  1123. this.status = status;
  1124. this.resok = resok;
  1125. }
  1126. encode(xdr) {
  1127. xdr.writeUnsignedInt(38);
  1128. xdr.writeUnsignedInt(this.status);
  1129. if (this.status === 0 && this.resok)
  1130. this.resok.encode(xdr);
  1131. }
  1132. }
  1133. exports.Nfsv4WriteResponse = Nfsv4WriteResponse;
  1134. class Nfsv4ReleaseLockOwnerRequest {
  1135. constructor(lockOwner) {
  1136. this.lockOwner = lockOwner;
  1137. }
  1138. encode(xdr) {
  1139. xdr.writeUnsignedInt(39);
  1140. this.lockOwner.encode(xdr);
  1141. }
  1142. }
  1143. exports.Nfsv4ReleaseLockOwnerRequest = Nfsv4ReleaseLockOwnerRequest;
  1144. class Nfsv4ReleaseLockOwnerResponse {
  1145. constructor(status) {
  1146. this.status = status;
  1147. }
  1148. encode(xdr) {
  1149. xdr.writeUnsignedInt(39);
  1150. xdr.writeUnsignedInt(this.status);
  1151. }
  1152. }
  1153. exports.Nfsv4ReleaseLockOwnerResponse = Nfsv4ReleaseLockOwnerResponse;
  1154. class Nfsv4IllegalRequest {
  1155. encode(xdr) {
  1156. xdr.writeUnsignedInt(10044);
  1157. }
  1158. }
  1159. exports.Nfsv4IllegalRequest = Nfsv4IllegalRequest;
  1160. class Nfsv4IllegalResponse {
  1161. constructor(status) {
  1162. this.status = status;
  1163. }
  1164. encode(xdr) {
  1165. xdr.writeUnsignedInt(10044);
  1166. xdr.writeUnsignedInt(this.status);
  1167. }
  1168. }
  1169. exports.Nfsv4IllegalResponse = Nfsv4IllegalResponse;
  1170. class Nfsv4CompoundRequest {
  1171. constructor(tag, minorversion, argarray) {
  1172. this.tag = tag;
  1173. this.minorversion = minorversion;
  1174. this.argarray = argarray;
  1175. }
  1176. encode(xdr) {
  1177. xdr.writeStr(this.tag);
  1178. xdr.writeUnsignedInt(this.minorversion);
  1179. const argarray = this.argarray;
  1180. const len = argarray.length;
  1181. xdr.writeUnsignedInt(len);
  1182. for (let i = 0; i < len; i++)
  1183. argarray[i].encode(xdr);
  1184. }
  1185. }
  1186. exports.Nfsv4CompoundRequest = Nfsv4CompoundRequest;
  1187. class Nfsv4CompoundResponse {
  1188. constructor(status, tag, resarray) {
  1189. this.status = status;
  1190. this.tag = tag;
  1191. this.resarray = resarray;
  1192. }
  1193. encode(xdr) {
  1194. xdr.writeUnsignedInt(this.status);
  1195. xdr.writeStr(this.tag);
  1196. const resarray = this.resarray;
  1197. const len = resarray.length;
  1198. xdr.writeUnsignedInt(len);
  1199. for (let i = 0; i < len; i++)
  1200. resarray[i].encode(xdr);
  1201. }
  1202. }
  1203. exports.Nfsv4CompoundResponse = Nfsv4CompoundResponse;
  1204. class Nfsv4CbGetattrRequest {
  1205. constructor(fh, attrRequest) {
  1206. this.fh = fh;
  1207. this.attrRequest = attrRequest;
  1208. }
  1209. encode(xdr) {
  1210. xdr.writeUnsignedInt(3);
  1211. this.fh.encode(xdr);
  1212. this.attrRequest.encode(xdr);
  1213. }
  1214. }
  1215. exports.Nfsv4CbGetattrRequest = Nfsv4CbGetattrRequest;
  1216. class Nfsv4CbGetattrResOk {
  1217. constructor(objAttributes) {
  1218. this.objAttributes = objAttributes;
  1219. }
  1220. encode(xdr) {
  1221. this.objAttributes.encode(xdr);
  1222. }
  1223. }
  1224. exports.Nfsv4CbGetattrResOk = Nfsv4CbGetattrResOk;
  1225. class Nfsv4CbGetattrResponse {
  1226. constructor(status, resok) {
  1227. this.status = status;
  1228. this.resok = resok;
  1229. }
  1230. encode(xdr) {
  1231. xdr.writeUnsignedInt(3);
  1232. xdr.writeUnsignedInt(this.status);
  1233. if (this.status === 0 && this.resok) {
  1234. this.resok.encode(xdr);
  1235. }
  1236. }
  1237. }
  1238. exports.Nfsv4CbGetattrResponse = Nfsv4CbGetattrResponse;
  1239. class Nfsv4CbRecallRequest {
  1240. constructor(stateid, truncate, fh) {
  1241. this.stateid = stateid;
  1242. this.truncate = truncate;
  1243. this.fh = fh;
  1244. }
  1245. encode(xdr) {
  1246. xdr.writeUnsignedInt(4);
  1247. this.stateid.encode(xdr);
  1248. xdr.writeBoolean(this.truncate);
  1249. this.fh.encode(xdr);
  1250. }
  1251. }
  1252. exports.Nfsv4CbRecallRequest = Nfsv4CbRecallRequest;
  1253. class Nfsv4CbRecallResponse {
  1254. constructor(status) {
  1255. this.status = status;
  1256. }
  1257. encode(xdr) {
  1258. xdr.writeUnsignedInt(4);
  1259. xdr.writeUnsignedInt(this.status);
  1260. }
  1261. }
  1262. exports.Nfsv4CbRecallResponse = Nfsv4CbRecallResponse;
  1263. class Nfsv4CbIllegalRequest {
  1264. encode(xdr) {
  1265. xdr.writeUnsignedInt(10044);
  1266. }
  1267. }
  1268. exports.Nfsv4CbIllegalRequest = Nfsv4CbIllegalRequest;
  1269. class Nfsv4CbIllegalResponse {
  1270. constructor(status) {
  1271. this.status = status;
  1272. }
  1273. encode(xdr) {
  1274. xdr.writeUnsignedInt(10044);
  1275. xdr.writeUnsignedInt(this.status);
  1276. }
  1277. }
  1278. exports.Nfsv4CbIllegalResponse = Nfsv4CbIllegalResponse;
  1279. class Nfsv4CbCompoundRequest {
  1280. constructor(tag, minorversion, callbackIdent, argarray) {
  1281. this.tag = tag;
  1282. this.minorversion = minorversion;
  1283. this.callbackIdent = callbackIdent;
  1284. this.argarray = argarray;
  1285. }
  1286. encode(xdr) {
  1287. xdr.writeStr(this.tag);
  1288. xdr.writeUnsignedInt(this.minorversion);
  1289. xdr.writeUnsignedInt(this.callbackIdent);
  1290. const argarray = this.argarray;
  1291. const len = argarray.length;
  1292. xdr.writeUnsignedInt(len);
  1293. for (let i = 0; i < len; i++)
  1294. argarray[i].encode(xdr);
  1295. }
  1296. }
  1297. exports.Nfsv4CbCompoundRequest = Nfsv4CbCompoundRequest;
  1298. class Nfsv4CbCompoundResponse {
  1299. constructor(status, tag, resarray) {
  1300. this.status = status;
  1301. this.tag = tag;
  1302. this.resarray = resarray;
  1303. }
  1304. encode(xdr) {
  1305. xdr.writeUnsignedInt(this.status);
  1306. xdr.writeStr(this.tag);
  1307. const resarray = this.resarray;
  1308. const len = resarray.length;
  1309. xdr.writeUnsignedInt(len);
  1310. for (let i = 0; i < len; i++)
  1311. resarray[i].encode(xdr);
  1312. }
  1313. }
  1314. exports.Nfsv4CbCompoundResponse = Nfsv4CbCompoundResponse;
  1315. //# sourceMappingURL=messages.js.map