12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091 |
- "use strict";
- Object.defineProperty(exports, "__esModule", { value: true });
- exports.cast_de_nrw_schule_svws_core_data_gost_GostFachwahl = exports.GostFachwahl = void 0;
- const JavaObject_1 = require("../../../java/lang/JavaObject");
- class GostFachwahl extends JavaObject_1.JavaObject {
- id = -1;
- fachID = -1;
- halbjahrID = -1;
- schuelerID = -1;
- schuelerNachname = "";
- schuelerVorname = "";
- kursartID = -1;
- constructor() {
- super();
- }
- isTranspiledInstanceOf(name) {
- return ['de.nrw.schule.svws.core.data.gost.GostFachwahl'].includes(name);
- }
- static transpilerFromJSON(json) {
- const obj = JSON.parse(json);
- const result = new GostFachwahl();
- if (typeof obj.id === "undefined")
- throw new Error('invalid json format, missing attribute id');
- result.id = obj.id;
- if (typeof obj.fachID === "undefined")
- throw new Error('invalid json format, missing attribute fachID');
- result.fachID = obj.fachID;
- if (typeof obj.halbjahrID === "undefined")
- throw new Error('invalid json format, missing attribute halbjahrID');
- result.halbjahrID = obj.halbjahrID;
- if (typeof obj.schuelerID === "undefined")
- throw new Error('invalid json format, missing attribute schuelerID');
- result.schuelerID = obj.schuelerID;
- if (typeof obj.schuelerNachname === "undefined")
- throw new Error('invalid json format, missing attribute schuelerNachname');
- result.schuelerNachname = obj.schuelerNachname;
- if (typeof obj.schuelerVorname === "undefined")
- throw new Error('invalid json format, missing attribute schuelerVorname');
- result.schuelerVorname = obj.schuelerVorname;
- if (typeof obj.kursartID === "undefined")
- throw new Error('invalid json format, missing attribute kursartID');
- result.kursartID = obj.kursartID;
- return result;
- }
- static transpilerToJSON(obj) {
- let result = '{';
- result += '"id" : ' + obj.id + ',';
- result += '"fachID" : ' + obj.fachID + ',';
- result += '"halbjahrID" : ' + obj.halbjahrID + ',';
- result += '"schuelerID" : ' + obj.schuelerID + ',';
- result += '"schuelerNachname" : ' + '"' + obj.schuelerNachname.valueOf() + '"' + ',';
- result += '"schuelerVorname" : ' + '"' + obj.schuelerVorname.valueOf() + '"' + ',';
- result += '"kursartID" : ' + obj.kursartID + ',';
- result = result.slice(0, -1);
- result += '}';
- return result;
- }
- static transpilerToJSONPatch(obj) {
- let result = '{';
- if (typeof obj.id !== "undefined") {
- result += '"id" : ' + obj.id + ',';
- }
- if (typeof obj.fachID !== "undefined") {
- result += '"fachID" : ' + obj.fachID + ',';
- }
- if (typeof obj.halbjahrID !== "undefined") {
- result += '"halbjahrID" : ' + obj.halbjahrID + ',';
- }
- if (typeof obj.schuelerID !== "undefined") {
- result += '"schuelerID" : ' + obj.schuelerID + ',';
- }
- if (typeof obj.schuelerNachname !== "undefined") {
- result += '"schuelerNachname" : ' + '"' + obj.schuelerNachname.valueOf() + '"' + ',';
- }
- if (typeof obj.schuelerVorname !== "undefined") {
- result += '"schuelerVorname" : ' + '"' + obj.schuelerVorname.valueOf() + '"' + ',';
- }
- if (typeof obj.kursartID !== "undefined") {
- result += '"kursartID" : ' + obj.kursartID + ',';
- }
- result = result.slice(0, -1);
- result += '}';
- return result;
- }
- }
- exports.GostFachwahl = GostFachwahl;
- function cast_de_nrw_schule_svws_core_data_gost_GostFachwahl(obj) {
- return obj;
- }
- exports.cast_de_nrw_schule_svws_core_data_gost_GostFachwahl = cast_de_nrw_schule_svws_core_data_gost_GostFachwahl;
- //# sourceMappingURL=GostFachwahl.js.map
|