github.com/quickfeed/quickfeed@v0.0.0-20240507093252-ed8ca812a09c/public/proto/qf/types_pb.ts (about) 1 // @generated by protoc-gen-es v1.8.0 with parameter "target=ts" 2 // @generated from file qf/types.proto (package qf, syntax proto3) 3 /* eslint-disable */ 4 // @ts-nocheck 5 6 import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf"; 7 import { Message, proto3, protoInt64, Timestamp } from "@bufbuild/protobuf"; 8 import { BuildInfo, Score } from "../kit/score/score_pb.js"; 9 10 /** 11 * @generated from message qf.User 12 */ 13 export class User extends Message<User> { 14 /** 15 * @generated from field: uint64 ID = 1; 16 */ 17 ID = protoInt64.zero; 18 19 /** 20 * @generated from field: bool IsAdmin = 2; 21 */ 22 IsAdmin = false; 23 24 /** 25 * @generated from field: string Name = 3; 26 */ 27 Name = ""; 28 29 /** 30 * @generated from field: string StudentID = 4; 31 */ 32 StudentID = ""; 33 34 /** 35 * @generated from field: string Email = 5; 36 */ 37 Email = ""; 38 39 /** 40 * @generated from field: string AvatarURL = 6; 41 */ 42 AvatarURL = ""; 43 44 /** 45 * @generated from field: string Login = 7; 46 */ 47 Login = ""; 48 49 /** 50 * Filter; True if user's JWT token needs to be updated. 51 * 52 * @generated from field: bool UpdateToken = 8; 53 */ 54 UpdateToken = false; 55 56 /** 57 * Filter; The user's ID on the remote provider. 58 * 59 * @generated from field: uint64 ScmRemoteID = 9; 60 */ 61 ScmRemoteID = protoInt64.zero; 62 63 /** 64 * Filter; The user's refresh token that may be exchanged for an access token. 65 * 66 * @generated from field: string RefreshToken = 10; 67 */ 68 RefreshToken = ""; 69 70 /** 71 * @generated from field: repeated qf.Enrollment Enrollments = 11; 72 */ 73 Enrollments: Enrollment[] = []; 74 75 constructor(data?: PartialMessage<User>) { 76 super(); 77 proto3.util.initPartial(data, this); 78 } 79 80 static readonly runtime: typeof proto3 = proto3; 81 static readonly typeName = "qf.User"; 82 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 83 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 84 { no: 2, name: "IsAdmin", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, 85 { no: 3, name: "Name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 86 { no: 4, name: "StudentID", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 87 { no: 5, name: "Email", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 88 { no: 6, name: "AvatarURL", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 89 { no: 7, name: "Login", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 90 { no: 8, name: "UpdateToken", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, 91 { no: 9, name: "ScmRemoteID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 92 { no: 10, name: "RefreshToken", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 93 { no: 11, name: "Enrollments", kind: "message", T: Enrollment, repeated: true }, 94 ]); 95 96 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): User { 97 return new User().fromBinary(bytes, options); 98 } 99 100 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): User { 101 return new User().fromJson(jsonValue, options); 102 } 103 104 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): User { 105 return new User().fromJsonString(jsonString, options); 106 } 107 108 static equals(a: User | PlainMessage<User> | undefined, b: User | PlainMessage<User> | undefined): boolean { 109 return proto3.util.equals(User, a, b); 110 } 111 } 112 113 /** 114 * @generated from message qf.Users 115 */ 116 export class Users extends Message<Users> { 117 /** 118 * @generated from field: repeated qf.User users = 1; 119 */ 120 users: User[] = []; 121 122 constructor(data?: PartialMessage<Users>) { 123 super(); 124 proto3.util.initPartial(data, this); 125 } 126 127 static readonly runtime: typeof proto3 = proto3; 128 static readonly typeName = "qf.Users"; 129 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 130 { no: 1, name: "users", kind: "message", T: User, repeated: true }, 131 ]); 132 133 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Users { 134 return new Users().fromBinary(bytes, options); 135 } 136 137 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Users { 138 return new Users().fromJson(jsonValue, options); 139 } 140 141 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Users { 142 return new Users().fromJsonString(jsonString, options); 143 } 144 145 static equals(a: Users | PlainMessage<Users> | undefined, b: Users | PlainMessage<Users> | undefined): boolean { 146 return proto3.util.equals(Users, a, b); 147 } 148 } 149 150 /** 151 * @generated from message qf.Group 152 */ 153 export class Group extends Message<Group> { 154 /** 155 * @generated from field: uint64 ID = 1; 156 */ 157 ID = protoInt64.zero; 158 159 /** 160 * @generated from field: string name = 2; 161 */ 162 name = ""; 163 164 /** 165 * @generated from field: uint64 courseID = 3; 166 */ 167 courseID = protoInt64.zero; 168 169 /** 170 * @generated from field: uint64 ScmTeamID = 4; 171 */ 172 ScmTeamID = protoInt64.zero; 173 174 /** 175 * @generated from field: qf.Group.GroupStatus status = 5; 176 */ 177 status = Group_GroupStatus.PENDING; 178 179 /** 180 * @generated from field: repeated qf.User users = 6; 181 */ 182 users: User[] = []; 183 184 /** 185 * @generated from field: repeated qf.Enrollment enrollments = 7; 186 */ 187 enrollments: Enrollment[] = []; 188 189 constructor(data?: PartialMessage<Group>) { 190 super(); 191 proto3.util.initPartial(data, this); 192 } 193 194 static readonly runtime: typeof proto3 = proto3; 195 static readonly typeName = "qf.Group"; 196 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 197 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 198 { no: 2, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 199 { no: 3, name: "courseID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 200 { no: 4, name: "ScmTeamID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 201 { no: 5, name: "status", kind: "enum", T: proto3.getEnumType(Group_GroupStatus) }, 202 { no: 6, name: "users", kind: "message", T: User, repeated: true }, 203 { no: 7, name: "enrollments", kind: "message", T: Enrollment, repeated: true }, 204 ]); 205 206 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Group { 207 return new Group().fromBinary(bytes, options); 208 } 209 210 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Group { 211 return new Group().fromJson(jsonValue, options); 212 } 213 214 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Group { 215 return new Group().fromJsonString(jsonString, options); 216 } 217 218 static equals(a: Group | PlainMessage<Group> | undefined, b: Group | PlainMessage<Group> | undefined): boolean { 219 return proto3.util.equals(Group, a, b); 220 } 221 } 222 223 /** 224 * @generated from enum qf.Group.GroupStatus 225 */ 226 export enum Group_GroupStatus { 227 /** 228 * @generated from enum value: PENDING = 0; 229 */ 230 PENDING = 0, 231 232 /** 233 * @generated from enum value: APPROVED = 1; 234 */ 235 APPROVED = 1, 236 } 237 // Retrieve enum metadata with: proto3.getEnumType(Group_GroupStatus) 238 proto3.util.setEnumType(Group_GroupStatus, "qf.Group.GroupStatus", [ 239 { no: 0, name: "PENDING" }, 240 { no: 1, name: "APPROVED" }, 241 ]); 242 243 /** 244 * @generated from message qf.Groups 245 */ 246 export class Groups extends Message<Groups> { 247 /** 248 * @generated from field: repeated qf.Group groups = 1; 249 */ 250 groups: Group[] = []; 251 252 constructor(data?: PartialMessage<Groups>) { 253 super(); 254 proto3.util.initPartial(data, this); 255 } 256 257 static readonly runtime: typeof proto3 = proto3; 258 static readonly typeName = "qf.Groups"; 259 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 260 { no: 1, name: "groups", kind: "message", T: Group, repeated: true }, 261 ]); 262 263 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Groups { 264 return new Groups().fromBinary(bytes, options); 265 } 266 267 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Groups { 268 return new Groups().fromJson(jsonValue, options); 269 } 270 271 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Groups { 272 return new Groups().fromJsonString(jsonString, options); 273 } 274 275 static equals(a: Groups | PlainMessage<Groups> | undefined, b: Groups | PlainMessage<Groups> | undefined): boolean { 276 return proto3.util.equals(Groups, a, b); 277 } 278 } 279 280 /** 281 * @generated from message qf.Course 282 */ 283 export class Course extends Message<Course> { 284 /** 285 * @generated from field: uint64 ID = 1; 286 */ 287 ID = protoInt64.zero; 288 289 /** 290 * @generated from field: uint64 courseCreatorID = 2; 291 */ 292 courseCreatorID = protoInt64.zero; 293 294 /** 295 * @generated from field: string name = 3; 296 */ 297 name = ""; 298 299 /** 300 * @generated from field: string code = 4; 301 */ 302 code = ""; 303 304 /** 305 * @generated from field: uint32 year = 5; 306 */ 307 year = 0; 308 309 /** 310 * @generated from field: string tag = 6; 311 */ 312 tag = ""; 313 314 /** 315 * @generated from field: uint64 ScmOrganizationID = 8; 316 */ 317 ScmOrganizationID = protoInt64.zero; 318 319 /** 320 * The organization's SCM name, e.g., dat520-2020. 321 * 322 * @generated from field: string ScmOrganizationName = 9; 323 */ 324 ScmOrganizationName = ""; 325 326 /** 327 * @generated from field: uint32 slipDays = 10; 328 */ 329 slipDays = 0; 330 331 /** 332 * Digest of the dockerfile used to build the course's docker image. 333 * 334 * @generated from field: string DockerfileDigest = 11; 335 */ 336 DockerfileDigest = ""; 337 338 /** 339 * @generated from field: qf.Enrollment.UserStatus enrolled = 12; 340 */ 341 enrolled = Enrollment_UserStatus.NONE; 342 343 /** 344 * @generated from field: repeated qf.Enrollment enrollments = 13; 345 */ 346 enrollments: Enrollment[] = []; 347 348 /** 349 * @generated from field: repeated qf.Assignment assignments = 14; 350 */ 351 assignments: Assignment[] = []; 352 353 /** 354 * @generated from field: repeated qf.Group groups = 15; 355 */ 356 groups: Group[] = []; 357 358 constructor(data?: PartialMessage<Course>) { 359 super(); 360 proto3.util.initPartial(data, this); 361 } 362 363 static readonly runtime: typeof proto3 = proto3; 364 static readonly typeName = "qf.Course"; 365 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 366 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 367 { no: 2, name: "courseCreatorID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 368 { no: 3, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 369 { no: 4, name: "code", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 370 { no: 5, name: "year", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 371 { no: 6, name: "tag", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 372 { no: 8, name: "ScmOrganizationID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 373 { no: 9, name: "ScmOrganizationName", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 374 { no: 10, name: "slipDays", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 375 { no: 11, name: "DockerfileDigest", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 376 { no: 12, name: "enrolled", kind: "enum", T: proto3.getEnumType(Enrollment_UserStatus) }, 377 { no: 13, name: "enrollments", kind: "message", T: Enrollment, repeated: true }, 378 { no: 14, name: "assignments", kind: "message", T: Assignment, repeated: true }, 379 { no: 15, name: "groups", kind: "message", T: Group, repeated: true }, 380 ]); 381 382 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Course { 383 return new Course().fromBinary(bytes, options); 384 } 385 386 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Course { 387 return new Course().fromJson(jsonValue, options); 388 } 389 390 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Course { 391 return new Course().fromJsonString(jsonString, options); 392 } 393 394 static equals(a: Course | PlainMessage<Course> | undefined, b: Course | PlainMessage<Course> | undefined): boolean { 395 return proto3.util.equals(Course, a, b); 396 } 397 } 398 399 /** 400 * @generated from message qf.Courses 401 */ 402 export class Courses extends Message<Courses> { 403 /** 404 * @generated from field: repeated qf.Course courses = 1; 405 */ 406 courses: Course[] = []; 407 408 constructor(data?: PartialMessage<Courses>) { 409 super(); 410 proto3.util.initPartial(data, this); 411 } 412 413 static readonly runtime: typeof proto3 = proto3; 414 static readonly typeName = "qf.Courses"; 415 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 416 { no: 1, name: "courses", kind: "message", T: Course, repeated: true }, 417 ]); 418 419 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Courses { 420 return new Courses().fromBinary(bytes, options); 421 } 422 423 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Courses { 424 return new Courses().fromJson(jsonValue, options); 425 } 426 427 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Courses { 428 return new Courses().fromJsonString(jsonString, options); 429 } 430 431 static equals(a: Courses | PlainMessage<Courses> | undefined, b: Courses | PlainMessage<Courses> | undefined): boolean { 432 return proto3.util.equals(Courses, a, b); 433 } 434 } 435 436 /** 437 * @generated from message qf.Repository 438 */ 439 export class Repository extends Message<Repository> { 440 /** 441 * @generated from field: uint64 ID = 1; 442 */ 443 ID = protoInt64.zero; 444 445 /** 446 * @generated from field: uint64 ScmOrganizationID = 2; 447 */ 448 ScmOrganizationID = protoInt64.zero; 449 450 /** 451 * ID of a github repository 452 * 453 * @generated from field: uint64 ScmRepositoryID = 3; 454 */ 455 ScmRepositoryID = protoInt64.zero; 456 457 /** 458 * @generated from field: uint64 userID = 4; 459 */ 460 userID = protoInt64.zero; 461 462 /** 463 * @generated from field: uint64 groupID = 5; 464 */ 465 groupID = protoInt64.zero; 466 467 /** 468 * @generated from field: string HTMLURL = 6; 469 */ 470 HTMLURL = ""; 471 472 /** 473 * @generated from field: qf.Repository.Type repoType = 7; 474 */ 475 repoType = Repository_Type.NONE; 476 477 /** 478 * Issues associated with this repository 479 * 480 * @generated from field: repeated qf.Issue issues = 8; 481 */ 482 issues: Issue[] = []; 483 484 constructor(data?: PartialMessage<Repository>) { 485 super(); 486 proto3.util.initPartial(data, this); 487 } 488 489 static readonly runtime: typeof proto3 = proto3; 490 static readonly typeName = "qf.Repository"; 491 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 492 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 493 { no: 2, name: "ScmOrganizationID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 494 { no: 3, name: "ScmRepositoryID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 495 { no: 4, name: "userID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 496 { no: 5, name: "groupID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 497 { no: 6, name: "HTMLURL", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 498 { no: 7, name: "repoType", kind: "enum", T: proto3.getEnumType(Repository_Type) }, 499 { no: 8, name: "issues", kind: "message", T: Issue, repeated: true }, 500 ]); 501 502 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Repository { 503 return new Repository().fromBinary(bytes, options); 504 } 505 506 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Repository { 507 return new Repository().fromJson(jsonValue, options); 508 } 509 510 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Repository { 511 return new Repository().fromJsonString(jsonString, options); 512 } 513 514 static equals(a: Repository | PlainMessage<Repository> | undefined, b: Repository | PlainMessage<Repository> | undefined): boolean { 515 return proto3.util.equals(Repository, a, b); 516 } 517 } 518 519 /** 520 * @generated from enum qf.Repository.Type 521 */ 522 export enum Repository_Type { 523 /** 524 * @generated from enum value: NONE = 0; 525 */ 526 NONE = 0, 527 528 /** 529 * @generated from enum value: INFO = 1; 530 */ 531 INFO = 1, 532 533 /** 534 * @generated from enum value: ASSIGNMENTS = 2; 535 */ 536 ASSIGNMENTS = 2, 537 538 /** 539 * @generated from enum value: TESTS = 3; 540 */ 541 TESTS = 3, 542 543 /** 544 * @generated from enum value: USER = 4; 545 */ 546 USER = 4, 547 548 /** 549 * @generated from enum value: GROUP = 5; 550 */ 551 GROUP = 5, 552 } 553 // Retrieve enum metadata with: proto3.getEnumType(Repository_Type) 554 proto3.util.setEnumType(Repository_Type, "qf.Repository.Type", [ 555 { no: 0, name: "NONE" }, 556 { no: 1, name: "INFO" }, 557 { no: 2, name: "ASSIGNMENTS" }, 558 { no: 3, name: "TESTS" }, 559 { no: 4, name: "USER" }, 560 { no: 5, name: "GROUP" }, 561 ]); 562 563 /** 564 * @generated from message qf.Enrollment 565 */ 566 export class Enrollment extends Message<Enrollment> { 567 /** 568 * @generated from field: uint64 ID = 1; 569 */ 570 ID = protoInt64.zero; 571 572 /** 573 * @generated from field: uint64 courseID = 2; 574 */ 575 courseID = protoInt64.zero; 576 577 /** 578 * @generated from field: uint64 userID = 3; 579 */ 580 userID = protoInt64.zero; 581 582 /** 583 * @generated from field: uint64 groupID = 4; 584 */ 585 groupID = protoInt64.zero; 586 587 /** 588 * @generated from field: qf.User user = 5; 589 */ 590 user?: User; 591 592 /** 593 * @generated from field: qf.Course course = 6; 594 */ 595 course?: Course; 596 597 /** 598 * @generated from field: qf.Group group = 7; 599 */ 600 group?: Group; 601 602 /** 603 * @generated from field: qf.Enrollment.UserStatus status = 8; 604 */ 605 status = Enrollment_UserStatus.NONE; 606 607 /** 608 * @generated from field: qf.Enrollment.DisplayState state = 9; 609 */ 610 state = Enrollment_DisplayState.UNSET; 611 612 /** 613 * @generated from field: uint32 slipDaysRemaining = 10; 614 */ 615 slipDaysRemaining = 0; 616 617 /** 618 * @generated from field: google.protobuf.Timestamp lastActivityDate = 11; 619 */ 620 lastActivityDate?: Timestamp; 621 622 /** 623 * @generated from field: uint64 totalApproved = 12; 624 */ 625 totalApproved = protoInt64.zero; 626 627 /** 628 * @generated from field: repeated qf.UsedSlipDays usedSlipDays = 13; 629 */ 630 usedSlipDays: UsedSlipDays[] = []; 631 632 constructor(data?: PartialMessage<Enrollment>) { 633 super(); 634 proto3.util.initPartial(data, this); 635 } 636 637 static readonly runtime: typeof proto3 = proto3; 638 static readonly typeName = "qf.Enrollment"; 639 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 640 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 641 { no: 2, name: "courseID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 642 { no: 3, name: "userID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 643 { no: 4, name: "groupID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 644 { no: 5, name: "user", kind: "message", T: User }, 645 { no: 6, name: "course", kind: "message", T: Course }, 646 { no: 7, name: "group", kind: "message", T: Group }, 647 { no: 8, name: "status", kind: "enum", T: proto3.getEnumType(Enrollment_UserStatus) }, 648 { no: 9, name: "state", kind: "enum", T: proto3.getEnumType(Enrollment_DisplayState) }, 649 { no: 10, name: "slipDaysRemaining", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 650 { no: 11, name: "lastActivityDate", kind: "message", T: Timestamp }, 651 { no: 12, name: "totalApproved", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 652 { no: 13, name: "usedSlipDays", kind: "message", T: UsedSlipDays, repeated: true }, 653 ]); 654 655 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Enrollment { 656 return new Enrollment().fromBinary(bytes, options); 657 } 658 659 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Enrollment { 660 return new Enrollment().fromJson(jsonValue, options); 661 } 662 663 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Enrollment { 664 return new Enrollment().fromJsonString(jsonString, options); 665 } 666 667 static equals(a: Enrollment | PlainMessage<Enrollment> | undefined, b: Enrollment | PlainMessage<Enrollment> | undefined): boolean { 668 return proto3.util.equals(Enrollment, a, b); 669 } 670 } 671 672 /** 673 * @generated from enum qf.Enrollment.UserStatus 674 */ 675 export enum Enrollment_UserStatus { 676 /** 677 * @generated from enum value: NONE = 0; 678 */ 679 NONE = 0, 680 681 /** 682 * @generated from enum value: PENDING = 1; 683 */ 684 PENDING = 1, 685 686 /** 687 * @generated from enum value: STUDENT = 2; 688 */ 689 STUDENT = 2, 690 691 /** 692 * @generated from enum value: TEACHER = 3; 693 */ 694 TEACHER = 3, 695 } 696 // Retrieve enum metadata with: proto3.getEnumType(Enrollment_UserStatus) 697 proto3.util.setEnumType(Enrollment_UserStatus, "qf.Enrollment.UserStatus", [ 698 { no: 0, name: "NONE" }, 699 { no: 1, name: "PENDING" }, 700 { no: 2, name: "STUDENT" }, 701 { no: 3, name: "TEACHER" }, 702 ]); 703 704 /** 705 * @generated from enum qf.Enrollment.DisplayState 706 */ 707 export enum Enrollment_DisplayState { 708 /** 709 * @generated from enum value: UNSET = 0; 710 */ 711 UNSET = 0, 712 713 /** 714 * @generated from enum value: HIDDEN = 1; 715 */ 716 HIDDEN = 1, 717 718 /** 719 * @generated from enum value: VISIBLE = 2; 720 */ 721 VISIBLE = 2, 722 723 /** 724 * @generated from enum value: FAVORITE = 3; 725 */ 726 FAVORITE = 3, 727 } 728 // Retrieve enum metadata with: proto3.getEnumType(Enrollment_DisplayState) 729 proto3.util.setEnumType(Enrollment_DisplayState, "qf.Enrollment.DisplayState", [ 730 { no: 0, name: "UNSET" }, 731 { no: 1, name: "HIDDEN" }, 732 { no: 2, name: "VISIBLE" }, 733 { no: 3, name: "FAVORITE" }, 734 ]); 735 736 /** 737 * @generated from message qf.UsedSlipDays 738 */ 739 export class UsedSlipDays extends Message<UsedSlipDays> { 740 /** 741 * @generated from field: uint64 ID = 1; 742 */ 743 ID = protoInt64.zero; 744 745 /** 746 * @generated from field: uint64 enrollmentID = 2; 747 */ 748 enrollmentID = protoInt64.zero; 749 750 /** 751 * @generated from field: uint64 assignmentID = 3; 752 */ 753 assignmentID = protoInt64.zero; 754 755 /** 756 * @generated from field: uint32 usedDays = 4; 757 */ 758 usedDays = 0; 759 760 constructor(data?: PartialMessage<UsedSlipDays>) { 761 super(); 762 proto3.util.initPartial(data, this); 763 } 764 765 static readonly runtime: typeof proto3 = proto3; 766 static readonly typeName = "qf.UsedSlipDays"; 767 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 768 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 769 { no: 2, name: "enrollmentID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 770 { no: 3, name: "assignmentID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 771 { no: 4, name: "usedDays", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 772 ]); 773 774 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UsedSlipDays { 775 return new UsedSlipDays().fromBinary(bytes, options); 776 } 777 778 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UsedSlipDays { 779 return new UsedSlipDays().fromJson(jsonValue, options); 780 } 781 782 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UsedSlipDays { 783 return new UsedSlipDays().fromJsonString(jsonString, options); 784 } 785 786 static equals(a: UsedSlipDays | PlainMessage<UsedSlipDays> | undefined, b: UsedSlipDays | PlainMessage<UsedSlipDays> | undefined): boolean { 787 return proto3.util.equals(UsedSlipDays, a, b); 788 } 789 } 790 791 /** 792 * @generated from message qf.Enrollments 793 */ 794 export class Enrollments extends Message<Enrollments> { 795 /** 796 * @generated from field: repeated qf.Enrollment enrollments = 1; 797 */ 798 enrollments: Enrollment[] = []; 799 800 constructor(data?: PartialMessage<Enrollments>) { 801 super(); 802 proto3.util.initPartial(data, this); 803 } 804 805 static readonly runtime: typeof proto3 = proto3; 806 static readonly typeName = "qf.Enrollments"; 807 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 808 { no: 1, name: "enrollments", kind: "message", T: Enrollment, repeated: true }, 809 ]); 810 811 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Enrollments { 812 return new Enrollments().fromBinary(bytes, options); 813 } 814 815 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Enrollments { 816 return new Enrollments().fromJson(jsonValue, options); 817 } 818 819 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Enrollments { 820 return new Enrollments().fromJsonString(jsonString, options); 821 } 822 823 static equals(a: Enrollments | PlainMessage<Enrollments> | undefined, b: Enrollments | PlainMessage<Enrollments> | undefined): boolean { 824 return proto3.util.equals(Enrollments, a, b); 825 } 826 } 827 828 /** 829 * @generated from message qf.Assignment 830 */ 831 export class Assignment extends Message<Assignment> { 832 /** 833 * @generated from field: uint64 ID = 1; 834 */ 835 ID = protoInt64.zero; 836 837 /** 838 * foreign key 839 * 840 * @generated from field: uint64 CourseID = 2; 841 */ 842 CourseID = protoInt64.zero; 843 844 /** 845 * @generated from field: string name = 3; 846 */ 847 name = ""; 848 849 /** 850 * @generated from field: google.protobuf.Timestamp deadline = 4; 851 */ 852 deadline?: Timestamp; 853 854 /** 855 * @generated from field: bool autoApprove = 5; 856 */ 857 autoApprove = false; 858 859 /** 860 * @generated from field: uint32 order = 6; 861 */ 862 order = 0; 863 864 /** 865 * @generated from field: bool isGroupLab = 7; 866 */ 867 isGroupLab = false; 868 869 /** 870 * minimal score limit for auto approval 871 * 872 * @generated from field: uint32 scoreLimit = 8; 873 */ 874 scoreLimit = 0; 875 876 /** 877 * number of reviewers that will review submissions for this assignment 878 * 879 * @generated from field: uint32 reviewers = 9; 880 */ 881 reviewers = 0; 882 883 /** 884 * container timeout for this assignment 885 * 886 * @generated from field: uint32 containerTimeout = 10; 887 */ 888 containerTimeout = 0; 889 890 /** 891 * submissions produced for this assignment 892 * 893 * @generated from field: repeated qf.Submission submissions = 11; 894 */ 895 submissions: Submission[] = []; 896 897 /** 898 * tasks associated with this assignment 899 * 900 * @generated from field: repeated qf.Task tasks = 12; 901 */ 902 tasks: Task[] = []; 903 904 /** 905 * grading benchmarks for this assignment 906 * 907 * @generated from field: repeated qf.GradingBenchmark gradingBenchmarks = 13; 908 */ 909 gradingBenchmarks: GradingBenchmark[] = []; 910 911 constructor(data?: PartialMessage<Assignment>) { 912 super(); 913 proto3.util.initPartial(data, this); 914 } 915 916 static readonly runtime: typeof proto3 = proto3; 917 static readonly typeName = "qf.Assignment"; 918 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 919 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 920 { no: 2, name: "CourseID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 921 { no: 3, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 922 { no: 4, name: "deadline", kind: "message", T: Timestamp }, 923 { no: 5, name: "autoApprove", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, 924 { no: 6, name: "order", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 925 { no: 7, name: "isGroupLab", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, 926 { no: 8, name: "scoreLimit", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 927 { no: 9, name: "reviewers", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 928 { no: 10, name: "containerTimeout", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 929 { no: 11, name: "submissions", kind: "message", T: Submission, repeated: true }, 930 { no: 12, name: "tasks", kind: "message", T: Task, repeated: true }, 931 { no: 13, name: "gradingBenchmarks", kind: "message", T: GradingBenchmark, repeated: true }, 932 ]); 933 934 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Assignment { 935 return new Assignment().fromBinary(bytes, options); 936 } 937 938 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Assignment { 939 return new Assignment().fromJson(jsonValue, options); 940 } 941 942 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Assignment { 943 return new Assignment().fromJsonString(jsonString, options); 944 } 945 946 static equals(a: Assignment | PlainMessage<Assignment> | undefined, b: Assignment | PlainMessage<Assignment> | undefined): boolean { 947 return proto3.util.equals(Assignment, a, b); 948 } 949 } 950 951 /** 952 * @generated from message qf.Task 953 */ 954 export class Task extends Message<Task> { 955 /** 956 * @generated from field: uint64 ID = 1; 957 */ 958 ID = protoInt64.zero; 959 960 /** 961 * foreign key 962 * 963 * @generated from field: uint64 assignmentID = 2; 964 */ 965 assignmentID = protoInt64.zero; 966 967 /** 968 * @generated from field: uint32 assignmentOrder = 3; 969 */ 970 assignmentOrder = 0; 971 972 /** 973 * @generated from field: string title = 4; 974 */ 975 title = ""; 976 977 /** 978 * @generated from field: string body = 5; 979 */ 980 body = ""; 981 982 /** 983 * @generated from field: string name = 6; 984 */ 985 name = ""; 986 987 /** 988 * Issues that use this task as a benchmark 989 * 990 * @generated from field: repeated qf.Issue issues = 7; 991 */ 992 issues: Issue[] = []; 993 994 constructor(data?: PartialMessage<Task>) { 995 super(); 996 proto3.util.initPartial(data, this); 997 } 998 999 static readonly runtime: typeof proto3 = proto3; 1000 static readonly typeName = "qf.Task"; 1001 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1002 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1003 { no: 2, name: "assignmentID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1004 { no: 3, name: "assignmentOrder", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 1005 { no: 4, name: "title", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1006 { no: 5, name: "body", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1007 { no: 6, name: "name", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1008 { no: 7, name: "issues", kind: "message", T: Issue, repeated: true }, 1009 ]); 1010 1011 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Task { 1012 return new Task().fromBinary(bytes, options); 1013 } 1014 1015 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Task { 1016 return new Task().fromJson(jsonValue, options); 1017 } 1018 1019 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Task { 1020 return new Task().fromJsonString(jsonString, options); 1021 } 1022 1023 static equals(a: Task | PlainMessage<Task> | undefined, b: Task | PlainMessage<Task> | undefined): boolean { 1024 return proto3.util.equals(Task, a, b); 1025 } 1026 } 1027 1028 /** 1029 * @generated from message qf.Issue 1030 */ 1031 export class Issue extends Message<Issue> { 1032 /** 1033 * @generated from field: uint64 ID = 1; 1034 */ 1035 ID = protoInt64.zero; 1036 1037 /** 1038 * Represents the internal ID of a repository 1039 * 1040 * @generated from field: uint64 repositoryID = 2; 1041 */ 1042 repositoryID = protoInt64.zero; 1043 1044 /** 1045 * Task that this issue draws its content from 1046 * 1047 * @generated from field: uint64 taskID = 3; 1048 */ 1049 taskID = protoInt64.zero; 1050 1051 /** 1052 * Issue number on scm. Needed for associating db issue with scm issue 1053 * 1054 * @generated from field: uint64 ScmIssueNumber = 4; 1055 */ 1056 ScmIssueNumber = protoInt64.zero; 1057 1058 constructor(data?: PartialMessage<Issue>) { 1059 super(); 1060 proto3.util.initPartial(data, this); 1061 } 1062 1063 static readonly runtime: typeof proto3 = proto3; 1064 static readonly typeName = "qf.Issue"; 1065 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1066 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1067 { no: 2, name: "repositoryID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1068 { no: 3, name: "taskID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1069 { no: 4, name: "ScmIssueNumber", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1070 ]); 1071 1072 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Issue { 1073 return new Issue().fromBinary(bytes, options); 1074 } 1075 1076 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Issue { 1077 return new Issue().fromJson(jsonValue, options); 1078 } 1079 1080 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Issue { 1081 return new Issue().fromJsonString(jsonString, options); 1082 } 1083 1084 static equals(a: Issue | PlainMessage<Issue> | undefined, b: Issue | PlainMessage<Issue> | undefined): boolean { 1085 return proto3.util.equals(Issue, a, b); 1086 } 1087 } 1088 1089 /** 1090 * @generated from message qf.PullRequest 1091 */ 1092 export class PullRequest extends Message<PullRequest> { 1093 /** 1094 * @generated from field: uint64 ID = 1; 1095 */ 1096 ID = protoInt64.zero; 1097 1098 /** 1099 * Represents the scm repository ID 1100 * 1101 * @generated from field: uint64 ScmRepositoryID = 2; 1102 */ 1103 ScmRepositoryID = protoInt64.zero; 1104 1105 /** 1106 * Foreign key 1107 * 1108 * @generated from field: uint64 taskID = 3; 1109 */ 1110 taskID = protoInt64.zero; 1111 1112 /** 1113 * Foreign key 1114 * 1115 * @generated from field: uint64 issueID = 4; 1116 */ 1117 issueID = protoInt64.zero; 1118 1119 /** 1120 * The user who owns this PR 1121 * 1122 * @generated from field: uint64 userID = 5; 1123 */ 1124 userID = protoInt64.zero; 1125 1126 /** 1127 * Scm ID of the comment used for automatic feedback 1128 * 1129 * @generated from field: uint64 ScmCommentID = 6; 1130 */ 1131 ScmCommentID = protoInt64.zero; 1132 1133 /** 1134 * The source branch for this pull request 1135 * 1136 * @generated from field: string sourceBranch = 7; 1137 */ 1138 sourceBranch = ""; 1139 1140 /** 1141 * Pull request number 1142 * 1143 * @generated from field: uint64 number = 8; 1144 */ 1145 number = protoInt64.zero; 1146 1147 /** 1148 * @generated from field: qf.PullRequest.Stage stage = 9; 1149 */ 1150 stage = PullRequest_Stage.NONE; 1151 1152 constructor(data?: PartialMessage<PullRequest>) { 1153 super(); 1154 proto3.util.initPartial(data, this); 1155 } 1156 1157 static readonly runtime: typeof proto3 = proto3; 1158 static readonly typeName = "qf.PullRequest"; 1159 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1160 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1161 { no: 2, name: "ScmRepositoryID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1162 { no: 3, name: "taskID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1163 { no: 4, name: "issueID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1164 { no: 5, name: "userID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1165 { no: 6, name: "ScmCommentID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1166 { no: 7, name: "sourceBranch", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1167 { no: 8, name: "number", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1168 { no: 9, name: "stage", kind: "enum", T: proto3.getEnumType(PullRequest_Stage) }, 1169 ]); 1170 1171 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): PullRequest { 1172 return new PullRequest().fromBinary(bytes, options); 1173 } 1174 1175 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): PullRequest { 1176 return new PullRequest().fromJson(jsonValue, options); 1177 } 1178 1179 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): PullRequest { 1180 return new PullRequest().fromJsonString(jsonString, options); 1181 } 1182 1183 static equals(a: PullRequest | PlainMessage<PullRequest> | undefined, b: PullRequest | PlainMessage<PullRequest> | undefined): boolean { 1184 return proto3.util.equals(PullRequest, a, b); 1185 } 1186 } 1187 1188 /** 1189 * @generated from enum qf.PullRequest.Stage 1190 */ 1191 export enum PullRequest_Stage { 1192 /** 1193 * @generated from enum value: NONE = 0; 1194 */ 1195 NONE = 0, 1196 1197 /** 1198 * @generated from enum value: DRAFT = 1; 1199 */ 1200 DRAFT = 1, 1201 1202 /** 1203 * @generated from enum value: REVIEW = 2; 1204 */ 1205 REVIEW = 2, 1206 1207 /** 1208 * @generated from enum value: APPROVED = 3; 1209 */ 1210 APPROVED = 3, 1211 } 1212 // Retrieve enum metadata with: proto3.getEnumType(PullRequest_Stage) 1213 proto3.util.setEnumType(PullRequest_Stage, "qf.PullRequest.Stage", [ 1214 { no: 0, name: "NONE" }, 1215 { no: 1, name: "DRAFT" }, 1216 { no: 2, name: "REVIEW" }, 1217 { no: 3, name: "APPROVED" }, 1218 ]); 1219 1220 /** 1221 * @generated from message qf.Assignments 1222 */ 1223 export class Assignments extends Message<Assignments> { 1224 /** 1225 * @generated from field: repeated qf.Assignment assignments = 1; 1226 */ 1227 assignments: Assignment[] = []; 1228 1229 constructor(data?: PartialMessage<Assignments>) { 1230 super(); 1231 proto3.util.initPartial(data, this); 1232 } 1233 1234 static readonly runtime: typeof proto3 = proto3; 1235 static readonly typeName = "qf.Assignments"; 1236 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1237 { no: 1, name: "assignments", kind: "message", T: Assignment, repeated: true }, 1238 ]); 1239 1240 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Assignments { 1241 return new Assignments().fromBinary(bytes, options); 1242 } 1243 1244 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Assignments { 1245 return new Assignments().fromJson(jsonValue, options); 1246 } 1247 1248 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Assignments { 1249 return new Assignments().fromJsonString(jsonString, options); 1250 } 1251 1252 static equals(a: Assignments | PlainMessage<Assignments> | undefined, b: Assignments | PlainMessage<Assignments> | undefined): boolean { 1253 return proto3.util.equals(Assignments, a, b); 1254 } 1255 } 1256 1257 /** 1258 * @generated from message qf.Submission 1259 */ 1260 export class Submission extends Message<Submission> { 1261 /** 1262 * @generated from field: uint64 ID = 1; 1263 */ 1264 ID = protoInt64.zero; 1265 1266 /** 1267 * foreign key 1268 * 1269 * @generated from field: uint64 AssignmentID = 2; 1270 */ 1271 AssignmentID = protoInt64.zero; 1272 1273 /** 1274 * @generated from field: uint64 userID = 3; 1275 */ 1276 userID = protoInt64.zero; 1277 1278 /** 1279 * @generated from field: uint64 groupID = 4; 1280 */ 1281 groupID = protoInt64.zero; 1282 1283 /** 1284 * @generated from field: uint32 score = 5; 1285 */ 1286 score = 0; 1287 1288 /** 1289 * @generated from field: string commitHash = 6; 1290 */ 1291 commitHash = ""; 1292 1293 /** 1294 * true => feedback is visible to the student or group members 1295 * 1296 * @generated from field: bool released = 7; 1297 */ 1298 released = false; 1299 1300 /** 1301 * @generated from field: qf.Submission.Status status = 8; 1302 */ 1303 status = Submission_Status.NONE; 1304 1305 /** 1306 * @generated from field: google.protobuf.Timestamp approvedDate = 9; 1307 */ 1308 approvedDate?: Timestamp; 1309 1310 /** 1311 * reviews produced for this submission 1312 * 1313 * @generated from field: repeated qf.Review reviews = 10; 1314 */ 1315 reviews: Review[] = []; 1316 1317 /** 1318 * build info for tests 1319 * 1320 * @generated from field: score.BuildInfo BuildInfo = 11; 1321 */ 1322 BuildInfo?: BuildInfo; 1323 1324 /** 1325 * list of scores for different tests 1326 * 1327 * @generated from field: repeated score.Score Scores = 12; 1328 */ 1329 Scores: Score[] = []; 1330 1331 constructor(data?: PartialMessage<Submission>) { 1332 super(); 1333 proto3.util.initPartial(data, this); 1334 } 1335 1336 static readonly runtime: typeof proto3 = proto3; 1337 static readonly typeName = "qf.Submission"; 1338 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1339 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1340 { no: 2, name: "AssignmentID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1341 { no: 3, name: "userID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1342 { no: 4, name: "groupID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1343 { no: 5, name: "score", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 1344 { no: 6, name: "commitHash", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1345 { no: 7, name: "released", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, 1346 { no: 8, name: "status", kind: "enum", T: proto3.getEnumType(Submission_Status) }, 1347 { no: 9, name: "approvedDate", kind: "message", T: Timestamp }, 1348 { no: 10, name: "reviews", kind: "message", T: Review, repeated: true }, 1349 { no: 11, name: "BuildInfo", kind: "message", T: BuildInfo }, 1350 { no: 12, name: "Scores", kind: "message", T: Score, repeated: true }, 1351 ]); 1352 1353 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Submission { 1354 return new Submission().fromBinary(bytes, options); 1355 } 1356 1357 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Submission { 1358 return new Submission().fromJson(jsonValue, options); 1359 } 1360 1361 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Submission { 1362 return new Submission().fromJsonString(jsonString, options); 1363 } 1364 1365 static equals(a: Submission | PlainMessage<Submission> | undefined, b: Submission | PlainMessage<Submission> | undefined): boolean { 1366 return proto3.util.equals(Submission, a, b); 1367 } 1368 } 1369 1370 /** 1371 * @generated from enum qf.Submission.Status 1372 */ 1373 export enum Submission_Status { 1374 /** 1375 * @generated from enum value: NONE = 0; 1376 */ 1377 NONE = 0, 1378 1379 /** 1380 * @generated from enum value: APPROVED = 1; 1381 */ 1382 APPROVED = 1, 1383 1384 /** 1385 * @generated from enum value: REJECTED = 2; 1386 */ 1387 REJECTED = 2, 1388 1389 /** 1390 * @generated from enum value: REVISION = 3; 1391 */ 1392 REVISION = 3, 1393 } 1394 // Retrieve enum metadata with: proto3.getEnumType(Submission_Status) 1395 proto3.util.setEnumType(Submission_Status, "qf.Submission.Status", [ 1396 { no: 0, name: "NONE" }, 1397 { no: 1, name: "APPROVED" }, 1398 { no: 2, name: "REJECTED" }, 1399 { no: 3, name: "REVISION" }, 1400 ]); 1401 1402 /** 1403 * @generated from message qf.Submissions 1404 */ 1405 export class Submissions extends Message<Submissions> { 1406 /** 1407 * @generated from field: repeated qf.Submission submissions = 1; 1408 */ 1409 submissions: Submission[] = []; 1410 1411 constructor(data?: PartialMessage<Submissions>) { 1412 super(); 1413 proto3.util.initPartial(data, this); 1414 } 1415 1416 static readonly runtime: typeof proto3 = proto3; 1417 static readonly typeName = "qf.Submissions"; 1418 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1419 { no: 1, name: "submissions", kind: "message", T: Submission, repeated: true }, 1420 ]); 1421 1422 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Submissions { 1423 return new Submissions().fromBinary(bytes, options); 1424 } 1425 1426 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Submissions { 1427 return new Submissions().fromJson(jsonValue, options); 1428 } 1429 1430 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Submissions { 1431 return new Submissions().fromJsonString(jsonString, options); 1432 } 1433 1434 static equals(a: Submissions | PlainMessage<Submissions> | undefined, b: Submissions | PlainMessage<Submissions> | undefined): boolean { 1435 return proto3.util.equals(Submissions, a, b); 1436 } 1437 } 1438 1439 /** 1440 * @generated from message qf.GradingBenchmark 1441 */ 1442 export class GradingBenchmark extends Message<GradingBenchmark> { 1443 /** 1444 * @generated from field: uint64 ID = 1; 1445 */ 1446 ID = protoInt64.zero; 1447 1448 /** 1449 * foreign key 1450 * 1451 * @generated from field: uint64 CourseID = 2; 1452 */ 1453 CourseID = protoInt64.zero; 1454 1455 /** 1456 * foreign key 1457 * 1458 * @generated from field: uint64 AssignmentID = 3; 1459 */ 1460 AssignmentID = protoInt64.zero; 1461 1462 /** 1463 * foreign key 1464 * 1465 * @generated from field: uint64 ReviewID = 4; 1466 */ 1467 ReviewID = protoInt64.zero; 1468 1469 /** 1470 * @generated from field: string heading = 5; 1471 */ 1472 heading = ""; 1473 1474 /** 1475 * @generated from field: string comment = 6; 1476 */ 1477 comment = ""; 1478 1479 /** 1480 * @generated from field: repeated qf.GradingCriterion criteria = 7; 1481 */ 1482 criteria: GradingCriterion[] = []; 1483 1484 constructor(data?: PartialMessage<GradingBenchmark>) { 1485 super(); 1486 proto3.util.initPartial(data, this); 1487 } 1488 1489 static readonly runtime: typeof proto3 = proto3; 1490 static readonly typeName = "qf.GradingBenchmark"; 1491 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1492 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1493 { no: 2, name: "CourseID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1494 { no: 3, name: "AssignmentID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1495 { no: 4, name: "ReviewID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1496 { no: 5, name: "heading", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1497 { no: 6, name: "comment", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1498 { no: 7, name: "criteria", kind: "message", T: GradingCriterion, repeated: true }, 1499 ]); 1500 1501 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GradingBenchmark { 1502 return new GradingBenchmark().fromBinary(bytes, options); 1503 } 1504 1505 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GradingBenchmark { 1506 return new GradingBenchmark().fromJson(jsonValue, options); 1507 } 1508 1509 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GradingBenchmark { 1510 return new GradingBenchmark().fromJsonString(jsonString, options); 1511 } 1512 1513 static equals(a: GradingBenchmark | PlainMessage<GradingBenchmark> | undefined, b: GradingBenchmark | PlainMessage<GradingBenchmark> | undefined): boolean { 1514 return proto3.util.equals(GradingBenchmark, a, b); 1515 } 1516 } 1517 1518 /** 1519 * @generated from message qf.Benchmarks 1520 */ 1521 export class Benchmarks extends Message<Benchmarks> { 1522 /** 1523 * @generated from field: repeated qf.GradingBenchmark benchmarks = 1; 1524 */ 1525 benchmarks: GradingBenchmark[] = []; 1526 1527 constructor(data?: PartialMessage<Benchmarks>) { 1528 super(); 1529 proto3.util.initPartial(data, this); 1530 } 1531 1532 static readonly runtime: typeof proto3 = proto3; 1533 static readonly typeName = "qf.Benchmarks"; 1534 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1535 { no: 1, name: "benchmarks", kind: "message", T: GradingBenchmark, repeated: true }, 1536 ]); 1537 1538 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Benchmarks { 1539 return new Benchmarks().fromBinary(bytes, options); 1540 } 1541 1542 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Benchmarks { 1543 return new Benchmarks().fromJson(jsonValue, options); 1544 } 1545 1546 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Benchmarks { 1547 return new Benchmarks().fromJsonString(jsonString, options); 1548 } 1549 1550 static equals(a: Benchmarks | PlainMessage<Benchmarks> | undefined, b: Benchmarks | PlainMessage<Benchmarks> | undefined): boolean { 1551 return proto3.util.equals(Benchmarks, a, b); 1552 } 1553 } 1554 1555 /** 1556 * @generated from message qf.GradingCriterion 1557 */ 1558 export class GradingCriterion extends Message<GradingCriterion> { 1559 /** 1560 * @generated from field: uint64 ID = 1; 1561 */ 1562 ID = protoInt64.zero; 1563 1564 /** 1565 * foreign key 1566 * 1567 * @generated from field: uint64 BenchmarkID = 2; 1568 */ 1569 BenchmarkID = protoInt64.zero; 1570 1571 /** 1572 * foreign key 1573 * 1574 * @generated from field: uint64 CourseID = 3; 1575 */ 1576 CourseID = protoInt64.zero; 1577 1578 /** 1579 * @generated from field: uint64 points = 4; 1580 */ 1581 points = protoInt64.zero; 1582 1583 /** 1584 * @generated from field: string description = 5; 1585 */ 1586 description = ""; 1587 1588 /** 1589 * @generated from field: qf.GradingCriterion.Grade grade = 6; 1590 */ 1591 grade = GradingCriterion_Grade.NONE; 1592 1593 /** 1594 * @generated from field: string comment = 7; 1595 */ 1596 comment = ""; 1597 1598 constructor(data?: PartialMessage<GradingCriterion>) { 1599 super(); 1600 proto3.util.initPartial(data, this); 1601 } 1602 1603 static readonly runtime: typeof proto3 = proto3; 1604 static readonly typeName = "qf.GradingCriterion"; 1605 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1606 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1607 { no: 2, name: "BenchmarkID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1608 { no: 3, name: "CourseID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1609 { no: 4, name: "points", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1610 { no: 5, name: "description", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1611 { no: 6, name: "grade", kind: "enum", T: proto3.getEnumType(GradingCriterion_Grade) }, 1612 { no: 7, name: "comment", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1613 ]); 1614 1615 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GradingCriterion { 1616 return new GradingCriterion().fromBinary(bytes, options); 1617 } 1618 1619 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GradingCriterion { 1620 return new GradingCriterion().fromJson(jsonValue, options); 1621 } 1622 1623 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GradingCriterion { 1624 return new GradingCriterion().fromJsonString(jsonString, options); 1625 } 1626 1627 static equals(a: GradingCriterion | PlainMessage<GradingCriterion> | undefined, b: GradingCriterion | PlainMessage<GradingCriterion> | undefined): boolean { 1628 return proto3.util.equals(GradingCriterion, a, b); 1629 } 1630 } 1631 1632 /** 1633 * @generated from enum qf.GradingCriterion.Grade 1634 */ 1635 export enum GradingCriterion_Grade { 1636 /** 1637 * @generated from enum value: NONE = 0; 1638 */ 1639 NONE = 0, 1640 1641 /** 1642 * @generated from enum value: FAILED = 1; 1643 */ 1644 FAILED = 1, 1645 1646 /** 1647 * @generated from enum value: PASSED = 2; 1648 */ 1649 PASSED = 2, 1650 } 1651 // Retrieve enum metadata with: proto3.getEnumType(GradingCriterion_Grade) 1652 proto3.util.setEnumType(GradingCriterion_Grade, "qf.GradingCriterion.Grade", [ 1653 { no: 0, name: "NONE" }, 1654 { no: 1, name: "FAILED" }, 1655 { no: 2, name: "PASSED" }, 1656 ]); 1657 1658 /** 1659 * @generated from message qf.Review 1660 */ 1661 export class Review extends Message<Review> { 1662 /** 1663 * @generated from field: uint64 ID = 1; 1664 */ 1665 ID = protoInt64.zero; 1666 1667 /** 1668 * foreign key 1669 * 1670 * @generated from field: uint64 SubmissionID = 2; 1671 */ 1672 SubmissionID = protoInt64.zero; 1673 1674 /** 1675 * UserID of the reviewer 1676 * 1677 * @generated from field: uint64 ReviewerID = 3; 1678 */ 1679 ReviewerID = protoInt64.zero; 1680 1681 /** 1682 * @generated from field: string feedback = 4; 1683 */ 1684 feedback = ""; 1685 1686 /** 1687 * @generated from field: bool ready = 5; 1688 */ 1689 ready = false; 1690 1691 /** 1692 * @generated from field: uint32 score = 6; 1693 */ 1694 score = 0; 1695 1696 /** 1697 * @generated from field: repeated qf.GradingBenchmark gradingBenchmarks = 7; 1698 */ 1699 gradingBenchmarks: GradingBenchmark[] = []; 1700 1701 /** 1702 * @generated from field: google.protobuf.Timestamp edited = 8; 1703 */ 1704 edited?: Timestamp; 1705 1706 constructor(data?: PartialMessage<Review>) { 1707 super(); 1708 proto3.util.initPartial(data, this); 1709 } 1710 1711 static readonly runtime: typeof proto3 = proto3; 1712 static readonly typeName = "qf.Review"; 1713 static readonly fields: FieldList = proto3.util.newFieldList(() => [ 1714 { no: 1, name: "ID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1715 { no: 2, name: "SubmissionID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1716 { no: 3, name: "ReviewerID", kind: "scalar", T: 4 /* ScalarType.UINT64 */ }, 1717 { no: 4, name: "feedback", kind: "scalar", T: 9 /* ScalarType.STRING */ }, 1718 { no: 5, name: "ready", kind: "scalar", T: 8 /* ScalarType.BOOL */ }, 1719 { no: 6, name: "score", kind: "scalar", T: 13 /* ScalarType.UINT32 */ }, 1720 { no: 7, name: "gradingBenchmarks", kind: "message", T: GradingBenchmark, repeated: true }, 1721 { no: 8, name: "edited", kind: "message", T: Timestamp }, 1722 ]); 1723 1724 static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): Review { 1725 return new Review().fromBinary(bytes, options); 1726 } 1727 1728 static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): Review { 1729 return new Review().fromJson(jsonValue, options); 1730 } 1731 1732 static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): Review { 1733 return new Review().fromJsonString(jsonString, options); 1734 } 1735 1736 static equals(a: Review | PlainMessage<Review> | undefined, b: Review | PlainMessage<Review> | undefined): boolean { 1737 return proto3.util.equals(Review, a, b); 1738 } 1739 } 1740