studium 0.18.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/README.md +3310 -0
- data/bin/all_passed_exams +14 -0
- data/bin/check_description_of_these_lectures +7 -0
- data/bin/curriculum_module_displayer +7 -0
- data/bin/cycle +7 -0
- data/bin/d10 +7 -0
- data/bin/d100 +7 -0
- data/bin/d15 +7 -0
- data/bin/d150 +7 -0
- data/bin/d20 +7 -0
- data/bin/d25 +7 -0
- data/bin/d3 +7 -0
- data/bin/d30 +7 -0
- data/bin/d5 +7 -0
- data/bin/determine_curricula +7 -0
- data/bin/display_lecture_url +7 -0
- data/bin/exam_registration_at +7 -0
- data/bin/exam_statistics +7 -0
- data/bin/exams_per_month +9 -0
- data/bin/finished_exams_at_this_university +7 -0
- data/bin/flashcards +7 -0
- data/bin/from_curriculum_id_to_university +9 -0
- data/bin/location_to_this_exam_topic.rb +7 -0
- data/bin/mandatory_continuous_assessment +7 -0
- data/bin/mandatory_upcoming_courses +10 -0
- data/bin/n_ECTS +7 -0
- data/bin/n_exam_questions_already_answered +15 -0
- data/bin/names_of_all_solved_exams +7 -0
- data/bin/not_completed_exams +7 -0
- data/bin/nquestions +7 -0
- data/bin/nsolved +7 -0
- data/bin/open_last_exam_question_asked_file +7 -0
- data/bin/passed_exams +7 -0
- data/bin/passed_pr/303/274fungsimmanente_courses +7 -0
- data/bin/passed_this_exam_on +10 -0
- data/bin/pdf_for +7 -0
- data/bin/question_answer +7 -0
- data/bin/random_exam_topic +7 -0
- data/bin/registered_for_this_exam +15 -0
- data/bin/report_solved_topics +7 -0
- data/bin/return_n_ects_from_this_file +7 -0
- data/bin/return_n_questions_solved_in_total +7 -0
- data/bin/rti_conflict +7 -0
- data/bin/search_for_n_ects +7 -0
- data/bin/show_lectures_on_the_commandline +7 -0
- data/bin/show_passed_exams_having_this_grade +7 -0
- data/bin/show_themes +7 -0
- data/bin/solved +9 -0
- data/bin/solved_ects +7 -0
- data/bin/studienkennzahl +7 -0
- data/bin/studium +7 -0
- data/bin/studium_actions +7 -0
- data/bin/studium_skeleton +7 -0
- data/bin/ufind +7 -0
- data/bin/upcoming_exams +7 -0
- data/bin/week_parser +7 -0
- data/doc/ECTS_CONSIDERATIONS/ECTS_CONSIDERATIONS.md +85 -0
- data/doc/HOW_TO_DETERMINE_WHICH_PART_IS_THE_QUESTION_AND_WHICH_PART_IS_THE_ANSWER/HOW_TO_DETERMINE_WHICH_PART_IS_THE_QUESTION_AND_WHICH_PART_IS_THE_ANSWER.md +44 -0
- data/doc/README.gen +3263 -0
- data/doc/SQL_database_specification/SQL_database_specification.md +46 -0
- data/doc/deprecated_components/deprecated_components.md +46 -0
- data/doc/documentation_for_the_file_lecture_information/documentation_for_the_file_lecture_information.md +311 -0
- data/doc/elegant_colours/elegant_colours.md +21 -0
- data/doc/statistics/yearly_statistics.md +8 -0
- data/doc/todo/todo_for_the_graphical_parts_of_the_studium_gem_including_www_related_aspects.md +92 -0
- data/doc/todo/todo_for_the_studium_gem.md +55 -0
- data/img/STUDIES.png +0 -0
- data/lib/studium/actions/actions.rb +134 -0
- data/lib/studium/autoinclude.rb +7 -0
- data/lib/studium/base/base.rb +3554 -0
- data/lib/studium/base/commandline_arguments_module/commandline_arguments_module.rb +115 -0
- data/lib/studium/base/html_colours_module.rb +632 -0
- data/lib/studium/base/runmode_module/runmode_module.rb +103 -0
- data/lib/studium/c/README.md +2 -0
- data/lib/studium/c/a.out +0 -0
- data/lib/studium/c/obtain_random_entry.c +11 -0
- data/lib/studium/check_and_sanitize/README.md +15 -0
- data/lib/studium/check_and_sanitize/check_curriculum_for_correct_separation_of_bachelor_and_master.rb +141 -0
- data/lib/studium/check_and_sanitize/check_for_all_exam_topics_being_registered.rb +118 -0
- data/lib/studium/check_and_sanitize/check_for_correct_themes_of_each_course.rb +100 -0
- data/lib/studium/check_and_sanitize/check_for_existing_description_of_this_lecture.rb +194 -0
- data/lib/studium/check_and_sanitize/check_important_exams.rb +138 -0
- data/lib/studium/check_and_sanitize/check_the_lecture_information_file.rb +166 -0
- data/lib/studium/check_and_sanitize/correct_all_dates_in_the_file_lecture_information.rb +115 -0
- data/lib/studium/check_and_sanitize/date_sanitizer.rb +350 -0
- data/lib/studium/check_and_sanitize/find_duplicate_lectures.rb +124 -0
- data/lib/studium/check_and_sanitize/missing_priority_entry.rb +44 -0
- data/lib/studium/check_and_sanitize/sanitize_lecture_information.rb +434 -0
- data/lib/studium/colours/colours.rb +1711 -0
- data/lib/studium/commandline/commandline.rb +1848 -0
- data/lib/studium/constants/constants.rb +2063 -0
- data/lib/studium/css/project.css +273 -0
- data/lib/studium/curricula/attribute_lecture_to_curriculum/attribute_boku_lecture_to_curriculum.rb +384 -0
- data/lib/studium/curricula/attribute_lecture_to_curriculum/attribute_lecture_to_curriculum.rb +238 -0
- data/lib/studium/curricula/curricula_from_this_website/curricula_from_this_website.rb +141 -0
- data/lib/studium/curricula/curriculum.rb +213 -0
- data/lib/studium/curricula/curriculum_as_string.rb +280 -0
- data/lib/studium/curricula/curriculum_module_displayer/constants.rb +33 -0
- data/lib/studium/curricula/curriculum_module_displayer/curriculum_module_displayer.rb +417 -0
- data/lib/studium/curricula/curriculum_module_displayer/initialize.rb +25 -0
- data/lib/studium/curricula/curriculum_module_displayer/menu.rb +45 -0
- data/lib/studium/curricula/curriculum_module_displayer/reset.rb +74 -0
- data/lib/studium/curricula/curriculum_module_displayer/run.rb +20 -0
- data/lib/studium/curricula/curriculum_module_displayer/set_use_this_curriculum.rb +93 -0
- data/lib/studium/curricula/curriculum_module_displayer/show_and_report.rb +190 -0
- data/lib/studium/curricula/determine_curricula/constants.rb +11 -0
- data/lib/studium/curricula/determine_curricula/determine_curricula.rb +36 -0
- data/lib/studium/curricula/determine_curricula/help.rb +39 -0
- data/lib/studium/curricula/determine_curricula/initialize.rb +48 -0
- data/lib/studium/curricula/determine_curricula/menu.rb +151 -0
- data/lib/studium/curricula/determine_curricula/misc.rb +403 -0
- data/lib/studium/curricula/determine_curricula/report.rb +141 -0
- data/lib/studium/curricula/determine_curricula/reset.rb +59 -0
- data/lib/studium/curricula/determine_curricula/run.rb +19 -0
- data/lib/studium/curricula/determine_elective_courses_in_this_curriculum.rb +112 -0
- data/lib/studium/curricula/display_bachelor_curricula.rb +90 -0
- data/lib/studium/curricula/handle_curricula/README.md +9 -0
- data/lib/studium/curricula/handle_curricula/handle_curricula.rb +99 -0
- data/lib/studium/curricula/handle_curricula/misc.rb +798 -0
- data/lib/studium/curricula/mitteilungsbl/303/244tter/mitteilungsbl/303/244tter.rb +323 -0
- data/lib/studium/curricula/modules/display_on_the_commandline.rb +319 -0
- data/lib/studium/curricula/modules/return_n_ects_in_this_module.rb +74 -0
- data/lib/studium/curricula/n_percent_solved_in_this_curriculum.rb +73 -0
- data/lib/studium/curricula/prepare_individual_curriculum.rb +304 -0
- data/lib/studium/curricula/random_curriculum_creator/random_curriculum_creator.rb +164 -0
- data/lib/studium/curricula/show_all_unfinished_courses_of_this_curriculum/show_all_unfinished_courses_of_this_curriculum.rb +116 -0
- data/lib/studium/curricula/show_lectures_of_this_curriculum.rb +114 -0
- data/lib/studium/curricula/show_lectures_of_this_curriculum_id/show_lectures_of_this_curriculum_id.rb +554 -0
- data/lib/studium/curricula/show_solved_percentage_among_the_registered_curricula.rb +87 -0
- data/lib/studium/curricula/sorted_individual_curricula.rb +121 -0
- data/lib/studium/ects/boku_ects_splitter.rb +128 -0
- data/lib/studium/ects/ects_per_university/ects_per_university.rb +179 -0
- data/lib/studium/ects/ects_scanner.rb +141 -0
- data/lib/studium/ects/ects_to_university_parser.rb +142 -0
- data/lib/studium/ects/last_entry_is_curriculum.rb +150 -0
- data/lib/studium/ects/n_ects_in_these_lectures.rb +196 -0
- data/lib/studium/ects/n_ects_points_in_mandatory_presence_courses.rb +47 -0
- data/lib/studium/ects/return_n_ects_from_this_file.rb +59 -0
- data/lib/studium/ects/return_n_ects_from_this_url.rb +197 -0
- data/lib/studium/ects/search_for_n_ects/search_for_n_ects.rb +719 -0
- data/lib/studium/ects/show_completed_ects_in_all_curricula.rb +245 -0
- data/lib/studium/ects/show_passed_credits_per_curriculum.rb +276 -0
- data/lib/studium/ects/simple_total_ects_points.rb +135 -0
- data/lib/studium/ects/solved_ects/constants.rb +19 -0
- data/lib/studium/ects/solved_ects/reset.rb +50 -0
- data/lib/studium/ects/solved_ects/solved_ects.rb +325 -0
- data/lib/studium/ects/solved_ects_per_university/reset.rb +25 -0
- data/lib/studium/ects/solved_ects_per_university/solved_ects_per_university.rb +116 -0
- data/lib/studium/ects/still_missing.rb +129 -0
- data/lib/studium/ects/sum_of_ects.rb +144 -0
- data/lib/studium/encoding/encoding.rb +109 -0
- data/lib/studium/exam_topics/RNAi_siRNA_and_miRNA +100 -0
- data/lib/studium/exam_topics/abfall_als_ressource +86 -0
- data/lib/studium/exam_topics/advanced_biochemistry +937 -0
- data/lib/studium/exam_topics/advanced_biotechnology +234 -0
- data/lib/studium/exam_topics/advanced_cellbiology +251 -0
- data/lib/studium/exam_topics/advanced_chemistry +547 -0
- data/lib/studium/exam_topics/advanced_immunology +225 -0
- data/lib/studium/exam_topics/advanced_microbiology +49 -0
- data/lib/studium/exam_topics/advanced_topics_in_plant_sciences +117 -0
- data/lib/studium/exam_topics/advanced_virology +273 -0
- data/lib/studium/exam_topics/ageing +154 -0
- data/lib/studium/exam_topics/agrar_ecology +67 -0
- data/lib/studium/exam_topics/agrarmarkt +73 -0
- data/lib/studium/exam_topics/agrarphysik +35 -0
- data/lib/studium/exam_topics/alcohols +30 -0
- data/lib/studium/exam_topics/algorithms +104 -0
- data/lib/studium/exam_topics/allergie +76 -0
- data/lib/studium/exam_topics/allgemeine_genetik +1006 -0
- data/lib/studium/exam_topics/allgemeine_mikrobiologie +1012 -0
- data/lib/studium/exam_topics/aminoacids +469 -0
- data/lib/studium/exam_topics/analytische_chemie_1 +134 -0
- data/lib/studium/exam_topics/analytische_chemie_2 +31 -0
- data/lib/studium/exam_topics/anatomie +378 -0
- data/lib/studium/exam_topics/anorganische_chemie +357 -0
- data/lib/studium/exam_topics/anthropologie +239 -0
- data/lib/studium/exam_topics/antibodies_and_antigens +790 -0
- data/lib/studium/exam_topics/apoptosis +35 -0
- data/lib/studium/exam_topics/archaea +112 -0
- data/lib/studium/exam_topics/archaeo_viruses +7 -0
- data/lib/studium/exam_topics/archaeology +5 -0
- data/lib/studium/exam_topics/architecture +8 -0
- data/lib/studium/exam_topics/artificial_intelligence +90 -0
- data/lib/studium/exam_topics/atomemissionsspektrometrie +6 -0
- data/lib/studium/exam_topics/audio +11 -0
- data/lib/studium/exam_topics/bacteriophages +266 -0
- data/lib/studium/exam_topics/basic_biochemistry +1008 -0
- data/lib/studium/exam_topics/basic_biotechnology +1011 -0
- data/lib/studium/exam_topics/basic_chemistry +1007 -0
- data/lib/studium/exam_topics/basic_virology +1008 -0
- data/lib/studium/exam_topics/bauwesen +6 -0
- data/lib/studium/exam_topics/betriebssysteme +128 -0
- data/lib/studium/exam_topics/betriebswirtschaftslehre +29 -0
- data/lib/studium/exam_topics/bioanalytik_und_biosensoren +451 -0
- data/lib/studium/exam_topics/biochips +80 -0
- data/lib/studium/exam_topics/bioelektrochemie +57 -0
- data/lib/studium/exam_topics/biofilms +58 -0
- data/lib/studium/exam_topics/bioinformatics +523 -0
- data/lib/studium/exam_topics/biological_therapeutics +156 -0
- data/lib/studium/exam_topics/biologie +152 -0
- data/lib/studium/exam_topics/biomarkers +137 -0
- data/lib/studium/exam_topics/biomaterials +90 -0
- data/lib/studium/exam_topics/biomedical_studies +16 -0
- data/lib/studium/exam_topics/biomembranes +6 -0
- data/lib/studium/exam_topics/bionik +65 -0
- data/lib/studium/exam_topics/biophysik +34 -0
- data/lib/studium/exam_topics/biopolymers +10 -0
- data/lib/studium/exam_topics/bioprozesstechnik +149 -0
- data/lib/studium/exam_topics/bioressourcenmanagement +78 -0
- data/lib/studium/exam_topics/birds +5 -0
- data/lib/studium/exam_topics/bodenkunde +384 -0
- data/lib/studium/exam_topics/bodenmikrobiologie +40 -0
- data/lib/studium/exam_topics/cancerbiology +488 -0
- data/lib/studium/exam_topics/cell_cultures +229 -0
- data/lib/studium/exam_topics/cellbiology +1011 -0
- data/lib/studium/exam_topics/cellular_transport_and_protein_secretion +27 -0
- data/lib/studium/exam_topics/cellular_vesicles +11 -0
- data/lib/studium/exam_topics/cellulose +6 -0
- data/lib/studium/exam_topics/chemische_technologie_anorganischer_stoffe +210 -0
- data/lib/studium/exam_topics/chemische_technologie_organischer_stoffe +25 -0
- data/lib/studium/exam_topics/chemisches_labor +60 -0
- data/lib/studium/exam_topics/chemokines_and_cytokines +45 -0
- data/lib/studium/exam_topics/chemotaxis_quorum_sensing_and_motility_in_prokaryotes +116 -0
- data/lib/studium/exam_topics/citric_acid_cycle +84 -0
- data/lib/studium/exam_topics/clinical_microbiology +520 -0
- data/lib/studium/exam_topics/computer_science +309 -0
- data/lib/studium/exam_topics/computer_vision_and_computer_graphics +15 -0
- data/lib/studium/exam_topics/crispr +51 -0
- data/lib/studium/exam_topics/cyanobacteria +45 -0
- data/lib/studium/exam_topics/cytogenetics_and_chromosome_biology +598 -0
- data/lib/studium/exam_topics/databases_and_sql +126 -0
- data/lib/studium/exam_topics/dna_mutation_and_dna_repair +186 -0
- data/lib/studium/exam_topics/dna_replication +80 -0
- data/lib/studium/exam_topics/ecogenetics +26 -0
- data/lib/studium/exam_topics/ecological_agriculture +12 -0
- data/lib/studium/exam_topics/ecology +332 -0
- data/lib/studium/exam_topics/economy +226 -0
- data/lib/studium/exam_topics/electron_microscopy +7 -0
- data/lib/studium/exam_topics/elektronenmikroskopie +356 -0
- data/lib/studium/exam_topics/elektrophorese +132 -0
- data/lib/studium/exam_topics/elektrotechnik_und_elektrizit/303/244t +42 -0
- data/lib/studium/exam_topics/elisa +55 -0
- data/lib/studium/exam_topics/embryologie_und_entwicklung +657 -0
- data/lib/studium/exam_topics/endospores_and_spores +104 -0
- data/lib/studium/exam_topics/enzymes_and_cofactors +395 -0
- data/lib/studium/exam_topics/epigenetik +188 -0
- data/lib/studium/exam_topics/erste_hilfe +414 -0
- data/lib/studium/exam_topics/ethik +143 -0
- data/lib/studium/exam_topics/evolution_and_evolutionary_genetics +372 -0
- data/lib/studium/exam_topics/excel +7 -0
- data/lib/studium/exam_topics/fish +19 -0
- data/lib/studium/exam_topics/fluorescence_microscopy +10 -0
- data/lib/studium/exam_topics/food_microbiology_and_food_biotechnology +92 -0
- data/lib/studium/exam_topics/forensik +65 -0
- data/lib/studium/exam_topics/forstwirtschaft +53 -0
- data/lib/studium/exam_topics/fortgeschrittene_genetik +692 -0
- data/lib/studium/exam_topics/fortgeschrittene_gentechnik +221 -0
- data/lib/studium/exam_topics/fortgeschrittene_physik +6 -0
- data/lib/studium/exam_topics/fungi +119 -0
- data/lib/studium/exam_topics/genetische_krankheiten +209 -0
- data/lib/studium/exam_topics/genexpression +1008 -0
- data/lib/studium/exam_topics/genomics_and_metagenomics +290 -0
- data/lib/studium/exam_topics/gentechnik_und_praktische_biochemie +961 -0
- data/lib/studium/exam_topics/geochemistry +67 -0
- data/lib/studium/exam_topics/geography +9 -0
- data/lib/studium/exam_topics/geologie_und_mineralogie +624 -0
- data/lib/studium/exam_topics/geometrie +56 -0
- data/lib/studium/exam_topics/geschichte +95 -0
- data/lib/studium/exam_topics/gluconeogenesis +72 -0
- data/lib/studium/exam_topics/glycogen +45 -0
- data/lib/studium/exam_topics/glycolysis +118 -0
- data/lib/studium/exam_topics/glykomik +131 -0
- data/lib/studium/exam_topics/glyoxylatzyklus +31 -0
- data/lib/studium/exam_topics/grassland_cultivation +32 -0
- data/lib/studium/exam_topics/hormone +152 -0
- data/lib/studium/exam_topics/html +8 -0
- data/lib/studium/exam_topics/human_ecology +8 -0
- data/lib/studium/exam_topics/hygiene +224 -0
- data/lib/studium/exam_topics/imaging_and_microscopy +270 -0
- data/lib/studium/exam_topics/immunanalytik +94 -0
- data/lib/studium/exam_topics/immunologie +1011 -0
- data/lib/studium/exam_topics/informatik +117 -0
- data/lib/studium/exam_topics/innate_immunity +52 -0
- data/lib/studium/exam_topics/insekten +66 -0
- data/lib/studium/exam_topics/insulin_and_diabetes +57 -0
- data/lib/studium/exam_topics/java +624 -0
- data/lib/studium/exam_topics/javascript +29 -0
- data/lib/studium/exam_topics/klima +6 -0
- data/lib/studium/exam_topics/kryptographie +10 -0
- data/lib/studium/exam_topics/landtechnik +26 -0
- data/lib/studium/exam_topics/lebensmittel_und_getr/303/244nke +224 -0
- data/lib/studium/exam_topics/lebensmitteltechnologie +16 -0
- data/lib/studium/exam_topics/light_microscopy +19 -0
- data/lib/studium/exam_topics/linux_and_unix +36 -0
- data/lib/studium/exam_topics/lipids +145 -0
- data/lib/studium/exam_topics/macroeconomics +39 -0
- data/lib/studium/exam_topics/marketing +53 -0
- data/lib/studium/exam_topics/mathematics +311 -0
- data/lib/studium/exam_topics/medizin_und_biomedizinische_technik +254 -0
- data/lib/studium/exam_topics/medizinische_chemie_und_pharmazie +441 -0
- data/lib/studium/exam_topics/messtechnik_und_regeltechnik +104 -0
- data/lib/studium/exam_topics/metabolismus +482 -0
- data/lib/studium/exam_topics/meteorologie_und_atmosph/303/244re +120 -0
- data/lib/studium/exam_topics/microbial_ecology +37 -0
- data/lib/studium/exam_topics/microcontrollers +11 -0
- data/lib/studium/exam_topics/mikrobielle_lebensgemeinschaften +58 -0
- data/lib/studium/exam_topics/mikrobielle_physiologie +313 -0
- data/lib/studium/exam_topics/mitochondria +57 -0
- data/lib/studium/exam_topics/mixed +287 -0
- data/lib/studium/exam_topics/molecular_biology_of_plants +281 -0
- data/lib/studium/exam_topics/molekulare_medizin +133 -0
- data/lib/studium/exam_topics/nanotechnologie +456 -0
- data/lib/studium/exam_topics/nature_conservation_and_biodiversity +247 -0
- data/lib/studium/exam_topics/naturstoffe +9 -0
- data/lib/studium/exam_topics/netzwerke +63 -0
- data/lib/studium/exam_topics/neuroanatomie +25 -0
- data/lib/studium/exam_topics/neurobiology +356 -0
- data/lib/studium/exam_topics/nucleotide_sequencing +41 -0
- data/lib/studium/exam_topics/nutztierethologie +11 -0
- data/lib/studium/exam_topics/object_oriented_modeling +15 -0
- data/lib/studium/exam_topics/obstbau +249 -0
- data/lib/studium/exam_topics/organische_chemie +1007 -0
- data/lib/studium/exam_topics/organische_chemie_2 +137 -0
- data/lib/studium/exam_topics/paleobiology +39 -0
- data/lib/studium/exam_topics/parasitic_diseases_and_molecular_infection_biology +336 -0
- data/lib/studium/exam_topics/patent_law +55 -0
- data/lib/studium/exam_topics/pathologie +761 -0
- data/lib/studium/exam_topics/pcr +155 -0
- data/lib/studium/exam_topics/pentosephosphatweg +61 -0
- data/lib/studium/exam_topics/peroxisomes_glycosomes_and_lysosomes +66 -0
- data/lib/studium/exam_topics/pflanzenanatomie +262 -0
- data/lib/studium/exam_topics/pflanzenbau +24 -0
- data/lib/studium/exam_topics/pflanzenschutz +35 -0
- data/lib/studium/exam_topics/pflanzenwissenschaften +1009 -0
- data/lib/studium/exam_topics/pharmaceutical_biotechnology +252 -0
- data/lib/studium/exam_topics/physik +449 -1
- data/lib/studium/exam_topics/physikalische_chemie +79 -0
- data/lib/studium/exam_topics/physiology_and_histology +592 -0
- data/lib/studium/exam_topics/phytochemie +33 -0
- data/lib/studium/exam_topics/plant_biotechnology +132 -0
- data/lib/studium/exam_topics/plant_breeding +64 -0
- data/lib/studium/exam_topics/plant_development +50 -0
- data/lib/studium/exam_topics/populationsgenetik +143 -0
- data/lib/studium/exam_topics/posttranslationale_modifikation_von_proteinen +198 -0
- data/lib/studium/exam_topics/programming +41 -0
- data/lib/studium/exam_topics/projektmanagement +226 -0
- data/lib/studium/exam_topics/prokaryote_genetics +587 -0
- data/lib/studium/exam_topics/protein_engineering +35 -0
- data/lib/studium/exam_topics/proteolyse +39 -0
- data/lib/studium/exam_topics/proteomik +42 -0
- data/lib/studium/exam_topics/protozoans +24 -0
- data/lib/studium/exam_topics/prozesstechnik +95 -0
- data/lib/studium/exam_topics/psychologie +21 -0
- data/lib/studium/exam_topics/python +391 -0
- data/lib/studium/exam_topics/quality_management +266 -0
- data/lib/studium/exam_topics/rechtsgrundlagen +126 -0
- data/lib/studium/exam_topics/research_topics_in_immunobiology +42 -0
- data/lib/studium/exam_topics/rna_and_dna +535 -0
- data/lib/studium/exam_topics/rna_seq +13 -0
- data/lib/studium/exam_topics/robotics +12 -0
- data/lib/studium/exam_topics/ruby +240 -0
- data/lib/studium/exam_topics/ruby_on_rails +63 -0
- data/lib/studium/exam_topics/scientific_writing_and_publishing +38 -0
- data/lib/studium/exam_topics/semisynthese_von_proteinen_und_nukleotiden +120 -0
- data/lib/studium/exam_topics/sexualbiologie +327 -0
- data/lib/studium/exam_topics/signal_transduction_and_laser_systems +215 -0
- data/lib/studium/exam_topics/sozialbiologie +17 -0
- data/lib/studium/exam_topics/soziologie +5 -0
- data/lib/studium/exam_topics/splicing_exons_and_introns +67 -0
- data/lib/studium/exam_topics/sport_und_sportverletzungen +6 -0
- data/lib/studium/exam_topics/statistik +306 -0
- data/lib/studium/exam_topics/stemcells +182 -0
- data/lib/studium/exam_topics/stickstofffixierung +91 -0
- data/lib/studium/exam_topics/structural_bioinformatics +54 -0
- data/lib/studium/exam_topics/strukturbiologie +445 -0
- data/lib/studium/exam_topics/system_biology_and_synthetic_biology +108 -0
- data/lib/studium/exam_topics/systematische_zoologie +446 -0
- data/lib/studium/exam_topics/technical_ecology +144 -0
- data/lib/studium/exam_topics/technik +5 -0
- data/lib/studium/exam_topics/technische_chemie +208 -0
- data/lib/studium/exam_topics/technische_grundlagen_der_informatik +43 -0
- data/lib/studium/exam_topics/technische_mikrobiologie +393 -0
- data/lib/studium/exam_topics/technisches_zeichnen +5 -0
- data/lib/studium/exam_topics/the_bacterial_cell_wall +98 -0
- data/lib/studium/exam_topics/the_c_plus_plus_programming_language +531 -0
- data/lib/studium/exam_topics/the_c_programming_language +133 -0
- data/lib/studium/exam_topics/the_cellcycle +102 -0
- data/lib/studium/exam_topics/the_european_union +121 -0
- data/lib/studium/exam_topics/the_interferon_system +40 -0
- data/lib/studium/exam_topics/the_microbiome +164 -0
- data/lib/studium/exam_topics/the_universe +32 -0
- data/lib/studium/exam_topics/theoretische_chemie +5 -0
- data/lib/studium/exam_topics/theoretische_informatik +161 -0
- data/lib/studium/exam_topics/thermodynamics +21 -0
- data/lib/studium/exam_topics/tierzucht +139 -0
- data/lib/studium/exam_topics/toxikologie +508 -0
- data/lib/studium/exam_topics/transcription +188 -0
- data/lib/studium/exam_topics/translation_ribosomes_and_translational_control +155 -0
- data/lib/studium/exam_topics/umweltbiotechnologie +64 -0
- data/lib/studium/exam_topics/umweltchemie +233 -0
- data/lib/studium/exam_topics/urbanism_and_traffic +19 -0
- data/lib/studium/exam_topics/urea_cycle +56 -0
- data/lib/studium/exam_topics/vaccines_and_vaccination +253 -0
- data/lib/studium/exam_topics/vectors_and_gene_therapy +247 -0
- data/lib/studium/exam_topics/verfahrenstechnik +37 -0
- data/lib/studium/exam_topics/verhaltensbiologie +79 -0
- data/lib/studium/exam_topics/veterinary_medicine +10 -0
- data/lib/studium/exam_topics/vitamine +32 -0
- data/lib/studium/exam_topics/wasserkunde +144 -0
- data/lib/studium/exam_topics/weinbau +86 -0
- data/lib/studium/exam_topics/wissenschaft +20 -0
- data/lib/studium/exam_topics/yeast +104 -0
- data/lib/studium/exam_topics/zoologie +338 -0
- data/lib/studium/exams/afterburn/afterburn.rb +304 -0
- data/lib/studium/exams/ask_exam_from_the_upcoming_exams_pool.rb +150 -0
- data/lib/studium/exams/ask_exam_topic_question.rb +112 -0
- data/lib/studium/exams/ask_question_from_alias.rb +141 -0
- data/lib/studium/exams/ask_question_from_any_of_the_still_missing_lectures.rb +130 -0
- data/lib/studium/exams/ask_question_from_grouped_themes.rb +141 -0
- data/lib/studium/exams/ask_question_from_last_topic.rb +91 -0
- data/lib/studium/exams/ask_random_question.rb +195 -0
- data/lib/studium/exams/autoinclude.rb +7 -0
- data/lib/studium/exams/average_grade/average_grade.rb +404 -0
- data/lib/studium/exams/csv/create_csv_passed_exams_file.rb +217 -0
- data/lib/studium/exams/cycle.rb +291 -0
- data/lib/studium/exams/dataset/dataset.rb +126 -0
- data/lib/studium/exams/designate_ten_random_exam_topics/designate_ten_random_exam_topics.rb +88 -0
- data/lib/studium/exams/exam/exam.rb +130 -0
- data/lib/studium/exams/exam_bubble/exam_bubble.rb +444 -0
- data/lib/studium/exams/exam_bubble/menu_for_the_main_loop.rb +111 -0
- data/lib/studium/exams/exam_question/README.md +3 -0
- data/lib/studium/exams/exam_question/exam_question.rb +434 -0
- data/lib/studium/exams/exam_registration_at/constants.rb +49 -0
- data/lib/studium/exams/exam_registration_at/exam_registration_at.rb +242 -0
- data/lib/studium/exams/exam_registration_at/help.rb +46 -0
- data/lib/studium/exams/exam_registration_at/menu.rb +81 -0
- data/lib/studium/exams/exam_registration_at/report_and_show.rb +133 -0
- data/lib/studium/exams/exam_registration_at/reset.rb +54 -0
- data/lib/studium/exams/exam_statistics_from_this_file/exam_statistics_from_this_file.rb +119 -0
- data/lib/studium/exams/exam_topics.rb +194 -0
- data/lib/studium/exams/exams.rb +20 -0
- data/lib/studium/exams/exams_per_month/exams_per_month.rb +2442 -0
- data/lib/studium/exams/exams_this_week.rb +182 -0
- data/lib/studium/exams/fix_exam_dates.rb +121 -0
- data/lib/studium/exams/frozen.rb +36 -0
- data/lib/studium/exams/last_exams/last_exams.rb +479 -0
- data/lib/studium/exams/lectures_without_exam_entry.rb +137 -0
- data/lib/studium/exams/mandatory_continuous_assessment/mandatory_continuous_assessment.rb +1358 -0
- data/lib/studium/exams/move_all_unsolved_exam_questions_to_the_top_of_the_file.rb +173 -0
- data/lib/studium/exams/move_the_last_exam_question_to_the_top_of_the_file/move_the_last_exam_question_to_the_top_of_the_file.rb +111 -0
- data/lib/studium/exams/n_exams_in_these_topics.rb +477 -0
- data/lib/studium/exams/next_exam.rb +106 -0
- data/lib/studium/exams/next_exams.rb +378 -0
- data/lib/studium/exams/not_completed/README.md +5 -0
- data/lib/studium/exams/not_completed/not_completed.rb +143 -0
- data/lib/studium/exams/open_exam_associated_url/open_exam_associated_url.rb +154 -0
- data/lib/studium/exams/open_last_exam_question_asked_file/constants.rb +15 -0
- data/lib/studium/exams/open_last_exam_question_asked_file/initialize.rb +29 -0
- data/lib/studium/exams/open_last_exam_question_asked_file/open_last_exam_question_asked_file.rb +110 -0
- data/lib/studium/exams/push_solved_questions_on_top.rb +180 -0
- data/lib/studium/exams/question_answer/question_answer.rb +2936 -0
- data/lib/studium/exams/questions_solved_from_day_to_day/questions_solved_from_day_to_day.rb +379 -0
- data/lib/studium/exams/remote_ftp_url.rb +52 -0
- data/lib/studium/exams/repeat_last_question.rb +78 -0
- data/lib/studium/exams/report_total_amount_of_questions_and_answers_for.rb +116 -0
- data/lib/studium/exams/show_all_passed_exams_of_this_university.rb +252 -0
- data/lib/studium/exams/show_backlog_of_exams/show_backlog_of_exams.rb +114 -0
- data/lib/studium/exams/show_exams_for/show_exams_for.rb +172 -0
- data/lib/studium/exams/show_themes/constants.rb +28 -0
- data/lib/studium/exams/show_themes/menu.rb +61 -0
- data/lib/studium/exams/show_themes/misc.rb +538 -0
- data/lib/studium/exams/show_themes/reset.rb +62 -0
- data/lib/studium/exams/show_themes/show_themes.rb +27 -0
- data/lib/studium/exams/show_upcoming_exams/show_upcoming_exams.rb +1537 -0
- data/lib/studium/exams/solve_all_questions_from_this_topic.rb +114 -0
- data/lib/studium/exams/solved/solved.rb +434 -0
- data/lib/studium/exams/timetable/constants.rb +142 -0
- data/lib/studium/exams/timetable/timetable.rb +448 -0
- data/lib/studium/exams/unsolve_all_questions_from_this_topic.rb +163 -0
- data/lib/studium/exams/upcoming_exams/upcoming_exams.rb +555 -0
- data/lib/studium/exams/upcoming_exams_at_the_boku/constants.rb +23 -0
- data/lib/studium/exams/upcoming_exams_at_the_boku/html.rb +64 -0
- data/lib/studium/exams/upcoming_exams_at_the_boku/upcoming_exams_at_the_boku.rb +194 -0
- data/lib/studium/exams/upcoming_exams_dataset.rb +247 -0
- data/lib/studium/exams/upcoming_registered_exams/upcoming_registered_exams.rb +257 -0
- data/lib/studium/exams/upload_exam_topics.rb +360 -0
- data/lib/studium/graphviz/README.md +4 -0
- data/lib/studium/graphviz/bachelor_vector_based_strategies.dot +160 -0
- data/lib/studium/graphviz/master_vector_based_strategies.dot +46 -0
- data/lib/studium/gui/gtk3/control_panel/control_panel.rb +40 -0
- data/lib/studium/gui/gtk3/lecture_information/lecture_information.rb +191 -0
- data/lib/studium/gui/java/exam_question/ExamQuestion$1.class +0 -0
- data/lib/studium/gui/java/exam_question/ExamQuestion.class +0 -0
- data/lib/studium/gui/java/exam_question/ExamQuestion.java +215 -0
- data/lib/studium/gui/javafx/exam_question_widget/exam_question_widget.rb +58 -0
- data/lib/studium/gui/jruby/exam_trainer/exam_trainer.rb +637 -0
- data/lib/studium/gui/jruby/show_upcoming_exams/show_upcoming_exams.rb +85 -0
- data/lib/studium/gui/libui/ask_exam_question/ask_exam_question.rb +347 -0
- data/lib/studium/gui/shared_code/control_panel/control_panel_module.rb +305 -0
- data/lib/studium/gui/shared_code/exam_trainer/exam_trainer_widget_module.rb +0 -0
- data/lib/studium/gui/shared_code/information_about_a_lecture/information_about_a_lecture_module.rb +0 -0
- data/lib/studium/gui/shared_code/show_upcoming_exams/show_upcoming_exams_module.rb +129 -0
- data/lib/studium/gui/universal_widgets/curriculum_viewer/curriculum_viewer.rb +549 -0
- data/lib/studium/gui/universal_widgets/ects_per_university/ects_per_university.rb +302 -0
- data/lib/studium/gui/universal_widgets/exam_trainer/exam_trainer.config +6 -0
- data/lib/studium/gui/universal_widgets/exam_trainer/exam_trainer.rb +3266 -0
- data/lib/studium/gui/universal_widgets/exam_trainer/manifest.yml +12 -0
- data/lib/studium/gui/universal_widgets/expand_time_range/expand_time_range.rb +309 -0
- data/lib/studium/gui/universal_widgets/information_about_a_lecture/information_about_a_lecture.rb +242 -0
- data/lib/studium/gui/universal_widgets/show_upcoming_exams/show_upcoming_exams.rb +252 -0
- data/lib/studium/images/libui_ask_exam_question.png +0 -0
- data/lib/studium/images/outdated.png +0 -0
- data/lib/studium/images/small_logos/DNA.png +0 -0
- data/lib/studium/images/small_logos/README.md +2 -0
- data/lib/studium/images/small_logos/solved.png +0 -0
- data/lib/studium/images/studies_favicon.png +0 -0
- data/lib/studium/java/README.md +5 -0
- data/lib/studium/java/studium/AskExamQuestion.java +461 -0
- data/lib/studium/java/studium/Base.java +123 -0
- data/lib/studium/java/studium/Constants.java +122 -0
- data/lib/studium/java/studium/EnsureThatTheLogDirectoryExists.java +57 -0
- data/lib/studium/java/studium/Mkdir.java +13 -0
- data/lib/studium/java/studium/OpenLastExamQuestionurlLinkViaTheBrowser.java +90 -0
- data/lib/studium/java/studium/ReturnNQuestionsSolvedInTotal.java +69 -0
- data/lib/studium/java/studium/Solved.java +112 -0
- data/lib/studium/java/studium/Test.java +60 -0
- data/lib/studium/java/studium/studium/AskExamQuestion.class +0 -0
- data/lib/studium/java/studium/studium/Base.class +0 -0
- data/lib/studium/java/studium/studium/Constants.class +0 -0
- data/lib/studium/java/studium/studium/EnsureThatTheLogDirectoryExists.class +0 -0
- data/lib/studium/java/studium/studium/Mkdir.class +0 -0
- data/lib/studium/java/studium/studium/OpenLastExamQuestionurlLinkViaTheBrowser.class +0 -0
- data/lib/studium/java/studium/studium/ReturnNQuestionsSolvedInTotal.class +0 -0
- data/lib/studium/java/studium/studium/Solved.class +0 -0
- data/lib/studium/java/studium/studium/Test.class +0 -0
- data/lib/studium/jobs/jobs.rb +80 -0
- data/lib/studium/logging/README.md +2 -0
- data/lib/studium/logging/ensure_that_the_log_directory_exists.rb +58 -0
- data/lib/studium/logging/html_log_directory.rb +42 -0
- data/lib/studium/logging/log_directory.rb +112 -0
- data/lib/studium/logging/store_last_question_asked_into_file.rb +138 -0
- data/lib/studium/parsers/README.md +2 -0
- data/lib/studium/parsers/custom_exam_results_parser.rb +209 -0
- data/lib/studium/parsers/parse_remote_lecture.rb +331 -0
- data/lib/studium/project/project.rb +88 -0
- data/lib/studium/requires/common_popular_requires.rb +37 -0
- data/lib/studium/requires/commonly_used_requires.rb +14 -0
- data/lib/studium/requires/require_class_exams_solved.rb +7 -0
- data/lib/studium/requires/require_ects_scripts.rb +27 -0
- data/lib/studium/requires/require_encoding.rb +7 -0
- data/lib/studium/requires/require_the_check_and_sanitize_files.rb +31 -0
- data/lib/studium/requires/require_the_curricula_files.rb +28 -0
- data/lib/studium/requires/require_the_exam_question_class.rb +7 -0
- data/lib/studium/requires/require_the_exams_files.rb +46 -0
- data/lib/studium/requires/require_the_logging_files.rb +23 -0
- data/lib/studium/requires/require_the_parsers.rb +28 -0
- data/lib/studium/requires/require_the_studium_constants.rb +7 -0
- data/lib/studium/requires/require_the_studium_project.rb +72 -0
- data/lib/studium/requires/require_the_toplevel_methods.rb +27 -0
- data/lib/studium/requires/require_the_utility_scripts.rb +34 -0
- data/lib/studium/requires/require_upcoming_exams.rb +7 -0
- data/lib/studium/requires/require_yaml.rb +7 -0
- data/lib/studium/requires/return_remote_homepage_of_this_lecture.rb +7 -0
- data/lib/studium/requires/with_GUI.rb +13 -0
- data/lib/studium/requires/www_mode.rb +17 -0
- data/lib/studium/statistics/README.md +4 -0
- data/lib/studium/statistics/best_exam_months.rb +92 -0
- data/lib/studium/statistics/curriculum_comparer/curriculum_comparer.rb +423 -0
- data/lib/studium/statistics/determine_exam_statistics_from_this_file.rb +142 -0
- data/lib/studium/statistics/exam_topics_that_are_about_to_be_completed.rb +117 -0
- data/lib/studium/statistics/max_stats.rb +169 -0
- data/lib/studium/statistics/new_questions_per_year.rb +147 -0
- data/lib/studium/statistics/report_how_many_ects_points_per_curriculum_were_completed.rb +167 -0
- data/lib/studium/statistics/report_how_many_exam_questions_were_answered.rb +473 -0
- data/lib/studium/statistics/show_exam_statistics.rb +75 -0
- data/lib/studium/statistics/show_which_courses_are_in_a_bachelor_or_master_curriculum_respectively.rb +104 -0
- data/lib/studium/statistics/top_stats.rb +126 -0
- data/lib/studium/toplevel_methods/e_and_esystem.rb +34 -0
- data/lib/studium/toplevel_methods/find_exam_topic_and_exam_title.rb +3986 -0
- data/lib/studium/toplevel_methods/install_the_project_on_the_given_hostsystem.rb +31 -0
- data/lib/studium/toplevel_methods/return_remote_homepage_of_this_lecture.rb +11611 -0
- data/lib/studium/toplevel_methods/return_remote_moodle_link_of_this_lecture.rb +2405 -0
- data/lib/studium/toplevel_methods/roebe.rb +16 -0
- data/lib/studium/toplevel_methods/runmode.rb +45 -0
- data/lib/studium/toplevel_methods/toplevel_methods.rb +7295 -0
- data/lib/studium/universities_in_austria/README.md +2 -0
- data/lib/studium/universities_in_austria/boku/README.md +4 -0
- data/lib/studium/universities_in_austria/boku/boku_/303/266ffnungszeiten.rb +28 -0
- data/lib/studium/universities_in_austria/boku/show_three_pillars_of_these_lectures.rb +110 -0
- data/lib/studium/universities_in_austria/boku/three_pillars.rb +237 -0
- data/lib/studium/universities_in_austria/tu_vienna/README.md +6 -0
- data/lib/studium/universities_in_austria/tu_vienna/tu_ferien.rb +42 -0
- data/lib/studium/universities_in_austria/tu_vienna/tu_/303/266ffnungszeiten.rb +34 -0
- data/lib/studium/university_course/university_course.rb +409 -0
- data/lib/studium/utility_scripts/attribute_lectures_to_university/attribute_lectures_to_university.rb +375 -0
- data/lib/studium/utility_scripts/audio_stats.rb +171 -0
- data/lib/studium/utility_scripts/auto_stud/auto_stud.rb +252 -0
- data/lib/studium/utility_scripts/auto_stud/constants.rb +18 -0
- data/lib/studium/utility_scripts/auto_stud/initialize.rb +23 -0
- data/lib/studium/utility_scripts/auto_stud/misc.rb +18 -0
- data/lib/studium/utility_scripts/autogeneration/autogeneration.rb +158 -0
- data/lib/studium/utility_scripts/autopurge_this_lecture_date.rb +100 -0
- data/lib/studium/utility_scripts/average_grade_of_this_curriculum.rb +153 -0
- data/lib/studium/utility_scripts/blocked_courses.rb +146 -0
- data/lib/studium/utility_scripts/calendar/README.md +2 -0
- data/lib/studium/utility_scripts/calendar/calendar.rb +251 -0
- data/lib/studium/utility_scripts/calendar/misc.rb +35 -0
- data/lib/studium/utility_scripts/check_description_of_these_lectures.rb +221 -0
- data/lib/studium/utility_scripts/course_registrations/course_registrations.rb +98 -0
- data/lib/studium/utility_scripts/courses/courses.rb +177 -0
- data/lib/studium/utility_scripts/create/README.md +2 -0
- data/lib/studium/utility_scripts/create/webpage_of_university.rb +129 -0
- data/lib/studium/utility_scripts/create/webpage_of_university_BOKU.rb +61 -0
- data/lib/studium/utility_scripts/create/webpage_of_university_TU.rb +60 -0
- data/lib/studium/utility_scripts/create/webpage_of_university_UniWien.rb +60 -0
- data/lib/studium/utility_scripts/create_database/create_database.rb +126 -0
- data/lib/studium/utility_scripts/current_lectures_belonging_to_both_bachelor_and_master_curriculum.rb +113 -0
- data/lib/studium/utility_scripts/currently_participating_in_these_lectures/currently_participating_in_these_lectures.rb +104 -0
- data/lib/studium/utility_scripts/display_lecture_url/display_lecture_url.rb +176 -0
- data/lib/studium/utility_scripts/expand_time_range/expand_time_range.rb +521 -0
- data/lib/studium/utility_scripts/finished_exams_at_this_university/finished_exams_at_this_university.rb +171 -0
- data/lib/studium/utility_scripts/foreign_language_percentage/constants.rb +23 -0
- data/lib/studium/utility_scripts/foreign_language_percentage/foreign_language_percentage.rb +149 -0
- data/lib/studium/utility_scripts/foreign_language_percentage/help.rb +31 -0
- data/lib/studium/utility_scripts/foreign_language_percentage/initialize.rb +25 -0
- data/lib/studium/utility_scripts/foreign_language_percentage/menu.rb +158 -0
- data/lib/studium/utility_scripts/foreign_language_percentage/report.rb +62 -0
- data/lib/studium/utility_scripts/foreign_language_percentage/reset.rb +50 -0
- data/lib/studium/utility_scripts/foreign_language_percentage/run.rb +19 -0
- data/lib/studium/utility_scripts/generate_spreadsheet/generate_spreadsheet.rb +353 -0
- data/lib/studium/utility_scripts/generate_spreadsheet/misc.rb +144 -0
- data/lib/studium/utility_scripts/holidays/holidays.rb +154 -0
- data/lib/studium/utility_scripts/homepage_of_these_courses/homepage_of_these_courses.rb +125 -0
- data/lib/studium/utility_scripts/lectures_attributed_to_universities/lectures_attributed_to_universities.rb +336 -0
- data/lib/studium/utility_scripts/lva_dates_of_the_important_courses.rb +111 -0
- data/lib/studium/utility_scripts/lva_nummer/lva_nummer.rb +427 -0
- data/lib/studium/utility_scripts/mandatory_lectures_in_this_month/mandatory_lectures_in_this_month.rb +316 -0
- data/lib/studium/utility_scripts/moodle/moodle.rb +214 -0
- data/lib/studium/utility_scripts/name_of_this_lva_id/name_of_this_lva_id.rb +110 -0
- data/lib/studium/utility_scripts/new_stud.rb +324 -0
- data/lib/studium/utility_scripts/next_week/next_week.rb +103 -0
- data/lib/studium/utility_scripts/not_yet_registered/not_yet_registered.rb +120 -0
- data/lib/studium/utility_scripts/open_last_exam_question_url_link_via_the_browser.rb +76 -0
- data/lib/studium/utility_scripts/passed_ects_per_year/passed_ects_per_year.rb +313 -0
- data/lib/studium/utility_scripts/passed_pr/303/274fungsimmanente_courses/passed_pr/303/274fungsimmanente_courses.rb +181 -0
- data/lib/studium/utility_scripts/pdf/README.md +2 -0
- data/lib/studium/utility_scripts/pdf/create_pdf_file_for_this_exam_topic.rb +352 -0
- data/lib/studium/utility_scripts/pdf/hexapdf_support.rb +50 -0
- data/lib/studium/utility_scripts/preparatory_meetings/preparatory_meetings.rb +317 -0
- data/lib/studium/utility_scripts/priority/priority.rb +164 -0
- data/lib/studium/utility_scripts/priority_points/priority_points.rb +261 -0
- data/lib/studium/utility_scripts/publish_my_exams/publish_my_exams.rb +174 -0
- data/lib/studium/utility_scripts/regexes/README.md +1 -0
- data/lib/studium/utility_scripts/regexes/generate_regex.rb +314 -0
- data/lib/studium/utility_scripts/regexes/generate_regexes_for_the_available_moodle_links.rb +55 -0
- data/lib/studium/utility_scripts/regexes/generate_regexes_for_the_registered_lectures.rb +48 -0
- data/lib/studium/utility_scripts/report_outdated_timetable_entries/report_outdated_timetable_entries.rb +142 -0
- data/lib/studium/utility_scripts/report_whether_this_lecture_is_registered_in_the_file_lecture_information/report_whether_this_lecture_is_registered_in_the_file_lecture_information.rb +129 -0
- data/lib/studium/utility_scripts/resolve_practical_courses_date_conflicts/individual_resolve_practical_courses_date_conflicts.rb +254 -0
- data/lib/studium/utility_scripts/resolve_practical_courses_date_conflicts/resolve_practical_courses_date_conflicts.rb +265 -0
- data/lib/studium/utility_scripts/scrape_remote_university_url.rb +138 -0
- data/lib/studium/utility_scripts/semester_schedule_creator/semester_container.rb +144 -0
- data/lib/studium/utility_scripts/semester_schedule_creator/semester_schedule_creator.rb +373 -0
- data/lib/studium/utility_scripts/semesterplaner/semesterplaner.rb +311 -0
- data/lib/studium/utility_scripts/set_aliases_based_on_this_file.rb +96 -0
- data/lib/studium/utility_scripts/show_all_passed_master_lectures/show_all_passed_master_lectures.rb +126 -0
- data/lib/studium/utility_scripts/show_conflicting_lva_lectures/show_conflicting_lva_lectures.rb +1385 -0
- data/lib/studium/utility_scripts/show_descriptions_of_lectures_belonging_to_this_module/constants.rb +23 -0
- data/lib/studium/utility_scripts/show_descriptions_of_lectures_belonging_to_this_module/menu.rb +63 -0
- data/lib/studium/utility_scripts/show_descriptions_of_lectures_belonging_to_this_module/reset.rb +33 -0
- data/lib/studium/utility_scripts/show_descriptions_of_lectures_belonging_to_this_module/run.rb +50 -0
- data/lib/studium/utility_scripts/show_descriptions_of_lectures_belonging_to_this_module/show_descriptions_of_lectures_belonging_to_this_module.rb +145 -0
- data/lib/studium/utility_scripts/show_lecturers/show_lecturers.rb +147 -0
- data/lib/studium/utility_scripts/show_lectures/show_lectures.rb +906 -0
- data/lib/studium/utility_scripts/show_lectures_fitting_to_this_language/show_lectures_fitting_to_this_language.rb +121 -0
- data/lib/studium/utility_scripts/show_lectures_fitting_to_this_theme/show_lectures_fitting_to_this_theme.rb +105 -0
- data/lib/studium/utility_scripts/show_lectures_on_the_commandline/show_lectures_on_the_commandline.rb +3160 -0
- data/lib/studium/utility_scripts/show_lectures_on_this_day/show_lectures_on_this_day.rb +150 -0
- data/lib/studium/utility_scripts/show_lva_dates_of_this_lecture/show_lva_dates_of_this_lecture.rb +182 -0
- data/lib/studium/utility_scripts/show_mixed_bachelor_master_courses/show_mixed_bachelor_master_courses.rb +92 -0
- data/lib/studium/utility_scripts/show_outdated_lva_dates/show_outdated_lva_dates.rb +214 -0
- data/lib/studium/utility_scripts/show_passed_exams_having_this_grade/show_passed_exams_having_this_grade.rb +91 -0
- data/lib/studium/utility_scripts/show_solved_english_lectures/show_solved_english_lectures.rb +139 -0
- data/lib/studium/utility_scripts/steop/README.md +4 -0
- data/lib/studium/utility_scripts/steop/show_all_steop_lectures.rb +93 -0
- data/lib/studium/utility_scripts/steop/steop_lectures_in_this_curriculum.rb +284 -0
- data/lib/studium/utility_scripts/steop/steop_lva_dates.rb +119 -0
- data/lib/studium/utility_scripts/studienkennzahl/studienkennzahl.rb +116 -0
- data/lib/studium/utility_scripts/studium_skeleton/studium_skeleton.rb +241 -0
- data/lib/studium/utility_scripts/stundenplan.rb +600 -0
- data/lib/studium/utility_scripts/sync_studium_relevant_entries_one_level_downwards.rb +217 -0
- data/lib/studium/utility_scripts/ufind/ufind.rb +106 -0
- data/lib/studium/utility_scripts/upcoming_mandatory_presence_courses/constants.rb +26 -0
- data/lib/studium/utility_scripts/upcoming_mandatory_presence_courses/run.rb +20 -0
- data/lib/studium/utility_scripts/upcoming_mandatory_presence_courses/upcoming_mandatory_presence_courses.rb +187 -0
- data/lib/studium/utility_scripts/video_lecture_downloader/video_lecture_downloader.rb +107 -0
- data/lib/studium/utility_scripts/week_parser/constants.rb +23 -0
- data/lib/studium/utility_scripts/week_parser/help.rb +32 -0
- data/lib/studium/utility_scripts/week_parser/menu.rb +59 -0
- data/lib/studium/utility_scripts/week_parser/misc.rb +373 -0
- data/lib/studium/utility_scripts/week_parser/reset.rb +65 -0
- data/lib/studium/utility_scripts/week_parser/run.rb +18 -0
- data/lib/studium/utility_scripts/week_parser/show.rb +236 -0
- data/lib/studium/utility_scripts/week_parser/week_parser.rb +49 -0
- data/lib/studium/utility_scripts/weekday_parser.rb +155 -0
- data/lib/studium/utility_scripts/weekly_schedule.rb +198 -0
- data/lib/studium/utility_scripts/wochenplanung/wochenplanung.rb +267 -0
- data/lib/studium/version/version.rb +46 -0
- data/lib/studium/www/exams/exams.cgi +54 -0
- data/lib/studium/www/fast_ask_exam_question/fast_ask_exam_question.cgi +156 -0
- data/lib/studium/www/handle_curricula/handle_curricula.cgi +154 -0
- data/lib/studium/www/next_generation_exam_question_trainer/next_generation_exam_question_trainer.cgi +112 -0
- data/lib/studium/www/next_generation_exam_question_trainer/solved.cgi +26 -0
- data/lib/studium/www/sinatra/app.rb +231 -0
- data/lib/studium/www/sinatra/curriculum_displayer/curriculum_displayer.rb +162 -0
- data/lib/studium/www/sinatra/misc.rb +115 -0
- data/lib/studium/www/statistics/statistics.cgi +82 -0
- data/lib/studium/www/upcoming_exams/upcoming_exams.cgi +36 -0
- data/lib/studium/yaml/ad_hoc_trainer/README.md +2 -0
- data/lib/studium/yaml/ad_hoc_trainer/exam_topics.md +22 -0
- data/lib/studium/yaml/allowed_themes_for_courses/allowed_themes_for_courses.yml +348 -0
- data/lib/studium/yaml/array_allowed_entries_for_the_file_lecture_information/array_allowed_entries_for_the_file_lecture_information.yml +71 -0
- data/lib/studium/yaml/available_exam_topics/available_exam_topics.yml +234 -0
- data/lib/studium/yaml/backlog_of_exams.yml +37 -0
- data/lib/studium/yaml/colours/custom_colours.yml +50 -0
- data/lib/studium/yaml/colours/use_colours.yml +1 -0
- data/lib/studium/yaml/current_exams.yml +30 -0
- data/lib/studium/yaml/curricula/README.md +39 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_agrarwissenschaften_033255.yml +147 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_biologie_basisblock_033630.yml +71 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_biologie_botanik_033630.yml +100 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_biologie_ecology_033630.yml +74 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_biologie_mikrobiologie_und_genetik_033630.yml +122 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_biologie_molekulare_biologie_033630.yml +106 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_biologie_zoologie_033630.yml +87 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_chemie_033662.yml +165 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_dummy_curriculum.yml +182 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_elektrotechnik_und_informationstechnik_033235.yml +13 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_forstwirtschaft_033225.yml +115 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_informatik_033521.yml +134 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_ktww_033231.yml +84 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_lmbt_033217.yml +121 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_medizinische_informatik_033533.yml +283 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_molekularbiologie_033665.yml +95 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_nutrition_science_033638.yml +119 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_pharmazie_033305.yml +170 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_technische_chemie_033290.yml +131 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_technische_informatik_033535.yml +23 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_ubrm_033227.yml +142 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_verfahrenstechnik_033273.yml +167 -0
- data/lib/studium/yaml/curricula/bachelor/bachelor_wirtschaftsinformatik_033526.yml +29 -0
- data/lib/studium/yaml/curricula/experimental/bachelor_informatik_in_den_lebenswissenschaften.yml +137 -0
- data/lib/studium/yaml/curricula/individual/bachelor_formale_logik.yml +88 -0
- data/lib/studium/yaml/curricula/individual/bachelor_informatik_und_molekulare_biologie.yml +1161 -0
- data/lib/studium/yaml/curricula/individual/bachelor_vector_based_strategies_in_life_sciences_molecular_medicine_and_biotechnology.yml +1157 -0
- data/lib/studium/yaml/curricula/individual/master_bioinformatics_and_nanobiotechnology_in_molecular_medicine.yml +306 -0
- data/lib/studium/yaml/curricula/individual/master_vector_based_strategies_in_life_sciences_molecular_medicine_and_biotechnology.yml +741 -0
- data/lib/studium/yaml/curricula/master/master_bioinformatik_066875.yml +75 -0
- data/lib/studium/yaml/curricula/master/master_biologie_molekulare_mikrobiologie_mikrobielle_oekologie_und_immunbiologie_066830.yml +78 -0
- data/lib/studium/yaml/curricula/master/master_biologische_chemie_066863.yml +66 -0
- data/lib/studium/yaml/curricula/master/master_dummy_curriculum.yml +197 -0
- data/lib/studium/yaml/curricula/master/master_genetik_und_entwicklungsbiologie_066877.yml +89 -0
- data/lib/studium/yaml/curricula/master/master_lmbt_066418.yml +112 -0
- data/lib/studium/yaml/curricula/master/master_molecular_biology_066865.yml +72 -0
- data/lib/studium/yaml/curricula/master/master_molekulare_biologie_066834.yml +151 -0
- data/lib/studium/yaml/curricula/master/master_pharmazie_066605.yml +176 -0
- data/lib/studium/yaml/curricula/master/master_technische_chemie_066490.yml +123 -0
- data/lib/studium/yaml/curricula/outdated/master_bioinformatics_and_molecular_biotechnology_including_aspects_from_molecular_medicine.yml +438 -0
- data/lib/studium/yaml/curricula/outdated/master_food_science_and_plant_biotechnology.yml +31 -0
- data/lib/studium/yaml/curricula.yml +562 -0
- data/lib/studium/yaml/daily_questions_solved/daily_questions_solved.yml +2019 -0
- data/lib/studium/yaml/daily_questions_solved/daily_questions_solved.yml~ +1983 -0
- data/lib/studium/yaml/default_delay.yml +4 -0
- data/lib/studium/yaml/default_encoding.yml +1 -0
- data/lib/studium/yaml/directory_to_the_exam_topics.yml +0 -0
- data/lib/studium/yaml/editor.yml +1 -0
- data/lib/studium/yaml/exams/next_exams_to_do.md +9 -0
- data/lib/studium/yaml/file_for_exam_questions.yml +1 -0
- data/lib/studium/yaml/german/README.md +2 -0
- data/lib/studium/yaml/german/german_to_english_month_names.yml +16 -0
- data/lib/studium/yaml/grouped_themes/grouped_themes.yml +264 -0
- data/lib/studium/yaml/holidays/holidays.yml +201 -0
- data/lib/studium/yaml/important_exams.yml +286 -0
- data/lib/studium/yaml/inscription_dates_of_universities.yml +60 -0
- data/lib/studium/yaml/lecture_aliases.yml +138 -0
- data/lib/studium/yaml/lecture_information/lecture_information.yml +66145 -0
- data/lib/studium/yaml/log_dir.yml +1 -0
- data/lib/studium/yaml/main_topic/main_topic.yml +11 -0
- data/lib/studium/yaml/max_stats/max_stats.yml +262 -0
- data/lib/studium/yaml/max_stats.yml +263 -0
- data/lib/studium/yaml/meta_themes +1 -0
- data/lib/studium/yaml/mitbelegung/README.md +4 -0
- data/lib/studium/yaml/mitbelegung/mitbelegung.yml +21 -0
- data/lib/studium/yaml/mitteilungsbl/303/244tter/mitteilungsbl/303/244tter.yml +363 -0
- data/lib/studium/yaml/n_total_questions.yml +1 -0
- data/lib/studium/yaml/rename_konsole_tab.yml +1 -0
- data/lib/studium/yaml/roebe/ad_hoc_exam_topics.md +19 -0
- data/lib/studium/yaml/roebe/sommersemester_2024_opportunities.md +441 -0
- data/lib/studium/yaml/semester_planner/README.md +4 -0
- data/lib/studium/yaml/semester_planner/semester_planner.yml +189 -0
- data/lib/studium/yaml/show_topic.yml +1 -0
- data/lib/studium/yaml/statistics/lecture_information.yml +1 -0
- data/lib/studium/yaml/statistics/max_stats.yml +239 -0
- data/lib/studium/yaml/statistics/statistics.yml +77 -0
- data/lib/studium/yaml/week/01_monday.yml +25 -0
- data/lib/studium/yaml/week/02_tuesday.yml +68 -0
- data/lib/studium/yaml/week/03_wednesday.yml +63 -0
- data/lib/studium/yaml/week/04_thursday.yml +20 -0
- data/lib/studium/yaml/week/05_friday.yml +31 -0
- data/lib/studium/yaml/week/06_saturday.yml +16 -0
- data/lib/studium/yaml/week/07_sunday.yml +0 -0
- data/lib/studium/yaml/week/README.md +10 -0
- data/lib/studium.rb +5 -0
- data/studium.gemspec +82 -0
- data/test/testing_colourized_question_and_answer.rb +18 -0
- data/test/testing_studium.rb +244 -0
- data/test/testing_studium_base_class.rb +31 -0
- data/test/testing_the_file_lecture_information.rb +18 -0
- data/test/testing_time_component.rb +29 -0
- metadata +1042 -0
@@ -0,0 +1,3160 @@
|
|
1
|
+
#!/usr/bin/ruby -w
|
2
|
+
# Encoding: UTF-8
|
3
|
+
# frozen_string_literal: true
|
4
|
+
# =========================================================================== #
|
5
|
+
# === Studium::ShowLecturesOnTheCommandline
|
6
|
+
#
|
7
|
+
# This class will show the lectures that belong to a particular curriuclum.
|
8
|
+
# It will also show how many exams have been solved already so far in
|
9
|
+
# the given curriculum at hand.
|
10
|
+
#
|
11
|
+
# For now, we only work on the bachelor-curriculum.
|
12
|
+
# =========================================================================== #
|
13
|
+
# require 'studium/utility_scripts/show_lectures_on_the_commandline/show_lectures_on_the_commandline.rb'
|
14
|
+
# =========================================================================== #
|
15
|
+
require 'studium/base/base.rb'
|
16
|
+
|
17
|
+
module Studium
|
18
|
+
|
19
|
+
class ShowLecturesOnTheCommandline < Base
|
20
|
+
|
21
|
+
require 'studium/constants/constants.rb'
|
22
|
+
include Studium::WebConstants
|
23
|
+
|
24
|
+
require 'studium/utility_scripts/lectures_attributed_to_universities/lectures_attributed_to_universities.rb'
|
25
|
+
require 'studium/curricula/modules/return_n_ects_in_this_module.rb'
|
26
|
+
require 'studium/curricula/sorted_individual_curricula.rb'
|
27
|
+
|
28
|
+
begin
|
29
|
+
require 'html_tags'
|
30
|
+
rescue LoadError; end
|
31
|
+
|
32
|
+
begin
|
33
|
+
require 'open'
|
34
|
+
rescue LoadError; end
|
35
|
+
|
36
|
+
begin
|
37
|
+
require 'studium/toplevel_methods/return_remote_homepage_of_this_lecture.rb'
|
38
|
+
rescue LoadError; end
|
39
|
+
|
40
|
+
# ========================================================================= #
|
41
|
+
# === ALSO_SHOW_URL
|
42
|
+
#
|
43
|
+
# If this constant is set to true then this class will also show
|
44
|
+
# the URL to the target course.
|
45
|
+
# ========================================================================= #
|
46
|
+
ALSO_SHOW_URL = true
|
47
|
+
|
48
|
+
# ========================================================================= #
|
49
|
+
# === determine_from_which_files_to_read
|
50
|
+
#
|
51
|
+
# This method will also assign towards the instance variables
|
52
|
+
# @read_from_these_files.
|
53
|
+
#
|
54
|
+
# The available curricula are stored within file_constants.rb in the
|
55
|
+
# studium/constants/ subdirectory.
|
56
|
+
# ========================================================================= #
|
57
|
+
def determine_from_which_files_to_read(
|
58
|
+
i = FILE_MASTER_VEKTORX, # Default entry comes here.
|
59
|
+
type_of_the_curriculum = :bachelor
|
60
|
+
)
|
61
|
+
# ======================================================================= #
|
62
|
+
# The following case/when menu describes where we can find the
|
63
|
+
# curriculum file and what "type", e. g. bachelor or master,
|
64
|
+
# it is.
|
65
|
+
# ======================================================================= #
|
66
|
+
case i # case tag
|
67
|
+
# ======================================================================= #
|
68
|
+
# === :master_bioinformatics_and_nanobiotechnology_in_molecular_medicine
|
69
|
+
# ======================================================================= #
|
70
|
+
when :master_bioinformatics_and_nanobiotechnology_in_molecular_medicine
|
71
|
+
i = return_and_check_file_for_this_curriculum(i)
|
72
|
+
is_master_curriculum
|
73
|
+
do_show_lecture_attribution_to_universities
|
74
|
+
# ======================================================================= #
|
75
|
+
# === :master_dummy_curriculum
|
76
|
+
#
|
77
|
+
# This refers to any dummy curriculum that we may want to test,
|
78
|
+
# for master-curricula.
|
79
|
+
# ======================================================================= #
|
80
|
+
when :master_dummy_curriculum
|
81
|
+
i = return_and_check_file_for_this_curriculum(i)
|
82
|
+
is_master_curriculum
|
83
|
+
do_show_lecture_attribution_to_universities
|
84
|
+
# ======================================================================= #
|
85
|
+
# === :bachelor_informatik_und_biotechnologie_unter_berücksichtigung_immunanalytisch_molekularmedizinischer_aspekte
|
86
|
+
# ======================================================================= #
|
87
|
+
when :bachelor_informatik_und_biotechnologie_unter_berücksichtigung_immunanalytisch_molekularmedizinischer_aspekte,
|
88
|
+
:bachelor_boku_individuell,
|
89
|
+
:indi2
|
90
|
+
i = return_and_check_file_for_this_curriculum(i)
|
91
|
+
is_bachelor_curriculum
|
92
|
+
is_an_individual_curriculum
|
93
|
+
do_show_lecture_attribution_to_universities
|
94
|
+
# ======================================================================= #
|
95
|
+
# === :bachelor_dummy_curriculum
|
96
|
+
#
|
97
|
+
# This refers to any dummy curriculum that we may want to test.
|
98
|
+
# ======================================================================= #
|
99
|
+
when :bachelor_dummy_curriculum,
|
100
|
+
:dummy
|
101
|
+
i = return_and_check_file_for_this_curriculum(i)
|
102
|
+
is_bachelor_curriculum
|
103
|
+
do_show_lecture_attribution_to_universities
|
104
|
+
# ======================================================================= #
|
105
|
+
# === :bachelor_individual_bachelor_informatik_und_molekulare_biologie
|
106
|
+
# ======================================================================= #
|
107
|
+
when :bachelor_individual_bachelor_informatik_und_molekulare_biologie
|
108
|
+
i = return_and_check_file_for_this_curriculum(i)
|
109
|
+
is_bachelor_curriculum
|
110
|
+
is_an_individual_curriculum
|
111
|
+
do_show_lecture_attribution_to_universities
|
112
|
+
# ======================================================================= #
|
113
|
+
# === :bachelor_forstwirtschaft
|
114
|
+
# ======================================================================= #
|
115
|
+
when :bachelor_forstwirtschaft
|
116
|
+
i = return_and_check_file_for_this_curriculum(i)
|
117
|
+
is_bachelor_curriculum
|
118
|
+
do_show_lecture_attribution_to_universities
|
119
|
+
# ======================================================================= #
|
120
|
+
# === :bachelor_informatik_und_molekulare_biologie
|
121
|
+
# ======================================================================= #
|
122
|
+
when :bachelor_informatik_und_molekulare_biologie,
|
123
|
+
:bachelor_biologische_informatik,
|
124
|
+
:indi3
|
125
|
+
i = return_and_check_file_for_this_curriculum(i)
|
126
|
+
is_bachelor_curriculum
|
127
|
+
is_an_individual_curriculum
|
128
|
+
do_show_lecture_attribution_to_universities
|
129
|
+
# ======================================================================= #
|
130
|
+
# === :master_bioinformatics_and_molecular_biotechnology
|
131
|
+
#
|
132
|
+
# This refers to the indi4 curriculum.
|
133
|
+
# ======================================================================= #
|
134
|
+
when :master_bioinformatics_and_molecular_biotechnology,
|
135
|
+
:indi4
|
136
|
+
i = return_and_check_file_for_this_curriculum(i)
|
137
|
+
is_master_curriculum
|
138
|
+
is_an_individual_curriculum
|
139
|
+
do_show_lecture_attribution_to_universities
|
140
|
+
# ======================================================================= #
|
141
|
+
# === :bachelor_vektor_curriculum
|
142
|
+
# ======================================================================= #
|
143
|
+
when :bachelor_vektor_curriculum,
|
144
|
+
:bachelor_vektorx_curriculum,
|
145
|
+
:indi1
|
146
|
+
i = return_and_check_file_for_this_curriculum(i)
|
147
|
+
is_bachelor_curriculum
|
148
|
+
is_an_individual_curriculum
|
149
|
+
do_show_lecture_attribution_to_universities
|
150
|
+
# ======================================================================= #
|
151
|
+
# === :master_vektoren_curriculum
|
152
|
+
# ======================================================================= #
|
153
|
+
when :master_vektoren_curriculum
|
154
|
+
i = return_and_check_file_for_this_curriculum(i)
|
155
|
+
is_master_curriculum
|
156
|
+
is_an_individual_curriculum
|
157
|
+
do_show_lecture_attribution_to_universities
|
158
|
+
# ======================================================================= #
|
159
|
+
# === :bachelor_bioinformatik_und_biotechnologie
|
160
|
+
# ======================================================================= #
|
161
|
+
when :bachelor_bioinformatik_und_biotechnologie
|
162
|
+
i = return_and_check_file_for_this_curriculum(i)
|
163
|
+
is_bachelor_curriculum
|
164
|
+
is_an_individual_curriculum
|
165
|
+
do_show_lecture_attribution_to_universities
|
166
|
+
# ======================================================================= #
|
167
|
+
# === :bachelor_mikrobiologie_individuelles_curriculum
|
168
|
+
#
|
169
|
+
# Removed as of 29.02.2020.
|
170
|
+
# ======================================================================= #
|
171
|
+
# when :bachelor_mikrobiologie_individuelles_curriculum,
|
172
|
+
# :bachelor_mikrobiologie_curriculum,
|
173
|
+
# :bachelor_mikrobiologie,
|
174
|
+
# :mikrobiologie
|
175
|
+
# i = return_and_check_file_for_this_curriculum(i)
|
176
|
+
# is_bachelor_curriculum
|
177
|
+
# ======================================================================= #
|
178
|
+
# === :bachelor_molekularbiologie_graz
|
179
|
+
# ======================================================================= #
|
180
|
+
when :bachelor_molekularbiologie_graz,
|
181
|
+
:bachelor_molekularbiologie_graz_curriculum,
|
182
|
+
:bachelor_molekularbiologie,
|
183
|
+
:bachelor_molekularbiologie_curriculum
|
184
|
+
i = return_and_check_file_for_this_curriculum(i)
|
185
|
+
is_bachelor_curriculum
|
186
|
+
# ======================================================================= #
|
187
|
+
# === :bachelor_ernährung_curriculum
|
188
|
+
# ======================================================================= #
|
189
|
+
when :bachelor_ernährung_curriculum
|
190
|
+
i = return_and_check_file_for_this_curriculum(i)
|
191
|
+
is_bachelor_curriculum
|
192
|
+
# ======================================================================= #
|
193
|
+
# === :bachelor_verfahrenstechnik_curriculum
|
194
|
+
# ======================================================================= #
|
195
|
+
when :bachelor_verfahrenstechnik_curriculum,
|
196
|
+
:verfahrenstechnik_curriculum,
|
197
|
+
:verfahrenstechnik
|
198
|
+
i = return_and_check_file_for_this_curriculum(i)
|
199
|
+
is_bachelor_curriculum
|
200
|
+
# ======================================================================= #
|
201
|
+
# === :bachelor_genetik_curriculum
|
202
|
+
# ======================================================================= #
|
203
|
+
when :bachelor_genetik_curriculum,
|
204
|
+
:genetik_curriculum
|
205
|
+
i = return_and_check_file_for_this_curriculum(i)
|
206
|
+
is_bachelor_curriculum
|
207
|
+
# ======================================================================= #
|
208
|
+
# === :master_genetik_und_entwicklungsbiologie_curriculum
|
209
|
+
# ======================================================================= #
|
210
|
+
when :master_genetik_und_entwicklungsbiologie_curriculum
|
211
|
+
i = return_and_check_file_for_this_curriculum(i)
|
212
|
+
is_master_curriculum
|
213
|
+
# ======================================================================= #
|
214
|
+
# === :master_pharmazie_curriculum
|
215
|
+
# ======================================================================= #
|
216
|
+
when :master_pharmazie_curriculum,
|
217
|
+
:master_pharmazie
|
218
|
+
i = return_and_check_file_for_this_curriculum(i)
|
219
|
+
is_master_curriculum
|
220
|
+
# ======================================================================= #
|
221
|
+
# === :bachelor_pharmazie_curriculum
|
222
|
+
# ======================================================================= #
|
223
|
+
when :bachelor_pharmazie_curriculum
|
224
|
+
i = return_and_check_file_for_this_curriculum(i)
|
225
|
+
is_bachelor_curriculum
|
226
|
+
# ======================================================================= #
|
227
|
+
# === :master_biologische_chemie_curriculum
|
228
|
+
# ======================================================================= #
|
229
|
+
when :master_biologische_chemie_curriculum,
|
230
|
+
:master_biologische_chemie
|
231
|
+
i = return_and_check_file_for_this_curriculum(i)
|
232
|
+
is_master_curriculum
|
233
|
+
# ======================================================================= #
|
234
|
+
# === :master_lmbt_curriculum
|
235
|
+
# ======================================================================= #
|
236
|
+
when :master_lmbt_curriculum
|
237
|
+
i = return_and_check_file_for_this_curriculum(i)
|
238
|
+
is_master_curriculum
|
239
|
+
# ======================================================================= #
|
240
|
+
# === :bachelor_boku_lmbt_curriculum
|
241
|
+
# ======================================================================= #
|
242
|
+
when :bachelor_boku_lmbt_curriculum
|
243
|
+
i = return_and_check_file_for_this_curriculum(i)
|
244
|
+
is_bachelor_curriculum
|
245
|
+
# ======================================================================= #
|
246
|
+
# === :technical_chemistry_curriculum
|
247
|
+
# ======================================================================= #
|
248
|
+
when :bachelor_technical_chemistry_curriculum,
|
249
|
+
:technical_chemistry_curriculum
|
250
|
+
i = return_and_check_file_for_this_curriculum(i)
|
251
|
+
is_bachelor_curriculum
|
252
|
+
do_show_lecture_attribution_to_universities
|
253
|
+
# ======================================================================= #
|
254
|
+
# === :bachelor_informatik_curriculum
|
255
|
+
# ======================================================================= #
|
256
|
+
when :bachelor_informatik_curriculum,
|
257
|
+
:bachelor_informatik,
|
258
|
+
:binformatik
|
259
|
+
i = return_and_check_file_for_this_curriculum(i)
|
260
|
+
is_bachelor_curriculum
|
261
|
+
# ======================================================================= #
|
262
|
+
# === :bachelor_ktww_curriculum
|
263
|
+
# ======================================================================= #
|
264
|
+
when :bachelor_ktww_curriculum,
|
265
|
+
:bachelor_boku_ktww_curriculum
|
266
|
+
i = return_and_check_file_for_this_curriculum(i)
|
267
|
+
is_bachelor_curriculum
|
268
|
+
# ======================================================================= #
|
269
|
+
# === :bachelor_agrarwissenschaften_curriculum
|
270
|
+
# ======================================================================= #
|
271
|
+
when :bachelor_agrarwissenschaften_curriculum
|
272
|
+
i = return_and_check_file_for_this_curriculum(i)
|
273
|
+
is_bachelor_curriculum
|
274
|
+
# ======================================================================= #
|
275
|
+
# === :bachelor_medizinische_informatik_curriculum
|
276
|
+
# ======================================================================= #
|
277
|
+
when :bachelor_medizinische_informatik_curriculum
|
278
|
+
i = return_and_check_file_for_this_curriculum(i)
|
279
|
+
is_bachelor_curriculum
|
280
|
+
# ======================================================================= #
|
281
|
+
# === :bachelor_botanik_curriculum
|
282
|
+
# ======================================================================= #
|
283
|
+
when :bachelor_botanik_curriculum,
|
284
|
+
:bachelor_botanik
|
285
|
+
i = return_and_check_file_for_this_curriculum(i)
|
286
|
+
is_bachelor_curriculum
|
287
|
+
# ======================================================================= #
|
288
|
+
# === :master_bioinformatik_curriculum
|
289
|
+
# ======================================================================= #
|
290
|
+
when :master_bioinformatik_curriculum
|
291
|
+
i = return_and_check_file_for_this_curriculum(i)
|
292
|
+
is_master_curriculum
|
293
|
+
# ======================================================================= #
|
294
|
+
# === :bachelor_ökologie_curriculum
|
295
|
+
# ======================================================================= #
|
296
|
+
when :bachelor_ökologie_curriculum
|
297
|
+
i = return_and_check_file_for_this_curriculum(i)
|
298
|
+
is_bachelor_curriculum
|
299
|
+
# ======================================================================= #
|
300
|
+
# === :bachelor_master_tu_wien
|
301
|
+
# ======================================================================= #
|
302
|
+
when :bachelor_master_tu_wien
|
303
|
+
i = return_and_check_file_for_this_curriculum(i)
|
304
|
+
is_bachelor_master_curriculum
|
305
|
+
# ======================================================================= #
|
306
|
+
# === :master_molbio_curriculum
|
307
|
+
# ======================================================================= #
|
308
|
+
when :master_molbio_curriculum
|
309
|
+
i = return_and_check_file_for_this_curriculum(i)
|
310
|
+
is_master_curriculum
|
311
|
+
# ======================================================================= #
|
312
|
+
# === :master_immunobiology_curriculum
|
313
|
+
# ======================================================================= #
|
314
|
+
when :master_immunobiology_curriculum
|
315
|
+
i = return_and_check_file_for_this_curriculum(i)
|
316
|
+
is_master_curriculum
|
317
|
+
# ======================================================================= #
|
318
|
+
# === :bachelor_chemie_curriculum
|
319
|
+
# ======================================================================= #
|
320
|
+
when :bachelor_chemie_curriculum
|
321
|
+
i = return_and_check_file_for_this_curriculum(i)
|
322
|
+
is_bachelor_curriculum
|
323
|
+
# ======================================================================= #
|
324
|
+
# === :bachelor_boku_ubrm_curriculum
|
325
|
+
# ======================================================================= #
|
326
|
+
when :bachelor_boku_ubrm_curriculum
|
327
|
+
i = return_and_check_file_for_this_curriculum(i)
|
328
|
+
is_bachelor_curriculum
|
329
|
+
# ======================================================================= #
|
330
|
+
# === :master_tu_vienna_biotechnology_curriculum
|
331
|
+
# ======================================================================= #
|
332
|
+
when :master_tu_vienna_biotechnology_curriculum
|
333
|
+
i = return_and_check_file_for_this_curriculum(i)
|
334
|
+
is_master_curriculum
|
335
|
+
# ======================================================================= #
|
336
|
+
# === :bachelor_molekulare_biologie_curriculum
|
337
|
+
# ======================================================================= #
|
338
|
+
when :bachelor_molekulare_biologie_curriculum
|
339
|
+
i = return_and_check_file_for_this_curriculum(i)
|
340
|
+
is_bachelor_curriculum
|
341
|
+
# ======================================================================= #
|
342
|
+
# === :bachelor_basisblock_biologie
|
343
|
+
# ======================================================================= #
|
344
|
+
when :bachelor_basisblock_biologie
|
345
|
+
i = return_and_check_file_for_this_curriculum(i)
|
346
|
+
is_bachelor_curriculum
|
347
|
+
else
|
348
|
+
if is_on_roebe? and i.is_a?(String) and !File.exist?(i)
|
349
|
+
e 'Warning: input '+i.to_s+' is not registered in this menu().'
|
350
|
+
end
|
351
|
+
end
|
352
|
+
if i.include? 'master_individuelles_' # This must be a master-lecture then.
|
353
|
+
type_of_the_curriculum = :master
|
354
|
+
end if i.is_a? String
|
355
|
+
# ======================================================================= #
|
356
|
+
# We must work on Arrays past this point.
|
357
|
+
# ======================================================================= #
|
358
|
+
unless i.is_a? Array
|
359
|
+
i = [i]
|
360
|
+
end
|
361
|
+
i.flatten! # Keep this important Array flat.
|
362
|
+
@read_from_these_files = i
|
363
|
+
end; alias determine_from_which_file_to_read determine_from_which_files_to_read # === determine_from_which_file_to_read
|
364
|
+
|
365
|
+
# ========================================================================= #
|
366
|
+
# === use_master_bioinformatics_and_nanobiotechnology_in_molecular_medicine
|
367
|
+
# ========================================================================= #
|
368
|
+
def use_master_bioinformatics_and_nanobiotechnology_in_molecular_medicine
|
369
|
+
determine_from_which_file_to_read(:master_bioinformatics_and_nanobiotechnology_in_molecular_medicine)
|
370
|
+
end
|
371
|
+
|
372
|
+
# ========================================================================= #
|
373
|
+
# === use_master_dummy_curriculum
|
374
|
+
# ========================================================================= #
|
375
|
+
def use_master_dummy_curriculum
|
376
|
+
determine_from_which_file_to_read(:master_dummy_curriculum)
|
377
|
+
end
|
378
|
+
|
379
|
+
# ========================================================================= #
|
380
|
+
# === use_bachelor_dummy_curriculum
|
381
|
+
# ========================================================================= #
|
382
|
+
def use_bachelor_dummy_curriculum
|
383
|
+
determine_from_which_file_to_read(:bachelor_dummy_curriculum)
|
384
|
+
end
|
385
|
+
|
386
|
+
# ========================================================================= #
|
387
|
+
# === use_bachelor_informatik_und_biotechnologie_unter_berücksichtigung_immunanalytisch_molekularmedizinischer_aspekte
|
388
|
+
# ========================================================================= #
|
389
|
+
def use_bachelor_informatik_und_biotechnologie_unter_berücksichtigung_immunanalytisch_molekularmedizinischer_aspekte
|
390
|
+
determine_from_which_file_to_read(:bachelor_informatik_und_biotechnologie_unter_berücksichtigung_immunanalytisch_molekularmedizinischer_aspekte)
|
391
|
+
end
|
392
|
+
|
393
|
+
# ========================================================================= #
|
394
|
+
# === use_priority_points
|
395
|
+
#
|
396
|
+
# This will use priority_points as dataset.
|
397
|
+
#
|
398
|
+
# Invocation example:
|
399
|
+
#
|
400
|
+
# ShowLecturesOnTheCommandline --priority-points
|
401
|
+
#
|
402
|
+
# ========================================================================= #
|
403
|
+
def use_priority_points
|
404
|
+
_ = main_dataset?
|
405
|
+
_.select! {|a,b|
|
406
|
+
b.has_key? :priority_points
|
407
|
+
}
|
408
|
+
is_master_curriculum # ← Hardcoded for now.
|
409
|
+
do_not_read_in_from_a_file
|
410
|
+
set_title 'Custom individual curriculum based on priority points'
|
411
|
+
# ======================================================================= #
|
412
|
+
# We only need to use the names of the lectures, hence why we will
|
413
|
+
# use the method .keys().
|
414
|
+
# ======================================================================= #
|
415
|
+
set_all_lectures(_.keys)
|
416
|
+
end
|
417
|
+
|
418
|
+
# ========================================================================= #
|
419
|
+
# === determine_the_type_of_the_curriculum (type tag)
|
420
|
+
#
|
421
|
+
# The allowed types are currently:
|
422
|
+
#
|
423
|
+
# :bachelor
|
424
|
+
# :master
|
425
|
+
# :bachelor_and_master
|
426
|
+
#
|
427
|
+
# The default will be towards :bachelor.
|
428
|
+
# ========================================================================= #
|
429
|
+
def determine_the_type_of_the_curriculum(
|
430
|
+
i = :bachelor
|
431
|
+
)
|
432
|
+
case i
|
433
|
+
when :bachelor_master
|
434
|
+
i = :bachelor_and_master # Slight sanitize-operation here.
|
435
|
+
end
|
436
|
+
@type_of_the_curriculum = i
|
437
|
+
end
|
438
|
+
|
439
|
+
# ========================================================================= #
|
440
|
+
# === use_bachelor_ernährung_curriculum
|
441
|
+
# ========================================================================= #
|
442
|
+
def use_bachelor_ernährung_curriculum
|
443
|
+
determine_from_which_file_to_read(:bachelor_ernährung_curriculum)
|
444
|
+
end
|
445
|
+
|
446
|
+
# ========================================================================= #
|
447
|
+
# === use_bachelor_pharmazie_curriculum
|
448
|
+
# ========================================================================= #
|
449
|
+
def use_bachelor_pharmazie_curriculum
|
450
|
+
determine_from_which_file_to_read(:bachelor_pharmazie_curriculum)
|
451
|
+
end
|
452
|
+
|
453
|
+
# ========================================================================= #
|
454
|
+
# === use_bachelor_molekularbiologie_curriculum
|
455
|
+
# ========================================================================= #
|
456
|
+
def use_bachelor_molekularbiologie_curriculum
|
457
|
+
determine_from_which_file_to_read(:bachelor_molekularbiologie_graz_curriculum)
|
458
|
+
end; alias use_bachelor_molekularbiologie_graz_curriculum use_bachelor_molekularbiologie_curriculum # === use_bachelor_molekularbiologie_graz_curriculum
|
459
|
+
|
460
|
+
# ========================================================================= #
|
461
|
+
# === use_master_biologische_chemie_curriculum
|
462
|
+
# ========================================================================= #
|
463
|
+
def use_master_biologische_chemie_curriculum
|
464
|
+
determine_from_which_file_to_read(:master_biologische_chemie_curriculum)
|
465
|
+
end
|
466
|
+
|
467
|
+
# ========================================================================= #
|
468
|
+
# === use_master_lmbt_curriculum
|
469
|
+
# ========================================================================= #
|
470
|
+
def use_master_lmbt_curriculum
|
471
|
+
determine_from_which_file_to_read(:master_lmbt_curriculum)
|
472
|
+
end
|
473
|
+
|
474
|
+
# ========================================================================= #
|
475
|
+
# === is_master_curriculum
|
476
|
+
#
|
477
|
+
# Denote that our curriculum at hand is a master-curriculum.
|
478
|
+
# ========================================================================= #
|
479
|
+
def is_master_curriculum
|
480
|
+
determine_the_type_of_the_curriculum(:master)
|
481
|
+
end
|
482
|
+
|
483
|
+
# ========================================================================= #
|
484
|
+
# === do_not_read_in_from_a_file
|
485
|
+
# ========================================================================= #
|
486
|
+
def do_not_read_in_from_a_file
|
487
|
+
@read_from_these_files = false
|
488
|
+
end
|
489
|
+
|
490
|
+
# ========================================================================= #
|
491
|
+
# === use_uni_vienna_master_genetik_und_entwicklungsbiologie_curriculum
|
492
|
+
# ========================================================================= #
|
493
|
+
def use_uni_vienna_master_genetik_und_entwicklungsbiologie_curriculum
|
494
|
+
determine_from_which_file_to_read(:master_genetik_und_entwicklungsbiologie_curriculum)
|
495
|
+
end
|
496
|
+
|
497
|
+
# ========================================================================= #
|
498
|
+
# === is_bachelor_curriculum
|
499
|
+
# ========================================================================= #
|
500
|
+
def is_bachelor_curriculum
|
501
|
+
determine_the_type_of_the_curriculum(:bachelor)
|
502
|
+
end
|
503
|
+
|
504
|
+
# ========================================================================= #
|
505
|
+
# === is_bachelor_master_curriculum
|
506
|
+
# ========================================================================= #
|
507
|
+
def is_bachelor_master_curriculum
|
508
|
+
determine_the_type_of_the_curriculum(:bachelor_master)
|
509
|
+
end
|
510
|
+
|
511
|
+
# ========================================================================= #
|
512
|
+
# === use_bachelor_medizinische_informatik_curriculum
|
513
|
+
# ========================================================================= #
|
514
|
+
def use_bachelor_medizinische_informatik_curriculum
|
515
|
+
determine_from_which_file_to_read(:bachelor_medizinische_informatik_curriculum)
|
516
|
+
end
|
517
|
+
|
518
|
+
# ========================================================================= #
|
519
|
+
# === use_bachelor_ökologie_curriculum
|
520
|
+
# ========================================================================= #
|
521
|
+
def use_bachelor_ökologie_curriculum
|
522
|
+
determine_from_which_file_to_read(:bachelor_ökologie_curriculum)
|
523
|
+
end
|
524
|
+
|
525
|
+
# ========================================================================= #
|
526
|
+
# === use_bachelor_informatik_curriculum
|
527
|
+
# ========================================================================= #
|
528
|
+
def use_bachelor_informatik_curriculum
|
529
|
+
determine_from_which_file_to_read(:bachelor_informatik_curriculum)
|
530
|
+
end
|
531
|
+
|
532
|
+
# ========================================================================= #
|
533
|
+
# === use_bachelor_lmbt_curriculum
|
534
|
+
# ========================================================================= #
|
535
|
+
def use_bachelor_lmbt_curriculum
|
536
|
+
determine_from_which_file_to_read(:bachelor_boku_lmbt_curriculum)
|
537
|
+
end
|
538
|
+
|
539
|
+
# ========================================================================= #
|
540
|
+
# === use_bachelor_agrarwissenschaften_curriculum
|
541
|
+
# ========================================================================= #
|
542
|
+
def use_bachelor_agrarwissenschaften_curriculum
|
543
|
+
determine_from_which_file_to_read(:bachelor_agrarwissenschaften_curriculum)
|
544
|
+
end
|
545
|
+
|
546
|
+
# ========================================================================= #
|
547
|
+
# === use_bachelor_master_tu_wien_curriculum
|
548
|
+
# ========================================================================= #
|
549
|
+
def use_bachelor_master_tu_wien_curriculum
|
550
|
+
determine_from_which_file_to_read(:bachelor_master_tu_wien)
|
551
|
+
end
|
552
|
+
|
553
|
+
# ========================================================================= #
|
554
|
+
# === use_bachelor_botanik_curriculum
|
555
|
+
# ========================================================================= #
|
556
|
+
def use_bachelor_botanik_curriculum
|
557
|
+
determine_from_which_file_to_read(:bachelor_botanik_curriculum)
|
558
|
+
end
|
559
|
+
|
560
|
+
# ========================================================================= #
|
561
|
+
# === use_bachelor_genetik_curriculum
|
562
|
+
# ========================================================================= #
|
563
|
+
def use_bachelor_genetik_curriculum
|
564
|
+
determine_from_which_file_to_read(:bachelor_genetik_curriculum)
|
565
|
+
end
|
566
|
+
|
567
|
+
# ========================================================================= #
|
568
|
+
# === use_master_molbio_curriculum
|
569
|
+
# ========================================================================= #
|
570
|
+
def use_master_molbio_curriculum
|
571
|
+
determine_from_which_file_to_read(:master_molbio_curriculum)
|
572
|
+
end
|
573
|
+
|
574
|
+
# ========================================================================= #
|
575
|
+
# === use_uni_vienna_master_bioinformatics_curriculum
|
576
|
+
# ========================================================================= #
|
577
|
+
def use_uni_vienna_master_bioinformatics_curriculum
|
578
|
+
determine_from_which_file_to_read(:master_bioinformatik_curriculum)
|
579
|
+
end
|
580
|
+
|
581
|
+
# ========================================================================= #
|
582
|
+
# === use_bachelor_chemie_curriculum
|
583
|
+
# ========================================================================= #
|
584
|
+
def use_bachelor_chemie_curriculum
|
585
|
+
determine_from_which_file_to_read(:bachelor_chemie_curriculum)
|
586
|
+
end
|
587
|
+
|
588
|
+
# ========================================================================= #
|
589
|
+
# === use_master_pharmazie_curriculum
|
590
|
+
# ========================================================================= #
|
591
|
+
def use_master_pharmazie_curriculum
|
592
|
+
determine_from_which_file_to_read(:master_pharmazie_curriculum)
|
593
|
+
end
|
594
|
+
|
595
|
+
# ========================================================================= #
|
596
|
+
# === use_master_immunobiology_curriculum
|
597
|
+
# ========================================================================= #
|
598
|
+
def use_master_immunobiology_curriculum
|
599
|
+
determine_from_which_file_to_read(:master_immunobiology_curriculum)
|
600
|
+
end
|
601
|
+
|
602
|
+
# ========================================================================= #
|
603
|
+
# === use_bachelor_biologie_basisblock_curriculum
|
604
|
+
# ========================================================================= #
|
605
|
+
def use_bachelor_biologie_basisblock_curriculum
|
606
|
+
determine_from_which_file_to_read(:bachelor_basisblock_biologie)
|
607
|
+
end
|
608
|
+
|
609
|
+
# ========================================================================= #
|
610
|
+
# === use_tu_master_biotechnology_curriculum
|
611
|
+
# ========================================================================= #
|
612
|
+
def use_tu_master_biotechnology_curriculum
|
613
|
+
determine_from_which_file_to_read(:master_tu_vienna_biotechnology_curriculum)
|
614
|
+
end
|
615
|
+
|
616
|
+
# ========================================================================= #
|
617
|
+
# === use_bachelor_molbio_curriculum
|
618
|
+
# ========================================================================= #
|
619
|
+
def use_bachelor_molbio_curriculum
|
620
|
+
determine_from_which_file_to_read(:bachelor_molekulare_biologie_curriculum)
|
621
|
+
end
|
622
|
+
|
623
|
+
# ========================================================================= #
|
624
|
+
# === use_bachelor_technical_chemistry_curriculum
|
625
|
+
# ========================================================================= #
|
626
|
+
def use_bachelor_technical_chemistry_curriculum
|
627
|
+
determine_from_which_file_to_read(:technical_chemistry_curriculum)
|
628
|
+
end
|
629
|
+
|
630
|
+
# ========================================================================= #
|
631
|
+
# === use_bachelor_verfahrenstechnik_curriculum
|
632
|
+
# ========================================================================= #
|
633
|
+
def use_bachelor_verfahrenstechnik_curriculum
|
634
|
+
determine_from_which_file_to_read(:bachelor_verfahrenstechnik_curriculum)
|
635
|
+
end
|
636
|
+
|
637
|
+
# ========================================================================= #
|
638
|
+
# === use_bachelor_ubrm_curriculum
|
639
|
+
# ========================================================================= #
|
640
|
+
def use_bachelor_ubrm_curriculum
|
641
|
+
determine_from_which_file_to_read(:bachelor_boku_ubrm_curriculum)
|
642
|
+
end
|
643
|
+
|
644
|
+
# ========================================================================= #
|
645
|
+
# === use_bachelor_ktww_curriculum
|
646
|
+
# ========================================================================= #
|
647
|
+
def use_bachelor_ktww_curriculum
|
648
|
+
determine_from_which_file_to_read(:bachelor_boku_ktww_curriculum)
|
649
|
+
end
|
650
|
+
|
651
|
+
# ========================================================================= #
|
652
|
+
# === use_mikrobiologie_individuelles_curriculum
|
653
|
+
# ========================================================================= #
|
654
|
+
def use_mikrobiologie_individuelles_curriculum
|
655
|
+
determine_from_which_file_to_read(:bachelor_mikrobiologie_individuelles_curriculum)
|
656
|
+
end; alias use_mikrobiologie_curriculum use_mikrobiologie_individuelles_curriculum # === use_mikrobiologie_curriculum
|
657
|
+
|
658
|
+
# ========================================================================= #
|
659
|
+
# === use_bachelor_forstwirtschaft
|
660
|
+
# ========================================================================= #
|
661
|
+
def use_bachelor_forstwirtschaft
|
662
|
+
determine_from_which_file_to_read(:bachelor_forstwirtschaft)
|
663
|
+
end
|
664
|
+
|
665
|
+
# ========================================================================= #
|
666
|
+
# === use_master_vektoren_curriculum
|
667
|
+
# ========================================================================= #
|
668
|
+
def use_master_vektoren_curriculum
|
669
|
+
determine_from_which_file_to_read(:master_vektoren_curriculum)
|
670
|
+
end
|
671
|
+
|
672
|
+
# ========================================================================= #
|
673
|
+
# === use_bachelor_biologische_informatik
|
674
|
+
# ========================================================================= #
|
675
|
+
def use_bachelor_biologische_informatik
|
676
|
+
determine_from_which_file_to_read(:bachelor_biologische_informatik)
|
677
|
+
end
|
678
|
+
|
679
|
+
# ========================================================================= #
|
680
|
+
# === use_bachelor_vektor_curriculum
|
681
|
+
#
|
682
|
+
# This method is to be used to read from the bachelor-vektorx
|
683
|
+
# curriculum.
|
684
|
+
# ========================================================================= #
|
685
|
+
def use_bachelor_vektor_curriculum
|
686
|
+
determine_from_which_file_to_read(:bachelor_vektor_curriculum)
|
687
|
+
end
|
688
|
+
|
689
|
+
# ========================================================================= #
|
690
|
+
# === return_and_check_file_for_this_curriculum
|
691
|
+
#
|
692
|
+
# The reason we have this method here is so that we can intercept
|
693
|
+
# individual curricula. If it is an individual curriculum then
|
694
|
+
# we will also show the university-attribution in the generated
|
695
|
+
# .html file.
|
696
|
+
# ========================================================================= #
|
697
|
+
def return_and_check_file_for_this_curriculum(i)
|
698
|
+
if i.to_s.include?('individuelles_curriculum') or
|
699
|
+
i.to_s.include?('vector') # Special exception.
|
700
|
+
do_show_lecture_attribution_to_universities
|
701
|
+
end
|
702
|
+
return return_file_for_this_curriculum(i) # ← in studium/base/curriculum.rb
|
703
|
+
end
|
704
|
+
|
705
|
+
# ========================================================================= #
|
706
|
+
# === use_individual_bachelor_informatik_und_molekulare_biologie
|
707
|
+
# ========================================================================= #
|
708
|
+
def use_individual_bachelor_informatik_und_molekulare_biologie
|
709
|
+
determine_from_which_file_to_read(:bachelor_individual_bachelor_informatik_und_molekulare_biologie)
|
710
|
+
end
|
711
|
+
|
712
|
+
# ========================================================================= #
|
713
|
+
# === show_help (help tag)
|
714
|
+
#
|
715
|
+
# The help options for class Studium::ShowLecturesOnTheCommandline
|
716
|
+
# are stored in this method here.
|
717
|
+
#
|
718
|
+
# To invoke this method, do:
|
719
|
+
#
|
720
|
+
# show_lectures_on_the_commandline --help
|
721
|
+
#
|
722
|
+
# ========================================================================= #
|
723
|
+
def show_help
|
724
|
+
e
|
725
|
+
opnn { :no_trailing_colon }
|
726
|
+
help_string = <<-EOF
|
727
|
+
|
728
|
+
|
729
|
+
The following help-options are available and documented:
|
730
|
+
|
731
|
+
EOF
|
732
|
+
e help_string
|
733
|
+
ecomment " #{slateblue('--available-curricula?')} # show "\
|
734
|
+
"which curricula are available"
|
735
|
+
ecomment " #{slateblue('--do-not-show-upcoming-exams')} # Do not show upcoming exams"
|
736
|
+
ecomment " #{slateblue('--show-all-URLs')} # Also "\
|
737
|
+
"show remote URLs of already solved lectures"
|
738
|
+
ecomment " #{slateblue('--priority-points')} # Display "\
|
739
|
+
"a curriculum based on priority points"
|
740
|
+
ecomment " #{slateblue('--use-this-curriculum=foo.md')} # use "\
|
741
|
+
"this curriculum as specified in the file"
|
742
|
+
e
|
743
|
+
end
|
744
|
+
|
745
|
+
# ========================================================================= #
|
746
|
+
# === Studium::ShowLecturesOnTheCommandline::IMAGE_FOR_THE_COMPLETED_MODULE
|
747
|
+
#
|
748
|
+
# This constant resides here because it is only used by this .rb file.
|
749
|
+
# ========================================================================= #
|
750
|
+
IMAGE_FOR_THE_COMPLETED_MODULE =
|
751
|
+
'<img src="/home/x/data/images/studium/COMPLETED_MODULE.png" '\
|
752
|
+
'style="margin-left: 1em; border: 3px solid black">'.dup
|
753
|
+
|
754
|
+
# ========================================================================= #
|
755
|
+
# === return_arrow_pointing_to_the_right_side
|
756
|
+
# ========================================================================= #
|
757
|
+
def return_arrow_pointing_to_the_right_side(
|
758
|
+
optional_margin_left = nil
|
759
|
+
)
|
760
|
+
if optional_margin_left
|
761
|
+
'<img src="/home/x/data/images/STD/PFEIL6_red.png" style="margin-left:'+
|
762
|
+
optional_margin_left.to_s+
|
763
|
+
'">'.dup
|
764
|
+
else
|
765
|
+
'<img src="/home/x/data/images/STD/PFEIL6_red.png">'.dup
|
766
|
+
end
|
767
|
+
end
|
768
|
+
|
769
|
+
# ========================================================================= #
|
770
|
+
# === return_timetable_of_upcoming_exams
|
771
|
+
#
|
772
|
+
# This method is for the display of a HTML timetable <div> element.
|
773
|
+
#
|
774
|
+
# It will be near the bottom part of the auto-generated .html file,
|
775
|
+
# if we actually wish to generate a .html file.
|
776
|
+
# ========================================================================= #
|
777
|
+
def return_timetable_of_upcoming_exams
|
778
|
+
# ======================================================================= #
|
779
|
+
# The dataset consists of the lectures that are part of this curriculum.
|
780
|
+
# ======================================================================= #
|
781
|
+
new_hash = {}
|
782
|
+
dataset = @hash_containing_the_lectures_for_this_curriculum
|
783
|
+
# ======================================================================= #
|
784
|
+
# We have to time-sort this.
|
785
|
+
# ======================================================================= #
|
786
|
+
dataset = dataset.sort_by {|name_of_the_lecture, inner_hash|
|
787
|
+
if inner_hash.has_key? 'exams'
|
788
|
+
exams = inner_hash['exams']
|
789
|
+
if exams.is_a? Array
|
790
|
+
exams = exams.first
|
791
|
+
if exams.include? ', '
|
792
|
+
exams = exams.split(', ').first.strip
|
793
|
+
end
|
794
|
+
end
|
795
|
+
else
|
796
|
+
exams = '01.01.2500' # <- Fake time stamp.
|
797
|
+
end
|
798
|
+
if exams.empty?
|
799
|
+
exams = '01.01.2500' # <- Fake time stamp.
|
800
|
+
end
|
801
|
+
Time.parse(exams)
|
802
|
+
}
|
803
|
+
dataset.each {|inner_array|
|
804
|
+
key = inner_array.first
|
805
|
+
value = inner_array.last
|
806
|
+
new_hash[key] = value
|
807
|
+
}
|
808
|
+
Studium.return_div_timetable_of_upcoming_exams(dataset)
|
809
|
+
end
|
810
|
+
|
811
|
+
# ========================================================================= #
|
812
|
+
# === set_html_string
|
813
|
+
# ========================================================================= #
|
814
|
+
def set_html_string(i)
|
815
|
+
@html_string = i.to_s.dup
|
816
|
+
end
|
817
|
+
|
818
|
+
# ========================================================================= #
|
819
|
+
# === html_string?
|
820
|
+
# ========================================================================= #
|
821
|
+
def html_string?
|
822
|
+
@html_string
|
823
|
+
end
|
824
|
+
|
825
|
+
# ========================================================================= #
|
826
|
+
# === consider_generating_a_html_file (html tag)
|
827
|
+
#
|
828
|
+
# This method can generate a .html file. As a consequence it is fairly
|
829
|
+
# long and messy.
|
830
|
+
# ========================================================================= #
|
831
|
+
def consider_generating_a_html_file(
|
832
|
+
i = @generate_html_file
|
833
|
+
)
|
834
|
+
if i
|
835
|
+
if is_on_roebe?
|
836
|
+
# =================================================================== #
|
837
|
+
# Install the project first in this case, so that the regexes
|
838
|
+
# are up-to-date. This may take quite some time, so it is better
|
839
|
+
# to move this to the end of the method, after the browser
|
840
|
+
# has loaded the page. Actually - we can not do this if we
|
841
|
+
# want to have up-to-date URLs.
|
842
|
+
# =================================================================== #
|
843
|
+
Studium.install_the_project_on_the_given_hostsystem
|
844
|
+
end
|
845
|
+
html_file = "#{log_dir?}html/"\
|
846
|
+
"#{title?.to_s.tr(' ','_').delete('(),')}.html"
|
847
|
+
_ = ''.dup
|
848
|
+
if www_mode?
|
849
|
+
# In this case, do not use the <meta> tag and similar entities.
|
850
|
+
else
|
851
|
+
_ << '<meta charset="UTF-8">'
|
852
|
+
_ << "#{N}<html>#{N}"
|
853
|
+
_ << "<head>#{N}"
|
854
|
+
_ << "<title>#{title?.to_s}</title>#{N}"
|
855
|
+
end
|
856
|
+
# ===================================================================== #
|
857
|
+
# Add tooltip.css next.
|
858
|
+
# ===================================================================== #
|
859
|
+
_ << '<link rel="stylesheet" type="text/css" href="../../../programming/ruby/src/cyberweb/lib/cyberweb/cascading_style_sheets/balloon.css">'
|
860
|
+
if www_mode?
|
861
|
+
# And do nothing as well here.
|
862
|
+
else
|
863
|
+
_ << "</head>#{N}"
|
864
|
+
_ << "<body style=\"font-size: 1.5em; "\
|
865
|
+
"font-family: monospace; "\
|
866
|
+
"padding: 1px; "\
|
867
|
+
"margin: 0px\">#{N}" # <- Open the <body> tax here.
|
868
|
+
end
|
869
|
+
_ << '<div style="border: 1px solid black; padding:2px;">'
|
870
|
+
# ===================================================================== #
|
871
|
+
# Add the title of the curriculum next, as a darkblue and bold
|
872
|
+
# <h1> tag. An example for such a title may be a String like
|
873
|
+
# "Bachelorcurriculum Informatik".
|
874
|
+
# ===================================================================== #
|
875
|
+
_ << HtmlTags.h1(
|
876
|
+
title?.to_s, css_style: 'font-weight: bold; color: darkblue'
|
877
|
+
)+N
|
878
|
+
remote_url = ::Studium.return_homepage_of_this_lecture(title?.to_s)
|
879
|
+
_ << '<b style="margin-left:1em">
|
880
|
+
Link to the remote page:
|
881
|
+
</b>
|
882
|
+
<a style="font-weight: bold; color: darkblue" href="'+remote_url+'">'+title?.to_s+'</a>'
|
883
|
+
if show_loaded_from_which_file? and loaded_from_which_file?
|
884
|
+
loaded_from_which_file?.each {|this_file|
|
885
|
+
_ << '<h2 style="color:slateblue; margin-bottom:4px; margin-left: 0.75em;">
|
886
|
+
Loaded from the file:
|
887
|
+
</h2>'+N
|
888
|
+
_ << '<b style="margin-left:2.0em; font-size:larger; color:blue">'+
|
889
|
+
File.basename(this_file)+'</b>
|
890
|
+
( <span style="font-weight: bold; color:steelblue">'+this_file+'</span> )
|
891
|
+
<br><br><br>'+N
|
892
|
+
}
|
893
|
+
end
|
894
|
+
hash = {}
|
895
|
+
# ===================================================================== #
|
896
|
+
# === Iterate over the lectures here
|
897
|
+
#
|
898
|
+
# Next iterate over all lectures that are part of the curriculum
|
899
|
+
# and build up a temporary Hash, with which we will work.
|
900
|
+
# ===================================================================== #
|
901
|
+
all_lectures?.each {|this_lecture|
|
902
|
+
# =================================================================== #
|
903
|
+
# raw_name_of_the_lecture will also include the lva-id.
|
904
|
+
# =================================================================== #
|
905
|
+
if this_lecture.include? '#' # Handle possible comments next.
|
906
|
+
raw_name_of_the_lecture = this_lecture[0 .. (this_lecture.index('#')-1)].strip
|
907
|
+
else
|
908
|
+
raw_name_of_the_lecture = this_lecture.dup
|
909
|
+
end
|
910
|
+
raw_name_of_the_lecture.squeeze!(' ') # <- Trying this as of March 2018.
|
911
|
+
# =================================================================== #
|
912
|
+
# === Pointer to the lecture-dataset
|
913
|
+
#
|
914
|
+
# Obtain a pointer to the lecture dataset next.
|
915
|
+
# =================================================================== #
|
916
|
+
pointer_to_the_lecture_dataset = @lecture_dataset[raw_name_of_the_lecture]
|
917
|
+
outdated_lecture = pointer_to_the_lecture_dataset[:outdated_lecture]
|
918
|
+
if pointer_to_the_lecture_dataset.nil?
|
919
|
+
next
|
920
|
+
end
|
921
|
+
if @ignore_outdated_lectures and outdated_lecture
|
922
|
+
next
|
923
|
+
end
|
924
|
+
hash[raw_name_of_the_lecture] = pointer_to_the_lecture_dataset
|
925
|
+
}
|
926
|
+
if @this_curriculum_has_n_ects_points_in_total >= 270.0
|
927
|
+
@individual_curriculum = false
|
928
|
+
# ^^^ ad-hoc hack.
|
929
|
+
end
|
930
|
+
# ===================================================================== #
|
931
|
+
# === Handle modules of an individual curriculum
|
932
|
+
#
|
933
|
+
# Next, if we have an individual curriculum, we will use a slightly
|
934
|
+
# different way to order the modules. How is it determined whether
|
935
|
+
# the given curriculum at hand is an individual one? We will
|
936
|
+
# simply use @individual_curriculum.
|
937
|
+
# ===================================================================== #
|
938
|
+
if @individual_curriculum
|
939
|
+
new_hash = ::Studium::SortedIndividualCurricula.new(hash, name_of_the_curriculum?)
|
940
|
+
# =================================================================== #
|
941
|
+
# Rewrite the variable called `hash` next.
|
942
|
+
# =================================================================== #
|
943
|
+
hash.clear
|
944
|
+
max_value = new_hash.max?
|
945
|
+
max_value = 100000 if max_value.nil?
|
946
|
+
max_value = 100000 if max_value > 100000 # Some bug was found on June 2022. Slight hack...
|
947
|
+
(1 .. max_value).each {|module_number|
|
948
|
+
pointer = new_hash[module_number]
|
949
|
+
if pointer.nil?
|
950
|
+
opne 'A nil-value was found for module number '+
|
951
|
+
steelblue(module_number)+'.'
|
952
|
+
# e
|
953
|
+
# e 'The hash was:'
|
954
|
+
# e
|
955
|
+
# pp new_hash
|
956
|
+
# e
|
957
|
+
end
|
958
|
+
pointer.each {|name_of_the_lecture, inner_hash|
|
959
|
+
hash[name_of_the_lecture] = inner_hash
|
960
|
+
} if pointer
|
961
|
+
}
|
962
|
+
end
|
963
|
+
@name_of_the_individual_curriculum_module = ''.dup
|
964
|
+
index = 0
|
965
|
+
# ===================================================================== #
|
966
|
+
# === Iterate over all lectures
|
967
|
+
#
|
968
|
+
# Next, iterate over all lectures. An individual entry may look
|
969
|
+
# like this:
|
970
|
+
#
|
971
|
+
# 185.A47 Physiologie und Grundlagen der Pathologie # 4.5 ECTS, VO, TU WIEN
|
972
|
+
#
|
973
|
+
# Because we may want to sort the dataset according to individual
|
974
|
+
# modules, we will first sort that dataset completely, before
|
975
|
+
# proceeding.
|
976
|
+
# ===================================================================== #
|
977
|
+
hash.each_pair {|this_lecture, pointer_to_the_lecture_dataset| index += 1
|
978
|
+
splitted = this_lecture.split(' ')
|
979
|
+
lva_id = splitted.first # Obtain the ID of the lva.
|
980
|
+
# =================================================================== #
|
981
|
+
# The variable `name_of_the_lecture` contains just the name of
|
982
|
+
# the lecture alone, without leading LVA ID number.
|
983
|
+
# =================================================================== #
|
984
|
+
name_of_the_lecture = splitted[1..-1].join(' ').strip
|
985
|
+
# =================================================================== #
|
986
|
+
# Next, determine some helper-variables. Since as of July 2018
|
987
|
+
# we will try another approach to obtain the specific entries of
|
988
|
+
# our main Hash, via a more generic method called obtain().
|
989
|
+
# =================================================================== #
|
990
|
+
n_ects_points = obtain(:ects, pointer_to_the_lecture_dataset)
|
991
|
+
university = obtain(:university, pointer_to_the_lecture_dataset)
|
992
|
+
lecture_type = obtain(:type, pointer_to_the_lecture_dataset)
|
993
|
+
bereits_absolviert = obtain(:already_solved, pointer_to_the_lecture_dataset)
|
994
|
+
curricula = obtain(:curricula, pointer_to_the_lecture_dataset)
|
995
|
+
is_a_steop_lecture = obtain(:is_a_steop_lecture, pointer_to_the_lecture_dataset)
|
996
|
+
semester = obtain(:semester, pointer_to_the_lecture_dataset).to_s # Must have .to_s due to nil-values.
|
997
|
+
if pointer_to_the_lecture_dataset.has_key? :homepage
|
998
|
+
# ================================================================= #
|
999
|
+
# In this case everything is fine. We will continue.
|
1000
|
+
# ================================================================= #
|
1001
|
+
else
|
1002
|
+
e crimson('The lecture `')+
|
1003
|
+
sfancy(this_lecture)+
|
1004
|
+
crimson('` does not have a registered')
|
1005
|
+
e crimson('remote homepage entry.')
|
1006
|
+
open_this_in_the_browser = false
|
1007
|
+
if open_this_in_the_browser and
|
1008
|
+
is_on_roebe? and
|
1009
|
+
commandline_mode?
|
1010
|
+
# =============================================================== #
|
1011
|
+
# On my home system we will batch-open these in the browser.
|
1012
|
+
# This will only work if they are registered in BeautifulUrl
|
1013
|
+
# though. It will thus not work for every lecture, but it may
|
1014
|
+
# work for many lectures, which can thus be updated.
|
1015
|
+
# =============================================================== #
|
1016
|
+
e crimson('Opening the URL to this lecture in the editor now, so that')
|
1017
|
+
e crimson('this erroneous entry can be corrected.')
|
1018
|
+
this_url = Studium.return_remote_homepage_of_this_lecture(this_lecture)
|
1019
|
+
if this_url != this_lecture # Means we found something.
|
1020
|
+
Studium.open_this_remote_url(this_url)
|
1021
|
+
sleep(0.75)
|
1022
|
+
end
|
1023
|
+
end
|
1024
|
+
end
|
1025
|
+
# =================================================================== #
|
1026
|
+
# === 15.04.2019
|
1027
|
+
#
|
1028
|
+
# Since as of 15.04.2019, we will tap into the method
|
1029
|
+
# Studium.return_homepage_of_this_lecture() to determine
|
1030
|
+
# the remote URL.
|
1031
|
+
#
|
1032
|
+
# In the past we used the BeautifulUrl for this, but it is better
|
1033
|
+
# to make use of the automatically generated regexp-case-when menu,
|
1034
|
+
# residing in the file called
|
1035
|
+
# 'regexes_for_the_registered_lectures.rb'.
|
1036
|
+
# =================================================================== #
|
1037
|
+
use_this_as_remote_url = ::Studium.return_homepage_of_this_lecture(this_lecture)
|
1038
|
+
case semester
|
1039
|
+
when 'both'
|
1040
|
+
semester = 'Sommer / Winter'
|
1041
|
+
when 'winter'
|
1042
|
+
semester = 'Winter'
|
1043
|
+
when 'summer'
|
1044
|
+
semester = 'Sommer'
|
1045
|
+
end
|
1046
|
+
# =================================================================== #
|
1047
|
+
# Also add this to the hash that contains the lectures. We could
|
1048
|
+
# use `this_lecture` as key, but I prefer the name alone, without
|
1049
|
+
# leading lva id. Note that this would, in theory, conflict if we
|
1050
|
+
# have lectures that have the same name but a different LVA ID.
|
1051
|
+
# =================================================================== #
|
1052
|
+
@hash_containing_the_lectures_for_this_curriculum[name_of_the_lecture] =
|
1053
|
+
pointer_to_the_lecture_dataset
|
1054
|
+
@hash_containing_the_lectures_for_this_curriculum[name_of_the_lecture].update(
|
1055
|
+
remote_url: use_this_as_remote_url
|
1056
|
+
)
|
1057
|
+
bereits_absolviert = ja_oder_nein(bereits_absolviert)
|
1058
|
+
case bereits_absolviert
|
1059
|
+
when 'Ja'
|
1060
|
+
colourized_bereits_absolviert = '<b style="color:green">'+bereits_absolviert
|
1061
|
+
# ================================================================= #
|
1062
|
+
# Also append the date when this exam has been completed
|
1063
|
+
# successfully.
|
1064
|
+
# ================================================================= #
|
1065
|
+
on_which_date = @hash_containing_the_lectures_for_this_curriculum[name_of_the_lecture][:already_solved_at].to_s
|
1066
|
+
colourized_bereits_absolviert <<
|
1067
|
+
", absolviert am</b> <b style=\"color:darkgreen\">#{on_which_date}</b>"
|
1068
|
+
else
|
1069
|
+
colourized_bereits_absolviert = '<b style="color:red">'+bereits_absolviert+'</b>'
|
1070
|
+
end
|
1071
|
+
# =================================================================== #
|
1072
|
+
# === Check special-content for the individual curriculum
|
1073
|
+
# =================================================================== #
|
1074
|
+
if individual_curriculum? and
|
1075
|
+
pointer_to_the_lecture_dataset.has_key?(:individual_curricula) and
|
1076
|
+
pointer_to_the_lecture_dataset[:individual_curricula].has_key?(:individual_curriculum_module)
|
1077
|
+
individual_curriculum_module = pointer_to_the_lecture_dataset[:individual_curricula][:individual_curriculum_module]
|
1078
|
+
name_of_the_curriculum_module = pointer_to_the_lecture_dataset[:individual_curricula][:name_of_the_curriculum_module]
|
1079
|
+
if individual_curriculum_module.is_a? Array
|
1080
|
+
individual_curriculum_module = individual_curriculum_module.first
|
1081
|
+
end
|
1082
|
+
if @name_of_the_individual_curriculum_module != individual_curriculum_module
|
1083
|
+
@name_of_the_individual_curriculum_module = individual_curriculum_module
|
1084
|
+
# =============================================================== #
|
1085
|
+
# Next we will show the name of the Module at hand. This will
|
1086
|
+
# be done only for lectures that are part of an individual
|
1087
|
+
# curriculum. We also need to determine the name of the
|
1088
|
+
# curriculum.
|
1089
|
+
# =============================================================== #
|
1090
|
+
# n_ects_in_this_module = Studium.return_n_ects_in_this_module(
|
1091
|
+
# @name_of_the_individual_curriculum_module,
|
1092
|
+
# individual_curriculum_module,
|
1093
|
+
# :use_what_is_best # <- Not ideal for speed-reasons, but for now this must suffice.
|
1094
|
+
# )
|
1095
|
+
# n_ects_in_this_module = '<span style="color: darkgreen">('+
|
1096
|
+
# n_ects_in_this_module.to_s+
|
1097
|
+
# ' ECTS)</span>'
|
1098
|
+
# ^^^ we tried this on 31.12.2019, but it does not work very well.
|
1099
|
+
_ << '<h1><b style="color:midnightblue">Module</b> '\
|
1100
|
+
'<span style="color:#510042">'+
|
1101
|
+
@name_of_the_individual_curriculum_module+
|
1102
|
+
'</span> '+
|
1103
|
+
'<b style="color:midnightblue">'+
|
1104
|
+
name_of_the_curriculum_module.strip+
|
1105
|
+
'</b>'
|
1106
|
+
n_ects_in_that_module = ::Studium.return_n_ects_in_that_module(
|
1107
|
+
title?,
|
1108
|
+
@name_of_the_individual_curriculum_module,
|
1109
|
+
@lecture_dataset
|
1110
|
+
)
|
1111
|
+
# =============================================================== #
|
1112
|
+
# Show how many ECTS points are in that module.
|
1113
|
+
# =============================================================== #
|
1114
|
+
_ << " <span style=\"font-size:0.8em\">[#{n_ects_in_that_module} ECTS in this module]</span>"
|
1115
|
+
# =============================================================== #
|
1116
|
+
# Since as of 29.02.2020 we will also notify whether we have
|
1117
|
+
# completed this module or whether we have not.
|
1118
|
+
# =============================================================== #
|
1119
|
+
if ::Studium.query_based_on_curriculum_title_whether_this_module_been_completed(
|
1120
|
+
title?,
|
1121
|
+
@name_of_the_individual_curriculum_module,
|
1122
|
+
@lecture_dataset
|
1123
|
+
)
|
1124
|
+
_ << IMAGE_FOR_THE_COMPLETED_MODULE.dup
|
1125
|
+
end
|
1126
|
+
# =============================================================== #
|
1127
|
+
# And close the header-tag as well.
|
1128
|
+
# =============================================================== #
|
1129
|
+
_ << '</h1>' # + n_ects_in_this_module
|
1130
|
+
end
|
1131
|
+
end
|
1132
|
+
# =================================================================== #
|
1133
|
+
# Add the university-logo as well. This image can also be clicked
|
1134
|
+
# on via a <a href=""> tag.
|
1135
|
+
# =================================================================== #
|
1136
|
+
clickable_logo = return_proper_logo_for_this_university(university)
|
1137
|
+
# clickable_logo = '<a href="'+return_remote_url(this_lecture)+'">'+clickable_logo+'</a>'
|
1138
|
+
# ^^^ disabled the above as of 16.04.2019
|
1139
|
+
clickable_logo = '<a href="'+use_this_as_remote_url+'">'+clickable_logo+'</a>'
|
1140
|
+
_ << '<span style="margin-left:2.0em">'+
|
1141
|
+
clickable_logo
|
1142
|
+
# =================================================================== #
|
1143
|
+
# If it is a STEOP lecture then a special "STEOP image" will be
|
1144
|
+
# shown.
|
1145
|
+
# =================================================================== #
|
1146
|
+
if is_a_steop_lecture
|
1147
|
+
_ << Studium.relative_steop_picture # return_proper_logo_for_this_university(:steop_picture)
|
1148
|
+
end
|
1149
|
+
# =================================================================== #
|
1150
|
+
# Next, we add the name of the lecture. This can either be
|
1151
|
+
# `this_lecture`, which will include the lecture-id,
|
1152
|
+
# or `name_of_the_lecture`, which will NOT include the lecture-id.
|
1153
|
+
# =================================================================== #
|
1154
|
+
if bereits_absolviert == 'Nein'
|
1155
|
+
# ================================================================= #
|
1156
|
+
# In this case we will use slightly different colours.
|
1157
|
+
# ================================================================= #
|
1158
|
+
bold_name_of_the_lecture = '<b style="font-size:larger; color: navy">'+
|
1159
|
+
this_lecture+
|
1160
|
+
'</b>'
|
1161
|
+
else # this is the default
|
1162
|
+
bold_name_of_the_lecture = '<b style="font-size:larger">'+
|
1163
|
+
this_lecture+
|
1164
|
+
'</b>'
|
1165
|
+
end
|
1166
|
+
_ << " Lehrveranstaltung <b>##{index}</b>:</span> "+
|
1167
|
+
bold_name_of_the_lecture+
|
1168
|
+
', Bereits <b>absolviert</b>? <span style="font-size:larger">'+
|
1169
|
+
colourized_bereits_absolviert+'</span>'\
|
1170
|
+
' (LVA Nummer: <b>'+lva_id.to_s+'</b>; '\
|
1171
|
+
'ECTS: <b>'+n_ects_points.to_s+'</b>; '\
|
1172
|
+
'Lecture Type: <b>'+lecture_type+'</b>; '\
|
1173
|
+
'Semester: <b>'+semester+'</b>; '
|
1174
|
+
_ << "University: <b>#{university}</b>) "
|
1175
|
+
# =================================================================== #
|
1176
|
+
# Add bachelor-or-master lecture next but only for unsolved
|
1177
|
+
# lectures.
|
1178
|
+
# =================================================================== #
|
1179
|
+
if bereits_absolviert == 'Nein'
|
1180
|
+
_ << return_bachelor_or_master_logo(curricula)
|
1181
|
+
end
|
1182
|
+
# =================================================================== #
|
1183
|
+
# Next check whether the lecture is a practical course. If it is we
|
1184
|
+
# will add a certain image, but only if it is NOT yet solved.
|
1185
|
+
# =================================================================== #
|
1186
|
+
if is_this_lecture_a_practical_course?(lecture_type) and
|
1187
|
+
(bereits_absolviert == 'Nein')
|
1188
|
+
_ << PRACTICAL_COURSE_IMAGE
|
1189
|
+
end
|
1190
|
+
_ << "#{HtmlTags::BR}#{N}"
|
1191
|
+
# =================================================================== #
|
1192
|
+
# If the lecture has not been solved yet, we will show the remote
|
1193
|
+
# URL. However had, via the commandline flag --show-all-URLs this
|
1194
|
+
# can be overruled.
|
1195
|
+
# =================================================================== #
|
1196
|
+
shall_we_show_the_url = false
|
1197
|
+
if @show_all_URLs or (bereits_absolviert == 'Nein')
|
1198
|
+
shall_we_show_the_url = true
|
1199
|
+
end
|
1200
|
+
# =================================================================== #
|
1201
|
+
# === Show the associated URL to the given lecture.
|
1202
|
+
# =================================================================== #
|
1203
|
+
if shall_we_show_the_url
|
1204
|
+
this_url = ::Studium.return_homepage_of_this_lecture(this_lecture)
|
1205
|
+
_ << return_arrow_pointing_to_the_right_side('3em')
|
1206
|
+
_ << '<a style="margin-left: 5em; font-size: larger; font-weight:bold" href="'+this_url+'">'+
|
1207
|
+
this_url+
|
1208
|
+
'</a>'+BR+N
|
1209
|
+
# ================================================================= #
|
1210
|
+
# === Show Moodle entries
|
1211
|
+
#
|
1212
|
+
# Since as of 28.10.2019 we will also display the Moodle link
|
1213
|
+
# to this course.
|
1214
|
+
# ================================================================= #
|
1215
|
+
url_to_moodle = ::Studium.return_remote_moodle_link_of_this_lecture(this_lecture)
|
1216
|
+
_ << return_arrow_pointing_to_the_right_side('3em')
|
1217
|
+
if (url_to_moodle == this_lecture) and !url_to_moodle.include?('http')
|
1218
|
+
url_to_moodle = '[No remote URL for Moodle is known for this course.]'
|
1219
|
+
_ << '<span style="margin-left: 5em; font-size: larger; font-weight:bold; color: darkblue" href="'+url_to_moodle+'">'+
|
1220
|
+
url_to_moodle+
|
1221
|
+
'</span>'+BR+N
|
1222
|
+
else
|
1223
|
+
_ << '<a style="margin-left: 5em; font-size: larger; font-weight:bold" href="'+url_to_moodle+'">'+
|
1224
|
+
url_to_moodle+
|
1225
|
+
'</a>'+BR+N
|
1226
|
+
end
|
1227
|
+
# ================================================================= #
|
1228
|
+
# Next, determine when the next exam may happen but only do so
|
1229
|
+
# when the instance variable @show_next_exams is true. We will
|
1230
|
+
# also NOT do any checking here and simply use the first found
|
1231
|
+
# entry, if we are instructed to show the next upcoming exams.
|
1232
|
+
# The user has to update the file lecture_information on his/her
|
1233
|
+
# own.
|
1234
|
+
# ================================================================= #
|
1235
|
+
if @show_next_exams
|
1236
|
+
if pointer_to_the_lecture_dataset.has_key? 'exams'
|
1237
|
+
array_upcoming_exams = pointer_to_the_lecture_dataset['exams']
|
1238
|
+
first_entry = array_upcoming_exams.first
|
1239
|
+
first_entry = remove_weekdays(first_entry)
|
1240
|
+
weekday = first_entry
|
1241
|
+
if weekday.include? ','
|
1242
|
+
weekday = weekday.split(',').first
|
1243
|
+
end
|
1244
|
+
weekday = english_to_german_weekday(
|
1245
|
+
translate_dd_mm_yyyy_to_weekday(weekday)
|
1246
|
+
)
|
1247
|
+
_ << '<span style="font-weight:bold; font-size: larger;margin-left:9em"> ^^^ '+
|
1248
|
+
'<b style="color: teal">Next exam:</b> '+
|
1249
|
+
weekday+' '+
|
1250
|
+
first_entry+'</span>'+BR+N
|
1251
|
+
end
|
1252
|
+
end
|
1253
|
+
end
|
1254
|
+
}
|
1255
|
+
# =================================================================== #
|
1256
|
+
# Next add how many lectures are in this Curriculum.
|
1257
|
+
# =================================================================== #
|
1258
|
+
_ << BR+
|
1259
|
+
return_how_many_lectures_are_in_this_curriculum_and_how_many_of_them_are_already_solved(:use_for_html).join(' ')+N
|
1260
|
+
_ << BR+BR+
|
1261
|
+
return_how_many_ects_points_this_curriculum_has_in_total(:no_colours)+'<br>'+N
|
1262
|
+
_ << BR+
|
1263
|
+
return_how_many_ects_points_have_been_passed_already(:use_for_html).join(' ')+N
|
1264
|
+
# =================================================================== #
|
1265
|
+
# Determine how many lectures are missing still.
|
1266
|
+
# =================================================================== #
|
1267
|
+
n_missing_lectures = n_total_lectures?.to_i - n_lectures_completed?
|
1268
|
+
_ << "#{BR}#{BR}There are still <b>#{n_missing_lectures.to_s}</b> lectures missing "\
|
1269
|
+
"before this curriculum has been completed successfully."
|
1270
|
+
# =================================================================== #
|
1271
|
+
# Next, add average grade, if we are using it at all altogether.
|
1272
|
+
# =================================================================== #
|
1273
|
+
if @do_report
|
1274
|
+
average_grade = return_the_average_grade
|
1275
|
+
_ << "\n<br><br>The <span style=\"font-weight:800;padding-left:2px; padding-right:2px;background-color: black; color:gold\">average grade</span> "\
|
1276
|
+
"is: <b style=\"color:darkgreen\">#{average_grade}</b>\n\n<br><br>"
|
1277
|
+
end
|
1278
|
+
# =================================================================== #
|
1279
|
+
# Also add the timetable of upcoming exams next, a html <div>.
|
1280
|
+
# =================================================================== #
|
1281
|
+
if @show_next_exams
|
1282
|
+
_ << "#{return_timetable_of_upcoming_exams}#{N}"
|
1283
|
+
end
|
1284
|
+
_ << "#{N}</div>"
|
1285
|
+
_ << @append_this_string_onto_the_html_string
|
1286
|
+
# =================================================================== #
|
1287
|
+
# Store into e. g.:
|
1288
|
+
# "#{log_dir?}html/#{title?.to_s.tr(' ','_').delete('()')}.html"
|
1289
|
+
# =================================================================== #
|
1290
|
+
set_html_string(_)
|
1291
|
+
_ << "</html>#{N}"
|
1292
|
+
# =================================================================== #
|
1293
|
+
# We will only generate a .html file if we are using the commandline
|
1294
|
+
# variant.
|
1295
|
+
# =================================================================== #
|
1296
|
+
if cmdline?
|
1297
|
+
result = "Next storing into\n".dup
|
1298
|
+
result << " `#{sfile(html_file)}`\n"
|
1299
|
+
also_open_in_the_browser = true
|
1300
|
+
if also_open_in_the_browser
|
1301
|
+
result << "\nThat page will be opened via the browser as well."
|
1302
|
+
opne result
|
1303
|
+
write_what_into(_, html_file)
|
1304
|
+
Open.in_browser(html_file) { :be_silent } # Don't show the exact command.
|
1305
|
+
end
|
1306
|
+
end
|
1307
|
+
end
|
1308
|
+
end
|
1309
|
+
|
1310
|
+
# ========================================================================= #
|
1311
|
+
# === do_generate_a_html_file
|
1312
|
+
#
|
1313
|
+
# This method can be used to generate a .html file no matter what.
|
1314
|
+
#
|
1315
|
+
# The other method, consider_generating_a_html_file, will instead
|
1316
|
+
# honour a certain instance variable.
|
1317
|
+
# ========================================================================= #
|
1318
|
+
def do_generate_a_html_file
|
1319
|
+
consider_generating_a_html_file(true)
|
1320
|
+
end
|
1321
|
+
|
1322
|
+
# ========================================================================= #
|
1323
|
+
# === initialize
|
1324
|
+
# ========================================================================= #
|
1325
|
+
def initialize(
|
1326
|
+
commandline_arguments = [],
|
1327
|
+
run_already = true
|
1328
|
+
)
|
1329
|
+
reset
|
1330
|
+
case commandline_arguments
|
1331
|
+
# ======================================================================= #
|
1332
|
+
# === :do_not_run_yet
|
1333
|
+
# ======================================================================= #
|
1334
|
+
when :do_not_run_yet
|
1335
|
+
commandline_arguments = nil
|
1336
|
+
run_already = false
|
1337
|
+
end
|
1338
|
+
set_commandline_arguments(
|
1339
|
+
commandline_arguments
|
1340
|
+
)
|
1341
|
+
case run_already
|
1342
|
+
# ======================================================================= #
|
1343
|
+
# === :do_not_run_yet
|
1344
|
+
# ======================================================================= #
|
1345
|
+
when :do_not_run_yet
|
1346
|
+
run_already = false
|
1347
|
+
end
|
1348
|
+
# ======================================================================= #
|
1349
|
+
# === Handle blocks given to this class
|
1350
|
+
# ======================================================================= #
|
1351
|
+
if block_given?
|
1352
|
+
yielded = yield
|
1353
|
+
case yielded
|
1354
|
+
# ===================================================================== #
|
1355
|
+
# === :do_not_run_yet
|
1356
|
+
# ===================================================================== #
|
1357
|
+
when :do_not_run_yet
|
1358
|
+
run_already = false
|
1359
|
+
# ===================================================================== #
|
1360
|
+
# === :www
|
1361
|
+
# ===================================================================== #
|
1362
|
+
when :www
|
1363
|
+
set_www_mode
|
1364
|
+
end
|
1365
|
+
end
|
1366
|
+
run if run_already
|
1367
|
+
end
|
1368
|
+
|
1369
|
+
# ========================================================================= #
|
1370
|
+
# === try_to_rename_kde_konsole_tab
|
1371
|
+
#
|
1372
|
+
# This method can be used to rename the KDE Konsole tab.
|
1373
|
+
# ========================================================================= #
|
1374
|
+
def try_to_rename_kde_konsole_tab(
|
1375
|
+
use_this_title = return_name_of_the_curriculum
|
1376
|
+
)
|
1377
|
+
if rename_konsole_tab?
|
1378
|
+
begin
|
1379
|
+
require 'roebe/requires/require_kde_konsole.rb'
|
1380
|
+
Roebe::KdeKonsole.new(use_this_title) { :be_quiet }
|
1381
|
+
rescue LoadError
|
1382
|
+
if is_on_roebe?
|
1383
|
+
e "The #{steelblue('class Roebe::KdeKonsole')} is not "\
|
1384
|
+
"available. Install the roebe-gem."
|
1385
|
+
end
|
1386
|
+
end
|
1387
|
+
end
|
1388
|
+
end
|
1389
|
+
|
1390
|
+
# ========================================================================= #
|
1391
|
+
# === menu (menu tag)
|
1392
|
+
# ========================================================================= #
|
1393
|
+
def menu(
|
1394
|
+
i = commandline_arguments?
|
1395
|
+
)
|
1396
|
+
if i.is_a? Array
|
1397
|
+
i.each {|entry| menu(entry) }
|
1398
|
+
else
|
1399
|
+
case i.to_s # case tag
|
1400
|
+
# ===================================================================== #
|
1401
|
+
# === lectures_commandline --ignore-outdated
|
1402
|
+
# ===================================================================== #
|
1403
|
+
when /^-?-?ignore(-|_| )?outdated$/i
|
1404
|
+
do_ignore_outdated_lectures
|
1405
|
+
# ===================================================================== #
|
1406
|
+
# === lectures_commandline --indi3
|
1407
|
+
#
|
1408
|
+
# This is indi3.
|
1409
|
+
# ===================================================================== #
|
1410
|
+
when /^-?-?master(-|_| )?bioinformatics(-|_| )?and(-|_| )?molecular(-|_| )?biotechnology$/i,
|
1411
|
+
/^-?-?indi3$/i
|
1412
|
+
use_master_bioinformatics_and_nanobiotechnology_in_molecular_medicine
|
1413
|
+
# ===================================================================== #
|
1414
|
+
# === lectures_commandline --bachelor-vektorx
|
1415
|
+
# ===================================================================== #
|
1416
|
+
when /^-?-?bachelor(-|_| )?vektorx?$/i,
|
1417
|
+
/^-?-?bachelor(-|_| )?vektore?n?$/,
|
1418
|
+
/^-?-?bachelor(-|_| )?vector$/,
|
1419
|
+
/^-?-?bachelor(-|_| )?vector(-|_| )?curriculum$/,
|
1420
|
+
/^-?-?molekularsimulatorisch(-|_| )?therapeutische(-|_| )?vektoren$/i,
|
1421
|
+
/^-?-?bachelor(-|_| )?molekularsimulatorisch(-|_| )?therapeutische(-|_| )?vektoren$/i,
|
1422
|
+
/^-?-?bachelor(-|_| )?individuelles(-|_| )?curriculum(-|_| )?molekularsimulatorische(-|_| )?vektoren(-|_| )?in(-|_| )?der(-|_| )?biotechnologie$/i,
|
1423
|
+
/^-?-?bachelor(-|_| )?individuelles(-|_| )?curriculum(-|_| )?molekularsimulatorische(-|_| )?vektoren(-|_| )?in(-|_| )?biotechnologie(-|_| )?und(-|_| )?bioinformatik$/i,
|
1424
|
+
/^-?-?bvektor$/i,
|
1425
|
+
/^-?-?individuelles(-|_| )?bachelor(-|_| )?studium/i,
|
1426
|
+
/^-?-?indi4$/i,
|
1427
|
+
'vektoren'
|
1428
|
+
use_bachelor_vektor_curriculum
|
1429
|
+
# ===================================================================== #
|
1430
|
+
# === lectures_commandline --bioinf2
|
1431
|
+
#
|
1432
|
+
# This is indi2, the bachelor-programme at the BOKU.
|
1433
|
+
#
|
1434
|
+
# The full name is:
|
1435
|
+
#
|
1436
|
+
# "Bachelorcurriculum Informatik und Biotechnologie unter Berücksichtigung immunanalytisch-molekularmedizinischer Aspekte"
|
1437
|
+
#
|
1438
|
+
# ===================================================================== #
|
1439
|
+
when /^-?-?bioinf2$/i,
|
1440
|
+
/^-?-?bachelor(-|_| )?bioinformatik(-|_| )?und(-|_| )?molekulare(-|_| )?biotechnologie$/i,
|
1441
|
+
/^-?-?bachelor(-|_| )?bioinformatik(-|_| )?und(-|_| )?biotechnologie$/i,
|
1442
|
+
/^-?-?bachelor(-|_| )?bioinformatik(-|_| )?an(-|_| )?der(-|_| )?boku$/i,
|
1443
|
+
/^-?-?indi2$/i
|
1444
|
+
use_bachelor_informatik_und_biotechnologie_unter_berücksichtigung_immunanalytisch_molekularmedizinischer_aspekte
|
1445
|
+
# ===================================================================== #
|
1446
|
+
# === lectures_commandline --biologische_informatik
|
1447
|
+
#
|
1448
|
+
# This is indi1, at the TU Vienna.
|
1449
|
+
# ===================================================================== #
|
1450
|
+
when /^-?-?biologische(-|_| )?informatik$/i,
|
1451
|
+
/^-?-?bachelor(-|_| )?biologische(-|_| )?informatik$/i,
|
1452
|
+
/^-?-?use(-|_| )?individual(-|_| )?bachelor(-|_| )?informatik(-|_| )?und(-|_| )?molekulare(-|_| )?biologie$/i,
|
1453
|
+
/^-?-?indi1$/i,
|
1454
|
+
/^-?-?indi$/i
|
1455
|
+
use_bachelor_biologische_informatik
|
1456
|
+
# ===================================================================== #
|
1457
|
+
# === lectures_commandline --mdummy
|
1458
|
+
# ===================================================================== #
|
1459
|
+
when /^-?-?master(-|_| )?dummy(-|_| )?curriculum$/i,
|
1460
|
+
/^-?-?mdummy$/i
|
1461
|
+
use_master_dummy_curriculum
|
1462
|
+
# ===================================================================== #
|
1463
|
+
# === lectures_commandline --dummy
|
1464
|
+
# ===================================================================== #
|
1465
|
+
when /^-?-?bachelor(-|_| )?dummy(-|_| )?curriculum$/i,
|
1466
|
+
/^-?-?bdummy$/i,
|
1467
|
+
/^-?-?dummy$/i
|
1468
|
+
use_bachelor_dummy_curriculum
|
1469
|
+
# ===================================================================== #
|
1470
|
+
# === lectures_commandline --aggregate
|
1471
|
+
#
|
1472
|
+
# This entry point really combines all curricula and lectures
|
1473
|
+
# that I intend to pass.
|
1474
|
+
#
|
1475
|
+
# Invocation example on my home system:
|
1476
|
+
#
|
1477
|
+
# bigaggregate
|
1478
|
+
#
|
1479
|
+
# ===================================================================== #
|
1480
|
+
when /^-?-?aggregate$/i
|
1481
|
+
use_master_vektoren_curriculum # Combine the bachelor-master curricula.
|
1482
|
+
is_not_an_individual_curriculum
|
1483
|
+
prepend_this_to_dataset(
|
1484
|
+
%i(
|
1485
|
+
bachelor_vektorx_curriculum
|
1486
|
+
master_vektorx_curriculum
|
1487
|
+
bachelor_informatik_und_molekulare_biologie
|
1488
|
+
bachelor_lbt
|
1489
|
+
bachelor_bioinformatik_an_der_boku
|
1490
|
+
|
1491
|
+
master_lbt
|
1492
|
+
master_bioinformatik_an_der_boku
|
1493
|
+
) # bachelor_agrarwissenschaften
|
1494
|
+
# bachelor_tu_wien
|
1495
|
+
)
|
1496
|
+
prepend_this_to_dataset(
|
1497
|
+
['892100 Physik (KTWW+HNT)']
|
1498
|
+
)
|
1499
|
+
sanitize_the_dataset
|
1500
|
+
uniq_the_dataset
|
1501
|
+
# ===================================================================== #
|
1502
|
+
# === lectures_commandline --aggregate-only-individual-curricula
|
1503
|
+
#
|
1504
|
+
# This entry point combines all individual curricula and lectures
|
1505
|
+
# in these curricula that I wish to pass.
|
1506
|
+
# ===================================================================== #
|
1507
|
+
when /^-?-?aggregate(-|_| )?only(-|_| )?individual(-|_| )?curricula$/i
|
1508
|
+
use_master_vektoren_curriculum # Combine the bachelor-master curricula.
|
1509
|
+
prepend_this_to_dataset(
|
1510
|
+
%i(
|
1511
|
+
bachelor_vektorx_curriculum
|
1512
|
+
bachelor_informatik_und_molekulare_biologie
|
1513
|
+
bachelor_bioinformatik_an_der_boku
|
1514
|
+
)
|
1515
|
+
)
|
1516
|
+
sanitize_the_dataset
|
1517
|
+
uniq_the_dataset
|
1518
|
+
# ===================================================================== #
|
1519
|
+
# === lectures_commandline --lmbt_curriculum
|
1520
|
+
# ===================================================================== #
|
1521
|
+
when /^-?-?bachelor(-|_| )?lm?bt$/i,
|
1522
|
+
/^-?-?bachelor(-|_| )?lm?bt$(-|_| )?curriculum/i,
|
1523
|
+
/^-?-?lm?bt$(-|_| )?curriculum/i,
|
1524
|
+
'lmbt',
|
1525
|
+
/lbt/i
|
1526
|
+
use_bachelor_lmbt_curriculum
|
1527
|
+
# ===================================================================== #
|
1528
|
+
# === lectures_commandline --bachelor-master-vektorx
|
1529
|
+
#
|
1530
|
+
# This entry point is the "bachelor-master-vector" joint
|
1531
|
+
# curriculum.
|
1532
|
+
#
|
1533
|
+
# Another invocation example:
|
1534
|
+
#
|
1535
|
+
# lectures_commandline --bmvec
|
1536
|
+
#
|
1537
|
+
# ===================================================================== #
|
1538
|
+
when /^-?-?bachelor(-|_| )?master(-|_| )?vektorx?$/i,
|
1539
|
+
/^-?-?bachelor(-|_| )?master(-|_| )?vektoren$/i,
|
1540
|
+
/^-?-?bachelor(-|_| )?master(-|_| )?vector$/i,
|
1541
|
+
/^-?-?bmvec$/i,
|
1542
|
+
/^-?-?bmvek$/i
|
1543
|
+
use_master_vektoren_curriculum # Combine the bachelor-master curricula.
|
1544
|
+
prepend_this_to_dataset(:bachelor_vektorx_curriculum) # And then prepend the dataset.
|
1545
|
+
# ===================================================================== #
|
1546
|
+
# === master_vektoren
|
1547
|
+
#
|
1548
|
+
# This entry point deals with the master lecture of the
|
1549
|
+
# vector-curriculum.
|
1550
|
+
#
|
1551
|
+
# Invocation example:
|
1552
|
+
#
|
1553
|
+
# lectures_commandline --master_vektorx
|
1554
|
+
#
|
1555
|
+
# ===================================================================== #
|
1556
|
+
when /^-?-?master(-|_| )?ve(c|k)torx$/,
|
1557
|
+
/^-?-?master(_|-)?molekularsimulatorisch(_|-)?therapeutische(_|-)?vektoren$/i,
|
1558
|
+
/^-?-?master(_|-)?individuelles(_|-)?curriculum(_|-)?molekularsimulatorische(_|-)?vektoren/i, # lcommandline --master-individuelles-curriculum-molekularsimulatorische-vektoren
|
1559
|
+
/^-?-?master(_|-)?vektoren$/i,
|
1560
|
+
/^-?-?master(-|_| )?ve(c|k)tors?$/,
|
1561
|
+
/^-?-?master(-|_| )?individuell/,
|
1562
|
+
'mastervect',
|
1563
|
+
'mastersim'
|
1564
|
+
use_master_vektoren_curriculum
|
1565
|
+
# ===================================================================== #
|
1566
|
+
# === lectures_commandline --forstwirtschaft
|
1567
|
+
# ===================================================================== #
|
1568
|
+
when /^-?-?forstwirtschaft$/i,
|
1569
|
+
/^-?-?bachelor(-|_| )?forstwirtschaft$/i
|
1570
|
+
use_bachelor_forstwirtschaft
|
1571
|
+
# ===================================================================== #
|
1572
|
+
# === lectures_commandline --bachelor-ern
|
1573
|
+
# ===================================================================== #
|
1574
|
+
when /^-?-?bachelor(-|_| )?ernährung?$/,
|
1575
|
+
/^-?-?bachelor(-|_| )?ern$/,
|
1576
|
+
/^-?-?bachelor(-|_| )?ernährung(_|-)?uni(_|-)?wien$/,
|
1577
|
+
/^-?-?bachelor(-|_| )?ernährungswissenschaften$/,
|
1578
|
+
/^-?-?bachelor(-|_| )?nutrition(_|-)?science$/i,
|
1579
|
+
/-?-?ernährung/,
|
1580
|
+
'ernährungswissenschaften',
|
1581
|
+
'ern'
|
1582
|
+
use_bachelor_ernährung_curriculum
|
1583
|
+
# ===================================================================== #
|
1584
|
+
# === lectures_commandline --bachelor_molekularbiologie_graz
|
1585
|
+
# ===================================================================== #
|
1586
|
+
when /^-?-?bachelor(-|_| )?molekularbiologie(-|_| )?graz$/i,
|
1587
|
+
/^-?-?bachelor(-|_| )?molekularbiologie(-|_| )?graz(-|_| )?curriculum$/i,
|
1588
|
+
/^-?-?bachelor(-|_| )?molbio(-|_| )?graz$/i,
|
1589
|
+
/^-?-?bachelor(-|_| )?molekularbiologie$/i,
|
1590
|
+
/^-?-?graz$/i
|
1591
|
+
use_bachelor_molekularbiologie_curriculum
|
1592
|
+
# ===================================================================== #
|
1593
|
+
# === lectures_commandline --bachelor-pharmazie
|
1594
|
+
# ===================================================================== #
|
1595
|
+
when /^-?-?bachelor(-|_| )?pharmazie$/i,
|
1596
|
+
/^-?-?pharmazie$/i,
|
1597
|
+
/^-?-?pharm$/i,
|
1598
|
+
/^-?-?bachelor(-|_| )?pharm$/i
|
1599
|
+
use_bachelor_pharmazie_curriculum
|
1600
|
+
# ===================================================================== #
|
1601
|
+
# === lectures_commandline --bachelor_verfahrenstechnik
|
1602
|
+
# ===================================================================== #
|
1603
|
+
when /^-?-?bachelor(-|_| )?verfahrenstechnik$/i,
|
1604
|
+
/^-?-?verfahrenstechnik$/i
|
1605
|
+
use_bachelor_verfahrenstechnik_curriculum
|
1606
|
+
# ===================================================================== #
|
1607
|
+
# === lectures_commandline --bachelor_technical_chemistry
|
1608
|
+
# ===================================================================== #
|
1609
|
+
when /^-?-?bachelor(-|_| )?technical(-|_| )?chemistry?$/i
|
1610
|
+
use_bachelor_technical_chemistry_curriculum
|
1611
|
+
# ===================================================================== #
|
1612
|
+
# === lectures_commandline --master-lmbt
|
1613
|
+
# ===================================================================== #
|
1614
|
+
when /^-?-?(-|_| )?lm?bt$/i,
|
1615
|
+
/^-?-?master(-|_| )?lm?bt(-|_| )?curriculum$/i,
|
1616
|
+
/^-?-?master(-|_| )?biotech$/i,
|
1617
|
+
/^-?-?master(-|_| )?lmbt$/i,
|
1618
|
+
/LBT2/i,
|
1619
|
+
'biotechnology',
|
1620
|
+
'masterbiotech'
|
1621
|
+
use_master_lmbt_curriculum
|
1622
|
+
# ===================================================================== #
|
1623
|
+
# === lectures_commandline --master-pharmazie
|
1624
|
+
# ===================================================================== #
|
1625
|
+
when /^-?-?master(-|_| )?pharmazie$/i,
|
1626
|
+
/^-?-?master(-|_| )?pharmazie(-|_| )?curriculum$/i,
|
1627
|
+
'mpharmacy',
|
1628
|
+
'mpharma'
|
1629
|
+
use_master_pharmazie_curriculum
|
1630
|
+
# ===================================================================== #
|
1631
|
+
# === lectures_commandline --master-biologische-chemie
|
1632
|
+
# ===================================================================== #
|
1633
|
+
when /^-?-?master(-|_| )?biologische(-|_| )?chemie$/i,
|
1634
|
+
/^-?-?master(-|_| )?biologische(-|_| )?chemie(-|_| )?curriculum$/i,
|
1635
|
+
/^-?-?biologische(-|_| )?chemie$/i,
|
1636
|
+
'mbiochem'
|
1637
|
+
use_master_biologische_chemie_curriculum
|
1638
|
+
# ===================================================================== #
|
1639
|
+
# === lectures_commandline --tu_master_biotech
|
1640
|
+
# ===================================================================== #
|
1641
|
+
when /^-?-?master(_|-)?tu(_|-)?biotechnology$/i,
|
1642
|
+
/^-?-?tu(_|-)?master(_|-)?biotech$/i,
|
1643
|
+
/^-?-?master(_|-)?tu(_|-)?wien(_|-)?biotechnologie$/i,
|
1644
|
+
/^-?-?tu(_|-)?vienna(_|-)?biotech(_|-)?master$/i,
|
1645
|
+
/^-?-?master(_|-)?tuwienbiotech$/i,
|
1646
|
+
/^-?-?tu(_|-)?wien(_|-)?biotech$/i
|
1647
|
+
use_tu_master_biotechnology_curriculum
|
1648
|
+
# ===================================================================== #
|
1649
|
+
# === lectures_commandline --bachelor-mikrobiologie
|
1650
|
+
# ===================================================================== #
|
1651
|
+
when /^-?-?bachelor(-|_| )?mikrobiologie$/i,
|
1652
|
+
/^-?-?mikrobiologie$/i,
|
1653
|
+
/^-?-?microbiology$/i
|
1654
|
+
use_mikrobiologie_individuelles_curriculum
|
1655
|
+
# ===================================================================== #
|
1656
|
+
# === lectures_commandline --priority-points
|
1657
|
+
# ===================================================================== #
|
1658
|
+
when /^-?-?priority(-|_| )?points$/i
|
1659
|
+
use_priority_points
|
1660
|
+
# ===================================================================== #
|
1661
|
+
# === lectures_commandline --informatik_curriculum
|
1662
|
+
# ===================================================================== #
|
1663
|
+
when /^-?-?informatik(_|-)?curriculum$/i,
|
1664
|
+
/^-?-?informatik$/i,
|
1665
|
+
/^-?-?bachelor(_|-)?informatik$/i,
|
1666
|
+
/^-?-?bachelor(_|-)?informatik(_|-)?curriculum$/i,
|
1667
|
+
'informatik'
|
1668
|
+
use_bachelor_informatik_curriculum
|
1669
|
+
# ===================================================================== #
|
1670
|
+
# === lectures_commandline --ktww_curriculum
|
1671
|
+
# ===================================================================== #
|
1672
|
+
when /^-?-?ktww(_|-)?curriculum$/i,
|
1673
|
+
/^-?-?boku(_|-)?ktww$/i,
|
1674
|
+
/^-?-?ktww$/i,
|
1675
|
+
/^-?-?bachelor(_|-)?ktww$/i,
|
1676
|
+
/^-?-?bachelor(_|-)?boku(_|-)?ktww(_|-)?curriculum$/i
|
1677
|
+
use_bachelor_ktww_curriculum
|
1678
|
+
# ===================================================================== #
|
1679
|
+
# === --no-html-page
|
1680
|
+
# ===================================================================== #
|
1681
|
+
when /^-?-?no(-|_| )?html(-|_| )?page$/,
|
1682
|
+
/^-?-?no(-|_| )?html$/
|
1683
|
+
no_html_page
|
1684
|
+
# ===================================================================== #
|
1685
|
+
# === lectures_commandline --aw_curriculum
|
1686
|
+
# ===================================================================== #
|
1687
|
+
when /^-?-?aw(_|-)?curriculum$/i,
|
1688
|
+
/^-?-?boku(_|-)?aw$/i,
|
1689
|
+
/^-?-?AW$/i,
|
1690
|
+
/^-?-?agrarwissenschaften$/i,
|
1691
|
+
/^-?-?bachelor(_|-)?agrarwissenschaften$/i,
|
1692
|
+
'bachelorAW'
|
1693
|
+
use_bachelor_agrarwissenschaften_curriculum
|
1694
|
+
# ===================================================================== #
|
1695
|
+
# === lectures_commandline --master-genetik-und-entwicklungsbiologie
|
1696
|
+
# ===================================================================== #
|
1697
|
+
when /^-?-?master(-|_| )?genetik(-|_| )?und(-|_| )?entwicklungsbiologie$/i,
|
1698
|
+
/^-?-?master(-|_| )?genetik(-|_| )?und(-|_| )?entwicklungsbiologie(-|_| )?curriculum$/i
|
1699
|
+
use_uni_vienna_master_genetik_und_entwicklungsbiologie_curriculum
|
1700
|
+
# ===================================================================== #
|
1701
|
+
# === lectures_commandline --master_bioinformatik
|
1702
|
+
# ===================================================================== #
|
1703
|
+
when /^-?-?master(_|-)?bioinformatik$/i,
|
1704
|
+
/^-?-?master(_|-)?bioinformatics$/i
|
1705
|
+
use_uni_vienna_master_bioinformatics_curriculum
|
1706
|
+
# ===================================================================== #
|
1707
|
+
# === lectures_commandline --bachelor_medizinische_informatik
|
1708
|
+
# ===================================================================== #
|
1709
|
+
when /^-?-?bachelor(-|_| )?medizinische(-|_| )?informatik$/i
|
1710
|
+
use_bachelor_medizinische_informatik_curriculum
|
1711
|
+
# ===================================================================== #
|
1712
|
+
# === lectures_commandline --molbio
|
1713
|
+
# ===================================================================== #
|
1714
|
+
when /^-?-?bachelor(-|_| )?molekularbiologie$/,
|
1715
|
+
/^-?-?bachelor(-|_| )?molekulare(-|_| )?biologie$/, # lectures_commandline --bachelor_molekulare_biologie
|
1716
|
+
/^-?-?bachelor(-|_| )?molbio$/,
|
1717
|
+
/^-?-?molbio$/,
|
1718
|
+
/^-?-?mbio$/,
|
1719
|
+
'molekularebiologie'
|
1720
|
+
use_bachelor_molbio_curriculum
|
1721
|
+
# ===================================================================== #
|
1722
|
+
# === lectures_commandline --bachelor-chemie
|
1723
|
+
# ===================================================================== #
|
1724
|
+
when /^-?-?bachelor(-|_| )?chemie?$/,
|
1725
|
+
/^-?-?bachelor(-|_| )?chemie?uni(_|-)?wien$/,
|
1726
|
+
/^-?-?bachelor(-|_| )?chemie(-|_| )?uni(-|_| )?wien$/,
|
1727
|
+
/^-?-?uni(-|_| )?wien(-|_| )?chemie$/,
|
1728
|
+
/^-?-?uniwien(-|_| )?bachelor(-|_| )?chemie$/,
|
1729
|
+
/^-?-?chem(-|_| )?bach$/i, # lcommandline --chembach
|
1730
|
+
'chemie'
|
1731
|
+
use_bachelor_chemie_curriculum
|
1732
|
+
# ===================================================================== #
|
1733
|
+
# === lectures_commandline --show-all-URLs
|
1734
|
+
#
|
1735
|
+
# This can be triggered like so:
|
1736
|
+
#
|
1737
|
+
# studiumsolved --show-all-URLs --tuwienbiotech
|
1738
|
+
#
|
1739
|
+
# ===================================================================== #
|
1740
|
+
when /^-?-?show(_|-)?all(_|-)?URLs$/i
|
1741
|
+
do_show_all_URLs
|
1742
|
+
# ===================================================================== #
|
1743
|
+
# === lectures_commandline --bachelor_ökologie_curriculum
|
1744
|
+
# ===================================================================== #
|
1745
|
+
when /^-?-?bachelor(_|-)?ökologie(_|-)?curriculum$/i,
|
1746
|
+
/^-?-?bachelor(_|-)?ecology(_|-)?curriculum/i,
|
1747
|
+
'ökologie'
|
1748
|
+
use_bachelor_ökologie_curriculum
|
1749
|
+
# ===================================================================== #
|
1750
|
+
# === lectures_commandline --molbio2
|
1751
|
+
# ===================================================================== #
|
1752
|
+
when /^-?-?master(-|_| )?molekularbiologie$/,
|
1753
|
+
/^-?-?master(-|_| )?molekulare(-|_| )?biologie/i,
|
1754
|
+
/^-?-?master(-|_| )?molbio$/,
|
1755
|
+
/^-?-?molbio2$/,
|
1756
|
+
/^-?-?mbio2$/,
|
1757
|
+
'mmolbio'
|
1758
|
+
use_master_molbio_curriculum
|
1759
|
+
# ===================================================================== #
|
1760
|
+
# === lectures_commandline --master_immunobiologie
|
1761
|
+
# ===================================================================== #
|
1762
|
+
when /^-?-?master(-|_| )?immunobiologie$/i,
|
1763
|
+
/^-?-?master(-|_| )?immunobiology$/i,
|
1764
|
+
/^-?-?master(-|_| )?immunobio$/i,
|
1765
|
+
/^-?-?master(-|_| )?immunbiology$/i,
|
1766
|
+
/^-?-?master(-|_| )?immuno$/i,
|
1767
|
+
/^-?-?immunbio$/i
|
1768
|
+
use_master_immunobiology_curriculum
|
1769
|
+
# ===================================================================== #
|
1770
|
+
# === lectures_commandline --biologie_basisblock
|
1771
|
+
# ===================================================================== #
|
1772
|
+
when /^-?-?uniwien(_|-)?biologie(_|-)?basisblock$/i,
|
1773
|
+
/^-?-?bachelor(_|-)?biologie(_|-)?basisblock$/i,
|
1774
|
+
/^-?-?bachelor(_|-)?biologe(_|-)?basisblock$/i,
|
1775
|
+
/^-?-?biologie(_|-)?basisblock$/i,
|
1776
|
+
/^-?-?bachelor(_|-)?biologie/i,
|
1777
|
+
/^-?-?biologie(_|-)?base$/i,
|
1778
|
+
/^-?-?biologie(_|-)?1$/i,
|
1779
|
+
'biologiebasisblock',
|
1780
|
+
'biologie',
|
1781
|
+
'uniwienbiologie'
|
1782
|
+
use_bachelor_biologie_basisblock_curriculum
|
1783
|
+
# ===================================================================== #
|
1784
|
+
# === lectures_commandline --genetic
|
1785
|
+
# ===================================================================== #
|
1786
|
+
when /^-?-?bachelor(-|_| )?genetik$/,
|
1787
|
+
/^-?-?bachelor(-|_| )?genetics$/,
|
1788
|
+
/^-?-?bachelor(-|_| )?mikrobiologie(-|_| )?und(-|_| )?genetik$/,
|
1789
|
+
/^-?-?geneti(c|k)$/,
|
1790
|
+
/^-?-?genetics$/,
|
1791
|
+
'mikrobiologie'
|
1792
|
+
use_bachelor_genetik_curriculum
|
1793
|
+
# ===================================================================== #
|
1794
|
+
# === curriculum bachelor_master_lmbt_curriculum
|
1795
|
+
# ===================================================================== #
|
1796
|
+
when /^-?-?lmbt(-|_| )?complete/i,
|
1797
|
+
/^-?-?bachelor(-|_| )?master(-|_| )?lmbt(-|_| )?curriculum$/i
|
1798
|
+
use_master_lmbt_curriculum
|
1799
|
+
prepend_this_to_dataset(:bachelor_lmbt_curriculum)
|
1800
|
+
# ===================================================================== #
|
1801
|
+
# === lectures_commandline --bachelor_master_tu_wien
|
1802
|
+
# ===================================================================== #
|
1803
|
+
when /^-?-?bachelor(-|_| )?master(-|_| )?tu(-|_| )?wien$/i,
|
1804
|
+
/bachelor(-|_| )?master(-|_| )?individuelles(-|_| )?studium(-|_| )?an(-|_| )?der(-|_| )?tu(-|_| )?wien$/i
|
1805
|
+
use_bachelor_master_tu_wien_curriculum
|
1806
|
+
# ===================================================================== #
|
1807
|
+
# === lectures_commandline --bachelor_botanik
|
1808
|
+
# ===================================================================== #
|
1809
|
+
when /^-?-?bachelor(-|_| )?botanik(-|_| )?curriculum$/i,
|
1810
|
+
/^-?-?bachelor(-|_| )?botanik$/i,
|
1811
|
+
/^botanik$/,
|
1812
|
+
'botany'
|
1813
|
+
use_bachelor_botanik_curriculum
|
1814
|
+
# ===================================================================== #
|
1815
|
+
# === lectures_commandline --bachelor-boku-ubrm
|
1816
|
+
# ===================================================================== #
|
1817
|
+
when /^-?-?bachelor(-|_| )?boku(-|_| )?ubrm$/i,
|
1818
|
+
/^-?-?boku(-|_| )?ubrm$/i,
|
1819
|
+
/^-?-?ubrm$/i
|
1820
|
+
use_bachelor_ubrm_curriculum
|
1821
|
+
# ===================================================================== #
|
1822
|
+
# === curriculum --master_immunobiologie --do-not-show-upcoming-exams
|
1823
|
+
# ===================================================================== #
|
1824
|
+
when /-?-?do-?not-?show-?upcoming-?exams/,
|
1825
|
+
/-?-?do-?not-?show-?next-?exams/,
|
1826
|
+
/-?-?no-?next-?exams/
|
1827
|
+
do_not_show_the_next_exams
|
1828
|
+
# ===================================================================== #
|
1829
|
+
# === curriculum --files
|
1830
|
+
# ===================================================================== #
|
1831
|
+
when /-?-?files?\??/,
|
1832
|
+
/-?-?fshow(_|-)?important(_|-)?files/
|
1833
|
+
show_important_files
|
1834
|
+
exit
|
1835
|
+
# ===================================================================== #
|
1836
|
+
# === curriculum --help
|
1837
|
+
# ===================================================================== #
|
1838
|
+
when /^-?-?help$/
|
1839
|
+
show_help
|
1840
|
+
exit
|
1841
|
+
# ===================================================================== #
|
1842
|
+
# === lectures_commandline --available-curricula
|
1843
|
+
# ===================================================================== #
|
1844
|
+
when /-?-?available-?curricula/,
|
1845
|
+
/-?-?show-?available/
|
1846
|
+
show_available_curricula
|
1847
|
+
exit
|
1848
|
+
else # else tag
|
1849
|
+
opne "Unknown input `#{sfancy(i)}` "\
|
1850
|
+
"(in the method #{__method__}())"
|
1851
|
+
exit # We will exit since as of April 2018; less confusing to do so.
|
1852
|
+
end
|
1853
|
+
end
|
1854
|
+
end; alias use_this_curriculum= menu # === use_this_curriculum=
|
1855
|
+
|
1856
|
+
# ========================================================================= #
|
1857
|
+
# === set_commandline_arguments
|
1858
|
+
# ========================================================================= #
|
1859
|
+
def set_commandline_arguments(i)
|
1860
|
+
# ======================================================================= #
|
1861
|
+
# We will handle empty Arrays a bit differently if we are on
|
1862
|
+
# a roebe-system.
|
1863
|
+
# ======================================================================= #
|
1864
|
+
if i.is_a?(Array) and i.empty?
|
1865
|
+
i << :bachelor_vektorx # Set a default value here.
|
1866
|
+
end
|
1867
|
+
@commandline_arguments = i
|
1868
|
+
end
|
1869
|
+
|
1870
|
+
# ========================================================================= #
|
1871
|
+
# === set_dataset
|
1872
|
+
# ========================================================================= #
|
1873
|
+
def set_dataset(i)
|
1874
|
+
@dataset = i
|
1875
|
+
end; alias set_all_lectures set_dataset # === set_all_lectures
|
1876
|
+
|
1877
|
+
# ========================================================================= #
|
1878
|
+
# === return_how_many_ects_points_this_curriculum_has_in_total
|
1879
|
+
# ========================================================================= #
|
1880
|
+
def return_how_many_ects_points_this_curriculum_has_in_total(
|
1881
|
+
use_colours = true
|
1882
|
+
)
|
1883
|
+
case use_colours
|
1884
|
+
when :no_colours
|
1885
|
+
use_colours = false
|
1886
|
+
end
|
1887
|
+
n_ects_points = @this_curriculum_has_n_ects_points_in_total
|
1888
|
+
# ======================================================================= #
|
1889
|
+
# Use colours, if issued to do so. On the commandline, this will
|
1890
|
+
# be the tomato colour.
|
1891
|
+
# ======================================================================= #
|
1892
|
+
if use_colours
|
1893
|
+
n_ects_points = tomato(n_ects_points)
|
1894
|
+
else
|
1895
|
+
n_ects_points = "<b>#{n_ects_points}</b>" # In this case we will assume www-use.
|
1896
|
+
end
|
1897
|
+
# ======================================================================= #
|
1898
|
+
# Next, return the Strings that informs the user how many ECTS points
|
1899
|
+
# the given curriculm has, in total. Since as of November 2019, we
|
1900
|
+
# will also inform the user how many of these ECTS require a
|
1901
|
+
# continuous mandatory assessment ("prüfungsimmanent").
|
1902
|
+
# ======================================================================= #
|
1903
|
+
n_ects_prüfungsimmanent = 0
|
1904
|
+
@dataset.each {|line|
|
1905
|
+
# ===================================================================== #
|
1906
|
+
# A line may look like this:
|
1907
|
+
#
|
1908
|
+
# 182.711 Betriebssysteme # 2.0 ECTS, VO
|
1909
|
+
#
|
1910
|
+
# ===================================================================== #
|
1911
|
+
name = line.dup
|
1912
|
+
if name.include? '#'
|
1913
|
+
name = name[0 .. (name.index('#') - 1)]
|
1914
|
+
name.strip!
|
1915
|
+
# =================================================================== #
|
1916
|
+
# Must still squeeze a bit:
|
1917
|
+
# =================================================================== #
|
1918
|
+
name.squeeze!(' ')
|
1919
|
+
if @lecture_dataset.has_key? name
|
1920
|
+
pointer = @lecture_dataset[name]
|
1921
|
+
n_ects = pointer[:ects].to_f
|
1922
|
+
type = pointer[:type]
|
1923
|
+
if is_prüfungsimmanent?(type)
|
1924
|
+
n_ects_prüfungsimmanent += n_ects
|
1925
|
+
end
|
1926
|
+
end
|
1927
|
+
end
|
1928
|
+
}
|
1929
|
+
n_percent_prüfungsimmanent = ((
|
1930
|
+
n_ects_prüfungsimmanent.to_f * 100.0
|
1931
|
+
) / @this_curriculum_has_n_ects_points_in_total.to_f).round(1)
|
1932
|
+
colourized_n_ects_prüfungsimmanent =
|
1933
|
+
skyblue(n_percent_prüfungsimmanent.to_s.dup)
|
1934
|
+
"This curriculum has #{n_ects_points} ECTS points "\
|
1935
|
+
"in total, of which "\
|
1936
|
+
"#{colourized_n_ects_prüfungsimmanent} ECTS "\
|
1937
|
+
"("+n_percent_prüfungsimmanent.to_s+"%)\n"\
|
1938
|
+
"require continuous mandatory assessment "\
|
1939
|
+
"(#{orangered('prüfungsimmanent')})."
|
1940
|
+
end
|
1941
|
+
|
1942
|
+
# ========================================================================= #
|
1943
|
+
# === read_from_these_files?
|
1944
|
+
# ========================================================================= #
|
1945
|
+
def read_from_these_files?
|
1946
|
+
@read_from_these_files # This also means to keep track of the position of the curriculum-file.
|
1947
|
+
end; alias loaded_from_which_file? read_from_these_files? # === loaded_from_which_file?
|
1948
|
+
alias curriculum_file? read_from_these_files? # === curriculum_file?
|
1949
|
+
alias curriculum_file_location? read_from_these_files? # === curriculum_file_location?
|
1950
|
+
alias curriculum_file_location read_from_these_files? # === curriculum_file_location
|
1951
|
+
alias curriculum? read_from_these_files? # === curriculum?
|
1952
|
+
|
1953
|
+
# ========================================================================= #
|
1954
|
+
# === dataset?
|
1955
|
+
# ========================================================================= #
|
1956
|
+
def dataset?
|
1957
|
+
@dataset
|
1958
|
+
end; alias dataset_holding_all_lectures dataset? # === dataset_holding_all_lectures
|
1959
|
+
alias all_lectures? dataset? # === all_lectures?
|
1960
|
+
alias lectures? dataset? # === lectures?
|
1961
|
+
|
1962
|
+
# ========================================================================= #
|
1963
|
+
# === read_in_main_dataset_from_the_existing_files
|
1964
|
+
#
|
1965
|
+
# This method will read in from an Array, which is usually stored in
|
1966
|
+
# the instance variables @read_from_these_files.
|
1967
|
+
#
|
1968
|
+
# Input to this method can be like this:
|
1969
|
+
#
|
1970
|
+
# ["/Programs/Ruby/2.5.1/lib/ruby/site_ruby/2.5.0/studium/yaml/curricula/master_bioinformatik_066875.yml"]
|
1971
|
+
#
|
1972
|
+
# ========================================================================= #
|
1973
|
+
def read_in_main_dataset_from_the_existing_files(
|
1974
|
+
i = @read_from_these_files
|
1975
|
+
)
|
1976
|
+
if i
|
1977
|
+
i.each {|this_file|
|
1978
|
+
# =================================================================== #
|
1979
|
+
# The next method will read into the variable @dataset.
|
1980
|
+
# =================================================================== #
|
1981
|
+
if File.exist? this_file.to_s
|
1982
|
+
read_in_dataset_from_this_file(this_file) # Delegate to this method.
|
1983
|
+
else
|
1984
|
+
opne "Can not read from non-existing file "\
|
1985
|
+
"`#{sfile(this_file)}`."
|
1986
|
+
opne 'The original input to the method '+
|
1987
|
+
sfancy(__method__.to_s)+' was '+
|
1988
|
+
sfancy(i)+' (class '+i.to_s+')'
|
1989
|
+
opne 'The '+orange('caller-stack')+' will be shown next:'
|
1990
|
+
e
|
1991
|
+
pp caller()
|
1992
|
+
e
|
1993
|
+
exit
|
1994
|
+
end
|
1995
|
+
}
|
1996
|
+
end
|
1997
|
+
end
|
1998
|
+
|
1999
|
+
# ========================================================================= #
|
2000
|
+
# === consider_generating_a_spreadsheet
|
2001
|
+
# ========================================================================= #
|
2002
|
+
def consider_generating_a_spreadsheet(
|
2003
|
+
i = @title
|
2004
|
+
)
|
2005
|
+
require 'studium/utility_scripts/generate_spreadsheet/generate_spreadsheet.rb'
|
2006
|
+
Studium::GenerateSpreadsheet.new(i)
|
2007
|
+
end
|
2008
|
+
|
2009
|
+
# ========================================================================= #
|
2010
|
+
# === consider_generating_a_graphviz_image_displaying_the_modules
|
2011
|
+
# ========================================================================= #
|
2012
|
+
def consider_generating_a_graphviz_image_displaying_the_modules(
|
2013
|
+
use_this_dataset
|
2014
|
+
)
|
2015
|
+
require 'image_paradise/graphviz/generate_graphviz_image.rb'
|
2016
|
+
copy = use_this_dataset.dup
|
2017
|
+
copy.map! {|entry|
|
2018
|
+
if entry.include? '#'
|
2019
|
+
entry = entry[0 .. ( entry.index('#') - 1 )]
|
2020
|
+
end
|
2021
|
+
entry.strip
|
2022
|
+
}
|
2023
|
+
copy = turn_this_array_into_the_full_dataset(
|
2024
|
+
copy.flatten, @lecture_dataset
|
2025
|
+
)
|
2026
|
+
# ======================================================================= #
|
2027
|
+
# Next, we will work on this modified dataset.
|
2028
|
+
# ======================================================================= #
|
2029
|
+
hash_containing_the_module_dependencies = {}
|
2030
|
+
copy.each_pair {|name_of_the_lecture, inner_hash|
|
2031
|
+
if inner_hash
|
2032
|
+
individual_curricula = inner_hash[:individual_curricula]
|
2033
|
+
if individual_curricula
|
2034
|
+
selection = individual_curricula.select {|most_inner_hash|
|
2035
|
+
most_inner_hash[:name_of_the_curriculum].include? @title
|
2036
|
+
}.first
|
2037
|
+
if selection
|
2038
|
+
individual_curriculum_module = selection[:individual_curriculum_module]
|
2039
|
+
if individual_curriculum_module
|
2040
|
+
individual_curriculum_module = individual_curriculum_module.first
|
2041
|
+
end
|
2042
|
+
individual_curriculum_depends_on_these_modules = selection[:individual_curriculum_depends_on_these_modules]
|
2043
|
+
hash_containing_the_module_dependencies[individual_curriculum_module] =
|
2044
|
+
individual_curriculum_depends_on_these_modules
|
2045
|
+
end
|
2046
|
+
end
|
2047
|
+
end
|
2048
|
+
}
|
2049
|
+
# ======================================================================= #
|
2050
|
+
# Next pass this Hash into class GenerateGraphvizImage.
|
2051
|
+
# ======================================================================= #
|
2052
|
+
ImageParadise::GenerateGraphvizImage.new(
|
2053
|
+
hash_containing_the_module_dependencies
|
2054
|
+
) { :use_bold_font_and_german }
|
2055
|
+
end
|
2056
|
+
|
2057
|
+
# ========================================================================= #
|
2058
|
+
# === return_how_many_ects_points_have_been_passed_already
|
2059
|
+
# ========================================================================= #
|
2060
|
+
def return_how_many_ects_points_have_been_passed_already(
|
2061
|
+
use_for = @mode
|
2062
|
+
)
|
2063
|
+
n_percent = (
|
2064
|
+
(@n_ects_were_passed_so_far.to_f * 100) / n_ects_points_in_total?
|
2065
|
+
).round(2)
|
2066
|
+
# ======================================================================= #
|
2067
|
+
# The next variable is not colourized by default, so that we can use
|
2068
|
+
# it for the :use_for_html entry point that will come next. A similar
|
2069
|
+
# reason is valid for the variable called `second_part`.
|
2070
|
+
# ======================================================================= #
|
2071
|
+
colourized_n_ECTS_points_were_passed = @n_ects_were_passed_so_far.to_s
|
2072
|
+
second_part = " <b>#{@title}</b>."
|
2073
|
+
case use_for
|
2074
|
+
when :use_for_html # (html tag, www tag)
|
2075
|
+
first_part = "In total we have passed <b>#{colourized_n_ECTS_points_were_passed} ECTS "\
|
2076
|
+
"points</b> (<b>#{n_percent.to_s+'%'}</b>) so far in the"
|
2077
|
+
when :commandline, :default # This is the default.
|
2078
|
+
colourized_n_ECTS_points_were_passed = plum(
|
2079
|
+
colourized_n_ECTS_points_were_passed
|
2080
|
+
)
|
2081
|
+
first_part = "In total we have passed #{colourized_n_ECTS_points_were_passed} ECTS "\
|
2082
|
+
"points (#{orangered(n_percent.to_s+'%')}) so far in the"
|
2083
|
+
second_part = " #{sfancy(@title)}."
|
2084
|
+
end
|
2085
|
+
[ first_part, second_part ]
|
2086
|
+
end
|
2087
|
+
|
2088
|
+
# ========================================================================= #
|
2089
|
+
# === report_how_many_ects_points_have_been_passed_already
|
2090
|
+
# ========================================================================= #
|
2091
|
+
def report_how_many_ects_points_have_been_passed_already
|
2092
|
+
array = return_how_many_ects_points_have_been_passed_already
|
2093
|
+
e array.first
|
2094
|
+
e
|
2095
|
+
e array.last
|
2096
|
+
e
|
2097
|
+
end
|
2098
|
+
|
2099
|
+
# ========================================================================= #
|
2100
|
+
# === report_how_many_exams_have_been_passed_already
|
2101
|
+
#
|
2102
|
+
# To invoke this method try:
|
2103
|
+
#
|
2104
|
+
# emo --agrarwissenschaften
|
2105
|
+
#
|
2106
|
+
# ========================================================================= #
|
2107
|
+
def report_how_many_exams_have_been_passed_already
|
2108
|
+
n_lectures_are_in_this_curriculum = n_lectures_in_this_curriculum?
|
2109
|
+
opne sfancy(@n_lectures_are_already_solved.to_s)+' lectures have '\
|
2110
|
+
'already been passed out'
|
2111
|
+
opne 'of a total '+
|
2112
|
+
slateblue(n_lectures_are_in_this_curriculum.to_s)+', in '\
|
2113
|
+
'the curriculum '+simp(title?.to_s)+'.'
|
2114
|
+
end
|
2115
|
+
|
2116
|
+
# ========================================================================= #
|
2117
|
+
# === do_not_report_anything
|
2118
|
+
# ========================================================================= #
|
2119
|
+
def do_not_report_anything
|
2120
|
+
@do_report = false
|
2121
|
+
end; alias do_not_report do_not_report_anything # === do_not_report
|
2122
|
+
|
2123
|
+
# ========================================================================= #
|
2124
|
+
# === n_lectures_in_this_curriculum?
|
2125
|
+
# ========================================================================= #
|
2126
|
+
def n_lectures_in_this_curriculum?
|
2127
|
+
@dataset.size
|
2128
|
+
end
|
2129
|
+
|
2130
|
+
# ========================================================================= #
|
2131
|
+
# === read_in_dataset_from_this_file
|
2132
|
+
#
|
2133
|
+
# Input to this method should be a String, not an Array.
|
2134
|
+
# ========================================================================= #
|
2135
|
+
def read_in_dataset_from_this_file(i)
|
2136
|
+
@dataset << obtain_sanitized_dataset_from(i)
|
2137
|
+
@dataset.flatten!
|
2138
|
+
check_for_title_entry_in_the_file(i)
|
2139
|
+
end
|
2140
|
+
|
2141
|
+
# ========================================================================= #
|
2142
|
+
# === report_the_average_grade
|
2143
|
+
# ========================================================================= #
|
2144
|
+
def report_the_average_grade
|
2145
|
+
if @do_report
|
2146
|
+
average_grade = return_the_average_grade
|
2147
|
+
e "The #{gold('average grade')} is: #{sfancy(average_grade)}"
|
2148
|
+
e
|
2149
|
+
end
|
2150
|
+
end
|
2151
|
+
|
2152
|
+
# ========================================================================= #
|
2153
|
+
# === check_for_title_entry_in_the_file
|
2154
|
+
#
|
2155
|
+
# You can put a line within a curriculum such as:
|
2156
|
+
#
|
2157
|
+
# @title Biologie Basisblock
|
2158
|
+
#
|
2159
|
+
# The method will check for this. However had, you can also avoid using
|
2160
|
+
# such a title, by having a header section, as a comment, where the
|
2161
|
+
# second line should contain the title of the lecture.
|
2162
|
+
#
|
2163
|
+
# The latter is the default (and recommended) mode.
|
2164
|
+
# ========================================================================= #
|
2165
|
+
def check_for_title_entry_in_the_file(
|
2166
|
+
this_file = dataset?
|
2167
|
+
)
|
2168
|
+
temporary_dataset = Studium.read_dataset_from_a_curriculum_file(
|
2169
|
+
this_file,
|
2170
|
+
:retain_comments
|
2171
|
+
)
|
2172
|
+
# ======================================================================= #
|
2173
|
+
# If the second line in the curriculum-file starts with '# === #'
|
2174
|
+
#
|
2175
|
+
# This is recommended for all registered curricula.
|
2176
|
+
# ======================================================================= #
|
2177
|
+
if temporary_dataset[1].start_with?('# === ')
|
2178
|
+
use_this_title = temporary_dataset[1]
|
2179
|
+
set_title(use_this_title)
|
2180
|
+
# ======================================================================= #
|
2181
|
+
# else check for a @title entry
|
2182
|
+
# ======================================================================= #
|
2183
|
+
elsif this_file.any? {|line|
|
2184
|
+
line.start_with? '@title'
|
2185
|
+
}
|
2186
|
+
set_title(
|
2187
|
+
dataset.select {|line| line.start_with? '@title ' }
|
2188
|
+
)
|
2189
|
+
# ===================================================================== #
|
2190
|
+
# In this case, grab the title, and remove that line.
|
2191
|
+
# So, we will reject all entries that include '@title '.
|
2192
|
+
# ===================================================================== #
|
2193
|
+
dataset.reject! {|line| line.start_with? '@title '}
|
2194
|
+
dataset.compact!
|
2195
|
+
set_dataset(dataset)
|
2196
|
+
end
|
2197
|
+
end
|
2198
|
+
|
2199
|
+
# ========================================================================= #
|
2200
|
+
# === no_html_page7
|
2201
|
+
# ========================================================================= #
|
2202
|
+
def no_html_page
|
2203
|
+
@generate_html_file = false
|
2204
|
+
end; alias no_html no_html_page # === no_html
|
2205
|
+
|
2206
|
+
# ========================================================================= #
|
2207
|
+
# === show_loaded_from_which_file?
|
2208
|
+
# ========================================================================= #
|
2209
|
+
def show_loaded_from_which_file?
|
2210
|
+
@show_loaded_from_which_file
|
2211
|
+
end
|
2212
|
+
|
2213
|
+
# ========================================================================= #
|
2214
|
+
# === report_how_many_ects_points_are_in_this_curriculum
|
2215
|
+
# ========================================================================= #
|
2216
|
+
def report_how_many_ects_points_are_in_this_curriculum
|
2217
|
+
if @do_report
|
2218
|
+
e return_how_many_ects_points_this_curriculum_has_in_total
|
2219
|
+
e
|
2220
|
+
end
|
2221
|
+
end
|
2222
|
+
|
2223
|
+
# ========================================================================= #
|
2224
|
+
# === do_show_all_URLs
|
2225
|
+
# ========================================================================= #
|
2226
|
+
def do_show_all_URLs
|
2227
|
+
@show_all_URLs = true
|
2228
|
+
end
|
2229
|
+
|
2230
|
+
# ========================================================================= #
|
2231
|
+
# === report_how_many_lectures_are_in_this_curriculum_and_how_many_of_them_are_already_solved
|
2232
|
+
# ========================================================================= #
|
2233
|
+
def report_how_many_lectures_are_in_this_curriculum_and_how_many_of_them_are_already_solved
|
2234
|
+
array = return_how_many_lectures_are_in_this_curriculum_and_how_many_of_them_are_already_solved
|
2235
|
+
if @do_report
|
2236
|
+
e
|
2237
|
+
e array[0]
|
2238
|
+
e array[1]
|
2239
|
+
e
|
2240
|
+
end
|
2241
|
+
end
|
2242
|
+
|
2243
|
+
# ========================================================================= #
|
2244
|
+
# === lecture_dataset?
|
2245
|
+
# ========================================================================= #
|
2246
|
+
def lecture_dataset?
|
2247
|
+
@lecture_dataset
|
2248
|
+
end; alias main_dataset? lecture_dataset? # === main_dataset?
|
2249
|
+
|
2250
|
+
# ========================================================================= #
|
2251
|
+
# === n_lectures_are_already_solved?
|
2252
|
+
# ========================================================================= #
|
2253
|
+
def n_lectures_are_already_solved?
|
2254
|
+
@n_lectures_are_already_solved
|
2255
|
+
end; alias n_lectures_completed? n_lectures_are_already_solved? # === n_lectures_completed?
|
2256
|
+
|
2257
|
+
# ========================================================================= #
|
2258
|
+
# === n_total_lectures?
|
2259
|
+
# ========================================================================= #
|
2260
|
+
def n_total_lectures?
|
2261
|
+
@dataset.size
|
2262
|
+
end
|
2263
|
+
|
2264
|
+
# ========================================================================= #
|
2265
|
+
# === is_this_lecture_a_practical_course?
|
2266
|
+
# ========================================================================= #
|
2267
|
+
def is_this_lecture_a_practical_course?(lecture_type)
|
2268
|
+
ARRAY_LECTURE_TYPES_THAT_ARE_MANDATORY_CONTINUOUS_ASSESSMENT.include? lecture_type
|
2269
|
+
end
|
2270
|
+
|
2271
|
+
# ========================================================================= #
|
2272
|
+
# === type_of_the_curriculum?
|
2273
|
+
# ========================================================================= #
|
2274
|
+
def type_of_the_curriculum?
|
2275
|
+
@type_of_the_curriculum
|
2276
|
+
end; alias curriculum_type? type_of_the_curriculum? # === curriculum_type?
|
2277
|
+
|
2278
|
+
# ========================================================================= #
|
2279
|
+
# === exclude_title_entries_from_the_main_dataset
|
2280
|
+
# ========================================================================= #
|
2281
|
+
def exclude_title_entries_from_the_main_dataset
|
2282
|
+
@dataset.reject! {|line| line.start_with? '@title ' }
|
2283
|
+
end
|
2284
|
+
|
2285
|
+
# ========================================================================= #
|
2286
|
+
# === n_ects_were_passed_in_this_curriculum?
|
2287
|
+
# ========================================================================= #
|
2288
|
+
def n_ects_were_passed_in_this_curriculum?
|
2289
|
+
@n_ects_were_passed_so_far
|
2290
|
+
end; alias n_ects_were_passed_in_this_curriculum n_ects_were_passed_in_this_curriculum? # === n_ects_were_passed_in_this_curriculum
|
2291
|
+
alias n_ects_were_passed_so_far n_ects_were_passed_in_this_curriculum? # === n_ects_were_passed_so_far
|
2292
|
+
|
2293
|
+
# ========================================================================= #
|
2294
|
+
# === n_ects_points_in_total?
|
2295
|
+
# ========================================================================= #
|
2296
|
+
def n_ects_points_in_total?
|
2297
|
+
@this_curriculum_has_n_ects_points_in_total
|
2298
|
+
end; alias total_ects_points? n_ects_points_in_total? # === total_ects_points?
|
2299
|
+
|
2300
|
+
# ========================================================================= #
|
2301
|
+
# === prepend_this_to_dataset
|
2302
|
+
#
|
2303
|
+
# An Array can be given to this method. If a symbol is given, such as
|
2304
|
+
# :bachelor_lbt, then that symbol will be treated in a special way as
|
2305
|
+
# far as this method is concerned.
|
2306
|
+
# ========================================================================= #
|
2307
|
+
def prepend_this_to_dataset(
|
2308
|
+
i = :bachelor_biologie_basisblock_curriculum
|
2309
|
+
)
|
2310
|
+
original_input = i.dup
|
2311
|
+
if i.is_a? Symbol
|
2312
|
+
# ===================================================================== #
|
2313
|
+
# Here we will handle input such as :bachelor_lbt.
|
2314
|
+
# ===================================================================== #
|
2315
|
+
i = return_curriculum_file_based_on_this_input(i)
|
2316
|
+
end
|
2317
|
+
if i.is_a? Array
|
2318
|
+
i.flatten.each {|entry| prepend_this_to_dataset(entry) }
|
2319
|
+
else
|
2320
|
+
if i.nil?
|
2321
|
+
e 'A nil value was encountered, onto the method called '+
|
2322
|
+
steelblue('prepend_this_dataset()')+'.'
|
2323
|
+
e 'The original input was: '+
|
2324
|
+
royalblue(original_input.to_s)
|
2325
|
+
elsif File.exist? i # Read in existing files.
|
2326
|
+
array = obtain_sanitized_dataset_from(i)
|
2327
|
+
@dataset = array+@dataset
|
2328
|
+
@dataset.flatten!
|
2329
|
+
exclude_title_entries_from_the_main_dataset
|
2330
|
+
# ===================================================================== #
|
2331
|
+
# The next check is for ad-hoc addition of lectures, such as via:
|
2332
|
+
# ['892100 Physik (KTWW+HNT)']
|
2333
|
+
# ===================================================================== #
|
2334
|
+
elsif is_this_a_registered_lecture? i
|
2335
|
+
@dataset << i
|
2336
|
+
else
|
2337
|
+
opne "No file exists at #{sfile(i)}."
|
2338
|
+
end
|
2339
|
+
end
|
2340
|
+
end
|
2341
|
+
|
2342
|
+
# ========================================================================= #
|
2343
|
+
# === add_to_the_dataset_without_any_further_checks
|
2344
|
+
# ========================================================================= #
|
2345
|
+
def add_to_the_dataset_without_any_further_checks(i)
|
2346
|
+
@dataset << i
|
2347
|
+
@dataset.flatten!
|
2348
|
+
end
|
2349
|
+
|
2350
|
+
# ========================================================================= #
|
2351
|
+
# === obtain_sanitized_dataset_from
|
2352
|
+
#
|
2353
|
+
# This method combines two other methods - loading the dataset that
|
2354
|
+
# belongs to a Curriculum; and sorting that dataset.
|
2355
|
+
# ========================================================================= #
|
2356
|
+
def obtain_sanitized_dataset_from(i)
|
2357
|
+
# ======================================================================= #
|
2358
|
+
# Keep in mind that the following method also allows for optional
|
2359
|
+
# arguments such as :remove_comments_and_title
|
2360
|
+
#
|
2361
|
+
# We do not need to do this for this file, though, as this file may
|
2362
|
+
# probably make use of all the information it can get.
|
2363
|
+
# ======================================================================= #
|
2364
|
+
dataset = Studium.read_dataset_from_a_curriculum_file(i).map(&:chomp)
|
2365
|
+
# ======================================================================= #
|
2366
|
+
# Next, we must check for duplicate entries. For now we will work on
|
2367
|
+
# the dataset obtained above ^^^ but if we need a more accurate
|
2368
|
+
# approach, we should work on the name + LVA-ID of the lecture at
|
2369
|
+
# hand instead.
|
2370
|
+
# ======================================================================= #
|
2371
|
+
unless dataset == dataset.uniq
|
2372
|
+
e 'We have found at the least one duplicate entry. This will be '\
|
2373
|
+
'shown next:'
|
2374
|
+
e
|
2375
|
+
these_are_the_duplicates = {}
|
2376
|
+
these_are_the_duplicates.default = 0
|
2377
|
+
dataset.each {|this_entry|
|
2378
|
+
these_are_the_duplicates[this_entry] += 1
|
2379
|
+
}
|
2380
|
+
these_are_the_duplicates.select {|key, value| value > 1 }.each {|duplicate, n_times|
|
2381
|
+
e sfancy(" #{duplicate}")
|
2382
|
+
}
|
2383
|
+
e
|
2384
|
+
e 'Please correct these entries before we can continue.'
|
2385
|
+
exit
|
2386
|
+
end
|
2387
|
+
sort_dataset(dataset) if @shall_we_sort_the_dataset
|
2388
|
+
end
|
2389
|
+
|
2390
|
+
# ========================================================================= #
|
2391
|
+
# === clear_old_dataset
|
2392
|
+
# ========================================================================= #
|
2393
|
+
def clear_old_dataset
|
2394
|
+
@dataset = []
|
2395
|
+
end
|
2396
|
+
|
2397
|
+
# ========================================================================= #
|
2398
|
+
# === do_not_show_the_next_exams
|
2399
|
+
#
|
2400
|
+
# Use this method if you do NOT want to show the next exams.
|
2401
|
+
# ========================================================================= #
|
2402
|
+
def do_not_show_the_next_exams
|
2403
|
+
@show_next_exams = false
|
2404
|
+
end
|
2405
|
+
|
2406
|
+
# ========================================================================= #
|
2407
|
+
# === do_not_show_loaded_from_which_file
|
2408
|
+
# ========================================================================= #
|
2409
|
+
def do_not_show_loaded_from_which_file
|
2410
|
+
@show_loaded_from_which_file = false
|
2411
|
+
end
|
2412
|
+
|
2413
|
+
# ========================================================================= #
|
2414
|
+
# === return_proper_logo_for_this_university
|
2415
|
+
# ========================================================================= #
|
2416
|
+
def return_proper_logo_for_this_university(
|
2417
|
+
i
|
2418
|
+
)
|
2419
|
+
Studium.return_proper_university_image(i)
|
2420
|
+
end
|
2421
|
+
|
2422
|
+
# ========================================================================= #
|
2423
|
+
# === is_this_a_registered_lecture?
|
2424
|
+
# ========================================================================= #
|
2425
|
+
def is_this_a_registered_lecture?(i)
|
2426
|
+
@lecture_dataset.has_key?(i.strip)
|
2427
|
+
end
|
2428
|
+
|
2429
|
+
# ========================================================================= #
|
2430
|
+
# === individual_curriculum?
|
2431
|
+
# ========================================================================= #
|
2432
|
+
def individual_curriculum?
|
2433
|
+
@individual_curriculum
|
2434
|
+
end; alias is_it_an_individual_curriculum? individual_curriculum? # === is_it_an_individual_curriculum?
|
2435
|
+
|
2436
|
+
# ========================================================================= #
|
2437
|
+
# === is_not_an_individual_curriculum
|
2438
|
+
# ========================================================================= #
|
2439
|
+
def is_not_an_individual_curriculum
|
2440
|
+
@individual_curriculum = false
|
2441
|
+
end
|
2442
|
+
|
2443
|
+
# ========================================================================= #
|
2444
|
+
# === is_an_individual_curriculum
|
2445
|
+
# ========================================================================= #
|
2446
|
+
def is_an_individual_curriculum
|
2447
|
+
@individual_curriculum = true
|
2448
|
+
end
|
2449
|
+
|
2450
|
+
# ========================================================================= #
|
2451
|
+
# === title?
|
2452
|
+
# ========================================================================= #
|
2453
|
+
def title?
|
2454
|
+
@title
|
2455
|
+
end; alias return_name_of_the_curriculum title? # === return_name_of_the_curriculum
|
2456
|
+
alias name_of_the_curriculum title? # === name_of_the_curriculum
|
2457
|
+
alias name_of_the_curriculum? title? # === name_of_the_curriculum?
|
2458
|
+
|
2459
|
+
# ========================================================================= #
|
2460
|
+
# === uniq_the_dataset
|
2461
|
+
#
|
2462
|
+
# This ad-hoc method will simply eliminate all the duplicates that
|
2463
|
+
# may exist in the main dataset at hand. It is only called from
|
2464
|
+
# within menu() right now (December 2019).
|
2465
|
+
# ========================================================================= #
|
2466
|
+
def uniq_the_dataset
|
2467
|
+
@dataset.uniq!
|
2468
|
+
end
|
2469
|
+
|
2470
|
+
# ========================================================================= #
|
2471
|
+
# === sanitize_the_dataset
|
2472
|
+
# ========================================================================= #
|
2473
|
+
def sanitize_the_dataset
|
2474
|
+
@dataset.map! {|entry|
|
2475
|
+
entry = entry.dup if entry.frozen?
|
2476
|
+
entry.squeeze!(' ')
|
2477
|
+
if entry.include? '#'
|
2478
|
+
entry = entry[0 .. (entry.index('#')-1)]
|
2479
|
+
end
|
2480
|
+
entry.strip!
|
2481
|
+
entry
|
2482
|
+
}
|
2483
|
+
end
|
2484
|
+
|
2485
|
+
# ========================================================================= #
|
2486
|
+
# === sort_dataset
|
2487
|
+
#
|
2488
|
+
# This method will sort the dataset, according to the name of the
|
2489
|
+
# lecture rather than the leading ID number.
|
2490
|
+
# ========================================================================= #
|
2491
|
+
def sort_dataset(
|
2492
|
+
i = @dataset
|
2493
|
+
)
|
2494
|
+
i.sort_by! {|line|
|
2495
|
+
# ===================================================================== #
|
2496
|
+
# The next line will split on ' ' tokens, take all but the first
|
2497
|
+
# entry, rejoin, strip and delete '(' tokens. So essentially we
|
2498
|
+
# will strip away the leading numbers from the line at hand.
|
2499
|
+
# ===================================================================== #
|
2500
|
+
line.split(' ')[1 .. -1].join(' ').strip
|
2501
|
+
}
|
2502
|
+
end
|
2503
|
+
|
2504
|
+
# ========================================================================= #
|
2505
|
+
# === starts_with_a_lecture_id_entry?
|
2506
|
+
# ========================================================================= #
|
2507
|
+
def starts_with_a_lecture_id_entry?(i)
|
2508
|
+
result = false
|
2509
|
+
if i.include? ' '
|
2510
|
+
splitted = i.split(' ')
|
2511
|
+
first_entry = splitted.first
|
2512
|
+
# ===================================================================== #
|
2513
|
+
# See: https://rubular.com/r/EKEk3QuWRQ1s
|
2514
|
+
# ===================================================================== #
|
2515
|
+
if first_entry =~ /^\d+\.?[A-Z]*\d{1,4}$/
|
2516
|
+
result = true
|
2517
|
+
end
|
2518
|
+
end
|
2519
|
+
result
|
2520
|
+
end
|
2521
|
+
|
2522
|
+
# ========================================================================= #
|
2523
|
+
# === return_bachelor_or_master_logo
|
2524
|
+
#
|
2525
|
+
# Here we differ between bachelor-logo and the master-logo.
|
2526
|
+
#
|
2527
|
+
# By default, we will operate on @type_of_the_curriculum, but
|
2528
|
+
# this can be wrong in a mixed bachelor-master curriculum.
|
2529
|
+
# ========================================================================= #
|
2530
|
+
def return_bachelor_or_master_logo(
|
2531
|
+
this_lecture = nil
|
2532
|
+
)
|
2533
|
+
if this_lecture.nil?
|
2534
|
+
case @type_of_the_curriculum
|
2535
|
+
when :bachelor
|
2536
|
+
BACHELOR_IMAGE
|
2537
|
+
when :master
|
2538
|
+
MASTER_IMAGE
|
2539
|
+
end
|
2540
|
+
else
|
2541
|
+
# ===================================================================== #
|
2542
|
+
# Else assume an Array was given.
|
2543
|
+
# ===================================================================== #
|
2544
|
+
if this_lecture.any? {|entry| entry.start_with?('033') }
|
2545
|
+
BACHELOR_IMAGE
|
2546
|
+
else
|
2547
|
+
MASTER_IMAGE
|
2548
|
+
end
|
2549
|
+
end
|
2550
|
+
end
|
2551
|
+
|
2552
|
+
# ========================================================================= #
|
2553
|
+
# === report_title
|
2554
|
+
#
|
2555
|
+
# Use this method to report the title of the Curriculum at hand.
|
2556
|
+
# ========================================================================= #
|
2557
|
+
def report_title(
|
2558
|
+
this_title = @title
|
2559
|
+
)
|
2560
|
+
if this_title
|
2561
|
+
e; e springgreen(this_title); e
|
2562
|
+
else
|
2563
|
+
opne 'No title was set via @title. This is '\
|
2564
|
+
'currently disallowed, so we exit now.'
|
2565
|
+
opne "The file to read from was `"\
|
2566
|
+
"#{sfancy(@read_from_this_file)}`."
|
2567
|
+
exit
|
2568
|
+
end
|
2569
|
+
end; alias display_the_name_of_the_curriculum report_title # === display_the_name_of_the_curriculum
|
2570
|
+
|
2571
|
+
# ========================================================================= #
|
2572
|
+
# === set_title
|
2573
|
+
#
|
2574
|
+
# The title of the Curriculum in question. Should be hardcoded
|
2575
|
+
# in the file.
|
2576
|
+
# ========================================================================= #
|
2577
|
+
def set_title(i)
|
2578
|
+
i = i.first if i.is_a? Array
|
2579
|
+
i = i.dup.delete(N) # Want to work on a String really.
|
2580
|
+
if i.start_with? '# ==='
|
2581
|
+
i.sub!(/^# === /,'')
|
2582
|
+
end
|
2583
|
+
i.sub!(/^@title /,'') if i.include? '@title '
|
2584
|
+
@title = i.strip.chomp
|
2585
|
+
end; alias set_title_of_the_curriculum set_title # === set_title_of_the_curriculum
|
2586
|
+
|
2587
|
+
# ========================================================================= #
|
2588
|
+
# === no_html_and_do_not_report_anything
|
2589
|
+
# ========================================================================= #
|
2590
|
+
def no_html_and_do_not_report_anything
|
2591
|
+
no_html
|
2592
|
+
do_not_report_anything
|
2593
|
+
end
|
2594
|
+
|
2595
|
+
# ========================================================================= #
|
2596
|
+
# === ja_oder_nein
|
2597
|
+
#
|
2598
|
+
# Input "true" will become "Ja" and input "false" will become "Nein".
|
2599
|
+
# ========================================================================= #
|
2600
|
+
def ja_oder_nein(
|
2601
|
+
i = 'nein'
|
2602
|
+
)
|
2603
|
+
Studium.ja_oder_nein(i)
|
2604
|
+
end
|
2605
|
+
|
2606
|
+
# ========================================================================= #
|
2607
|
+
# === opnn
|
2608
|
+
# ========================================================================= #
|
2609
|
+
def opnn(i = namespace?)
|
2610
|
+
if block_given?
|
2611
|
+
super(i) { yield }
|
2612
|
+
else
|
2613
|
+
super(i)
|
2614
|
+
end
|
2615
|
+
end
|
2616
|
+
|
2617
|
+
# ========================================================================= #
|
2618
|
+
# === return_the_average_grade
|
2619
|
+
#
|
2620
|
+
# This method will return the average grade. So for example, if we have
|
2621
|
+
# passed three exams, with a grade of 2, 3 and 4, respectively, then
|
2622
|
+
# the average grade will be 2 + 3 + 4 = 9 / 3 → 3.
|
2623
|
+
# ========================================================================= #
|
2624
|
+
def return_the_average_grade
|
2625
|
+
# ======================================================================= #
|
2626
|
+
# We must work on a copy, because some grades, such as '+', are not
|
2627
|
+
# useful for calculating the average grade - hence we will have to
|
2628
|
+
# weed these entries out, for the purpose of calculating the
|
2629
|
+
# average grade through this method here.
|
2630
|
+
# ======================================================================= #
|
2631
|
+
array_storing_the_grades = @array_storing_the_grades.dup
|
2632
|
+
array_storing_the_grades.reject! {|grade|
|
2633
|
+
grade == '+' or grade == 'E' # Remove '+' and 'E' exam results.
|
2634
|
+
}
|
2635
|
+
average_grade = (
|
2636
|
+
array_storing_the_grades.sum.to_f / array_storing_the_grades.size
|
2637
|
+
).round(2)
|
2638
|
+
return average_grade
|
2639
|
+
end
|
2640
|
+
|
2641
|
+
# ========================================================================= #
|
2642
|
+
# === report_the_university_attribution
|
2643
|
+
#
|
2644
|
+
# This method will report the university-attribution of that curriculum.
|
2645
|
+
# ========================================================================= #
|
2646
|
+
def report_the_university_attribution
|
2647
|
+
require 'studium/toplevel_methods/toplevel_methods.rb'
|
2648
|
+
# ======================================================================= #
|
2649
|
+
# We must build up our main Hash next. That Hash should look e. g.
|
2650
|
+
# like this:
|
2651
|
+
#
|
2652
|
+
# {
|
2653
|
+
# "TU Wien"=>115.5,
|
2654
|
+
# "Uni Wien"=>30.0,
|
2655
|
+
# "BOKU Wien"=>26.0,
|
2656
|
+
# "Vetmed Wien"=>8.5
|
2657
|
+
# }
|
2658
|
+
#
|
2659
|
+
# ======================================================================= #
|
2660
|
+
sanitize_the_dataset
|
2661
|
+
hash = {}
|
2662
|
+
@dataset.each {|entry|
|
2663
|
+
pointer = @lecture_dataset[entry]
|
2664
|
+
if pointer
|
2665
|
+
n_ects = pointer[:ects]
|
2666
|
+
this_university = pointer[:university]
|
2667
|
+
if hash.has_key? this_university
|
2668
|
+
hash[this_university] += n_ects
|
2669
|
+
else
|
2670
|
+
hash[this_university] = n_ects
|
2671
|
+
end
|
2672
|
+
else
|
2673
|
+
e steelblue('No entry found for ')+
|
2674
|
+
royalblue(entry.to_s)
|
2675
|
+
end
|
2676
|
+
}
|
2677
|
+
Studium.report_n_ects_per_university(hash, n_ects_points_in_total?)
|
2678
|
+
end
|
2679
|
+
|
2680
|
+
# ========================================================================= #
|
2681
|
+
# === reset
|
2682
|
+
# ========================================================================= #
|
2683
|
+
def reset
|
2684
|
+
super()
|
2685
|
+
is_bachelor_curriculum # ← This is just to set a default.
|
2686
|
+
infer_the_namespace
|
2687
|
+
# ======================================================================= #
|
2688
|
+
# === @lecture_dataset
|
2689
|
+
#
|
2690
|
+
# This variable keeps track of all registered lectures at the
|
2691
|
+
# universities.
|
2692
|
+
# ======================================================================= #
|
2693
|
+
@lecture_dataset = return_dataset_from_the_file_lecture_information
|
2694
|
+
# ======================================================================= #
|
2695
|
+
# === @this_curriculum_has_n_ects_points_in_total
|
2696
|
+
# ======================================================================= #
|
2697
|
+
@this_curriculum_has_n_ects_points_in_total = 0
|
2698
|
+
# ======================================================================= #
|
2699
|
+
# === @n_ects_were_passed_so_far
|
2700
|
+
# ======================================================================= #
|
2701
|
+
@n_ects_were_passed_so_far = 0
|
2702
|
+
# ======================================================================= #
|
2703
|
+
# === @shall_we_sort_the_dataset
|
2704
|
+
# ======================================================================= #
|
2705
|
+
@shall_we_sort_the_dataset = true # ← Whether to sort the dataset or not.
|
2706
|
+
# ======================================================================= #
|
2707
|
+
# === @dataset
|
2708
|
+
# ======================================================================= #
|
2709
|
+
@dataset = []
|
2710
|
+
# ======================================================================= #
|
2711
|
+
# === @title
|
2712
|
+
#
|
2713
|
+
# Which title to use for this curriculum.
|
2714
|
+
# ======================================================================= #
|
2715
|
+
@title = nil
|
2716
|
+
# ======================================================================= #
|
2717
|
+
# === @hash_containing_the_lectures_for_this_curriculum
|
2718
|
+
#
|
2719
|
+
# The following hash will contain the lectures that are used for
|
2720
|
+
# the curriculum. Specifically it will be used to autogenerate the
|
2721
|
+
# .html file.
|
2722
|
+
# ======================================================================= #
|
2723
|
+
@hash_containing_the_lectures_for_this_curriculum = {}
|
2724
|
+
# ======================================================================= #
|
2725
|
+
# === @individual_curriculum
|
2726
|
+
#
|
2727
|
+
# The following variable determines whether this lecture is an
|
2728
|
+
# individual curriculum or whether it is not.
|
2729
|
+
# ======================================================================= #
|
2730
|
+
@individual_curriculum = false
|
2731
|
+
# ======================================================================= #
|
2732
|
+
# === @show_next_exams
|
2733
|
+
# ======================================================================= #
|
2734
|
+
@show_next_exams = true
|
2735
|
+
# ======================================================================= #
|
2736
|
+
# === @n_lectures_are_already_solved
|
2737
|
+
# ======================================================================= #
|
2738
|
+
@n_lectures_are_already_solved = 0
|
2739
|
+
# ======================================================================= #
|
2740
|
+
# Next, determine from which files we will read.
|
2741
|
+
# ======================================================================= #
|
2742
|
+
determine_from_which_files_to_read
|
2743
|
+
# ======================================================================= #
|
2744
|
+
# === @array_storing_the_grades
|
2745
|
+
# ======================================================================= #
|
2746
|
+
@array_storing_the_grades = []
|
2747
|
+
# ======================================================================= #
|
2748
|
+
# === @generate_html_file
|
2749
|
+
#
|
2750
|
+
# If the following variable is true then this class will additionally
|
2751
|
+
# generate a .html file.
|
2752
|
+
# ======================================================================= #
|
2753
|
+
@generate_html_file = true
|
2754
|
+
# ======================================================================= #
|
2755
|
+
# === @mode
|
2756
|
+
#
|
2757
|
+
# The @mode can be :commandline or :www.
|
2758
|
+
# ======================================================================= #
|
2759
|
+
@mode = :commandline
|
2760
|
+
# ======================================================================= #
|
2761
|
+
# === @show_loaded_from_which_file
|
2762
|
+
# ======================================================================= #
|
2763
|
+
@show_loaded_from_which_file = true
|
2764
|
+
# ======================================================================= #
|
2765
|
+
# === @do_report
|
2766
|
+
# ======================================================================= #
|
2767
|
+
@do_report = true
|
2768
|
+
# ======================================================================= #
|
2769
|
+
# === @show_all_URLs
|
2770
|
+
# ======================================================================= #
|
2771
|
+
@show_all_URLs = false
|
2772
|
+
# ======================================================================= #
|
2773
|
+
# === @html_string
|
2774
|
+
# ======================================================================= #
|
2775
|
+
@html_string = nil
|
2776
|
+
# ======================================================================= #
|
2777
|
+
# === @show_to_which_universities_the_lectures_belong_to
|
2778
|
+
#
|
2779
|
+
# By default we will not show to which university the given lectures
|
2780
|
+
# belong to.
|
2781
|
+
# ======================================================================= #
|
2782
|
+
@show_to_which_universities_the_lectures_belong_to = false
|
2783
|
+
# ======================================================================= #
|
2784
|
+
# === @append_this_string_onto_the_html_string
|
2785
|
+
#
|
2786
|
+
# The following instance variable can be used to append more onto
|
2787
|
+
# the main HTML string.
|
2788
|
+
# ======================================================================= #
|
2789
|
+
@append_this_string_onto_the_html_string = ''.dup
|
2790
|
+
# ======================================================================= #
|
2791
|
+
# === @ignore_outdated_lectures
|
2792
|
+
# ======================================================================= #
|
2793
|
+
@ignore_outdated_lectures = false
|
2794
|
+
end
|
2795
|
+
|
2796
|
+
# ========================================================================= #
|
2797
|
+
# === do_all_actions_after_the_main_dataset_was_read_in
|
2798
|
+
# ========================================================================= #
|
2799
|
+
def do_all_actions_after_the_main_dataset_was_read_in
|
2800
|
+
iterate_over_the_lectures
|
2801
|
+
consider_showing_to_which_universities_the_lectures_belong_to
|
2802
|
+
# ======================================================================= #
|
2803
|
+
# The next method will output something like:
|
2804
|
+
# "A total of 52 lectures are part of this Curriculum."
|
2805
|
+
# ======================================================================= #
|
2806
|
+
if commandline?
|
2807
|
+
report_how_many_lectures_are_in_this_curriculum_and_how_many_of_them_are_already_solved
|
2808
|
+
report_how_many_ects_points_have_been_passed_already
|
2809
|
+
report_how_many_ects_points_are_in_this_curriculum
|
2810
|
+
report_the_average_grade
|
2811
|
+
report_the_university_attribution
|
2812
|
+
end
|
2813
|
+
consider_generating_a_html_file
|
2814
|
+
end
|
2815
|
+
|
2816
|
+
# ========================================================================= #
|
2817
|
+
# === run (run tag)
|
2818
|
+
#
|
2819
|
+
# The menu() method has to come before any other methods here.
|
2820
|
+
# ========================================================================= #
|
2821
|
+
def run
|
2822
|
+
menu # First, pass the commandline into the menu-method.
|
2823
|
+
read_in_main_dataset_from_the_existing_files
|
2824
|
+
if commandline?
|
2825
|
+
try_to_rename_kde_konsole_tab
|
2826
|
+
report_title
|
2827
|
+
end
|
2828
|
+
do_all_actions_after_the_main_dataset_was_read_in # Continue here.
|
2829
|
+
end
|
2830
|
+
|
2831
|
+
# ========================================================================= #
|
2832
|
+
# === show_important_files
|
2833
|
+
#
|
2834
|
+
# This method will show the file that has all lectures registered.
|
2835
|
+
#
|
2836
|
+
# Usage example:
|
2837
|
+
#
|
2838
|
+
# curriculum --files?
|
2839
|
+
#
|
2840
|
+
# ========================================================================= #
|
2841
|
+
def show_important_files(
|
2842
|
+
use_this_file = Studium.file_lecture_information
|
2843
|
+
)
|
2844
|
+
e "The following file is the most important file by far:"
|
2845
|
+
e
|
2846
|
+
e " #{sfile(use_this_file)}"
|
2847
|
+
e
|
2848
|
+
end
|
2849
|
+
|
2850
|
+
# ========================================================================= #
|
2851
|
+
# === show_available_curricula
|
2852
|
+
#
|
2853
|
+
# This method will show the available Curricula.
|
2854
|
+
#
|
2855
|
+
# Invocation example:
|
2856
|
+
#
|
2857
|
+
# studium_solved --show-available
|
2858
|
+
#
|
2859
|
+
# ========================================================================= #
|
2860
|
+
def show_available_curricula
|
2861
|
+
e 'These curricula are available:'
|
2862
|
+
e
|
2863
|
+
Studium.return_array_location_of_all_registered_curricula.each {|entry|
|
2864
|
+
if entry.is_a? Array
|
2865
|
+
entry.each {|inner_entry|
|
2866
|
+
e " #{sfancy(File.basename(inner_entry).sub(/\.yml$/,''))}"
|
2867
|
+
}
|
2868
|
+
else
|
2869
|
+
e " #{sfancy(File.basename(entry).sub(/\.yml$/,'').strip)}"
|
2870
|
+
end
|
2871
|
+
}; e
|
2872
|
+
end
|
2873
|
+
|
2874
|
+
# ========================================================================= #
|
2875
|
+
# === do_show_lecture_attribution_to_universities
|
2876
|
+
# ========================================================================= #
|
2877
|
+
def do_show_lecture_attribution_to_universities
|
2878
|
+
@show_to_which_universities_the_lectures_belong_to = true
|
2879
|
+
end
|
2880
|
+
|
2881
|
+
# ========================================================================= #
|
2882
|
+
# === consider_showing_to_which_universities_the_lectures_belong_to
|
2883
|
+
#
|
2884
|
+
# We should only show as to which university a particular lecture
|
2885
|
+
# belongs to if it is an individual curriculum. Other curricula
|
2886
|
+
# all belong to one particular university, so showing the "table"
|
2887
|
+
# on the commandline is useless.
|
2888
|
+
# ========================================================================= #
|
2889
|
+
def consider_showing_to_which_universities_the_lectures_belong_to
|
2890
|
+
if @show_to_which_universities_the_lectures_belong_to
|
2891
|
+
first_argument = @commandline_arguments
|
2892
|
+
if first_argument.is_a? Array
|
2893
|
+
first_argument = first_argument.first
|
2894
|
+
end
|
2895
|
+
first_argument = first_argument.to_s.delete('-')
|
2896
|
+
if cmdline?
|
2897
|
+
e
|
2898
|
+
e 'The percentage-value of lectures attributed to '\
|
2899
|
+
'the different'
|
2900
|
+
e 'universities will be shown next:'
|
2901
|
+
end
|
2902
|
+
_ = Studium::LecturesAttributedToUniversities.new(first_argument) {
|
2903
|
+
:do_not_show_the_title_and_do_not_report
|
2904
|
+
}
|
2905
|
+
splitted_html_string = _.html_string.split("\n")
|
2906
|
+
# ===================================================================== #
|
2907
|
+
# Also embed this into a little <div> container next:
|
2908
|
+
# ===================================================================== #
|
2909
|
+
@append_this_string_onto_the_html_string <<
|
2910
|
+
'<div style="padding: 0.70em; background-color: black; '\
|
2911
|
+
'font-size: 1.0em; font-family: monospace;">'
|
2912
|
+
splitted_html_string.each {|line|
|
2913
|
+
@append_this_string_onto_the_html_string << "<b>#{line.strip}</b><br>#{N}"
|
2914
|
+
}
|
2915
|
+
@append_this_string_onto_the_html_string << '</div>'
|
2916
|
+
# ===================================================================== #
|
2917
|
+
# And now we can report our findings, if we are on the commandline.
|
2918
|
+
# ===================================================================== #
|
2919
|
+
_.report if cmdline?
|
2920
|
+
end
|
2921
|
+
end
|
2922
|
+
|
2923
|
+
# ========================================================================= #
|
2924
|
+
# === iterate_over_the_lectures (iterate tag)
|
2925
|
+
# ========================================================================= #
|
2926
|
+
def iterate_over_the_lectures(
|
2927
|
+
i = @dataset
|
2928
|
+
)
|
2929
|
+
i.each_with_index {|line, index| index += 1
|
2930
|
+
result = ''.dup # This is the line that will be reported to the user.
|
2931
|
+
# ===================================================================== #
|
2932
|
+
# Since as of January 2018 the dataset has already been sanitized a
|
2933
|
+
# bit before coming to this method, so there will no longer be any
|
2934
|
+
# '#' characters. In the past, the variable line would look like
|
2935
|
+
# this:
|
2936
|
+
#
|
2937
|
+
# "754117 Mikrobiologie - Übungen (AW) # 2.0 ECTS, UE\n"
|
2938
|
+
#
|
2939
|
+
# That is why the next line still checks for this.
|
2940
|
+
# ===================================================================== #
|
2941
|
+
if line and line.include?('#')
|
2942
|
+
raw_line = line[0 .. (line.index('#') - 1)] # ← raw_line is like: "754117 Mikrobiologie - Übungen (AW)"
|
2943
|
+
# ===================================================================== #
|
2944
|
+
# The next code checks for a leading LVA-id entry, but it must also
|
2945
|
+
# keep in mind that ID entries may be like this: "185.A47"
|
2946
|
+
# ===================================================================== #
|
2947
|
+
# elsif starts_with_a_lecture_id_entry?(line)
|
2948
|
+
# raw_line = line.split(' ')[1 .. -1].join(' ').strip.dup
|
2949
|
+
else
|
2950
|
+
raw_line = line.dup
|
2951
|
+
end
|
2952
|
+
raw_line.strip! # ← Added this in December 2019.
|
2953
|
+
raw_line.squeeze!(' ') # ← Added this as of March 2018.
|
2954
|
+
# ===================================================================== #
|
2955
|
+
# Obtain the remote URL. Since as of 20.02.2018, this requires that
|
2956
|
+
# the beautiful_url project also deals with leading numbers, so all
|
2957
|
+
# entries must have that too, as an additional qualifier.
|
2958
|
+
#
|
2959
|
+
# On November 2019 support for BeautifulUrl was removed, and
|
2960
|
+
# replaced with Studium.return_remote_url_of_this_lecture()
|
2961
|
+
# instead.
|
2962
|
+
# ===================================================================== #
|
2963
|
+
remote_url = Studium.return_remote_url_of_this_lecture(raw_line)
|
2964
|
+
if remote_url == raw_line
|
2965
|
+
e crimson("No registered remote homepage for #{raw_line}.")
|
2966
|
+
end
|
2967
|
+
splitted = raw_line.split(' ')
|
2968
|
+
lecture_id = splitted.first # ← Obtain the lecture id.
|
2969
|
+
name_of_the_lecture = splitted[1..-1].join(' ')
|
2970
|
+
padded_index = ('('+index.to_s+')').rjust(5)
|
2971
|
+
colourized_index = slategray(padded_index)
|
2972
|
+
# ===================================================================== #
|
2973
|
+
# Create a colourized string for the remote URL next.
|
2974
|
+
# ===================================================================== #
|
2975
|
+
colourized_remote_url = N+dodgerblue(' → ')+
|
2976
|
+
dodgerblue(remote_url)+
|
2977
|
+
dodgerblue(' ☚')
|
2978
|
+
pointer_to_the_lecture = @lecture_dataset[raw_line]
|
2979
|
+
if pointer_to_the_lecture and
|
2980
|
+
pointer_to_the_lecture.has_key?(:already_solved)
|
2981
|
+
already_solved = pointer_to_the_lecture[:already_solved]
|
2982
|
+
else
|
2983
|
+
opne "#{swarn('Problem with `')}#{sfancy(raw_line)}#{swarn('`:')}"
|
2984
|
+
opne swarn('no registered key called :already_solved was found')
|
2985
|
+
# =================================================================== #
|
2986
|
+
# Also inform the user whether this lecture is registered at all.
|
2987
|
+
# If not, notify the user about this.
|
2988
|
+
# =================================================================== #
|
2989
|
+
unless main_dataset?.has_key? raw_line
|
2990
|
+
opne swarn('The lecture ')+
|
2991
|
+
sfancy(raw_line)+swarn(' has not yet been')
|
2992
|
+
opne swarn('registered in the file `')+
|
2993
|
+
sfancy('lecture_information.yml')+
|
2994
|
+
swarn('`.')
|
2995
|
+
end
|
2996
|
+
pp pointer_to_the_lecture
|
2997
|
+
already_solved = false
|
2998
|
+
end
|
2999
|
+
if pointer_to_the_lecture.nil?
|
3000
|
+
opne "Skipping this lecture (#{sfancy(raw_line)})"
|
3001
|
+
opne 'as it is not registered or otherwise missing.'
|
3002
|
+
next
|
3003
|
+
end
|
3004
|
+
# ===================================================================== #
|
3005
|
+
# Deconstruct the content of our hash-"pointer" next.
|
3006
|
+
# ===================================================================== #
|
3007
|
+
n_ects_points = pointer_to_the_lecture[:ects]
|
3008
|
+
@this_curriculum_has_n_ects_points_in_total += n_ects_points
|
3009
|
+
padded_name_of_the_lecture = name_of_the_lecture.ljust(76)
|
3010
|
+
padded_n_ects_points = n_ects_points.to_s.rjust(5)
|
3011
|
+
colourized_n_ects_points = steelblue(padded_n_ects_points)
|
3012
|
+
expanded_ja_oder_nein = ja_oder_nein(already_solved)
|
3013
|
+
case expanded_ja_oder_nein
|
3014
|
+
when 'Ja'
|
3015
|
+
colourized_ja_oder_nein = lightgreen(expanded_ja_oder_nein.rjust(4))
|
3016
|
+
when 'Nein' # Lectures that were not yet passed, will be highlighted in red.
|
3017
|
+
colourized_ja_oder_nein = crimson(expanded_ja_oder_nein.rjust(4))
|
3018
|
+
end
|
3019
|
+
fancified_already_solved = 'Bereits absolviert? '+colourized_ja_oder_nein+'. '
|
3020
|
+
result << colourized_index+' '+
|
3021
|
+
sfancy(padded_name_of_the_lecture)+' '+
|
3022
|
+
fancified_already_solved+
|
3023
|
+
'('+mediumseagreen('LVA Nummer: ')+
|
3024
|
+
sfancy(lecture_id.rjust(7))
|
3025
|
+
grade = nil
|
3026
|
+
if already_solved
|
3027
|
+
# =================================================================== #
|
3028
|
+
# Obtain the grade of this lecture.
|
3029
|
+
# =================================================================== #
|
3030
|
+
if pointer_to_the_lecture.has_key? :grade
|
3031
|
+
grade = pointer_to_the_lecture[:grade]
|
3032
|
+
# ================================================================= #
|
3033
|
+
# We must keep in mind that the grade can also be a '+' character.
|
3034
|
+
# We can not calculate the average number from entries that are
|
3035
|
+
# '+' Strings, so we will ignore these entries - but we will
|
3036
|
+
# do so not here but lateron, when we calculate the average grade.
|
3037
|
+
# ================================================================= #
|
3038
|
+
@array_storing_the_grades << grade
|
3039
|
+
end
|
3040
|
+
@n_lectures_are_already_solved += 1
|
3041
|
+
@n_ects_were_passed_so_far += n_ects_points
|
3042
|
+
# =================================================================== #
|
3043
|
+
# If the lecture was already solved then we will not show
|
3044
|
+
# the remote URL.
|
3045
|
+
# =================================================================== #
|
3046
|
+
colourized_remote_url = ''
|
3047
|
+
end
|
3048
|
+
result << ', '+mediumseagreen('n ECTS: ')+colourized_n_ects_points
|
3049
|
+
if grade
|
3050
|
+
result << ', '+mediumseagreen('Grade: '+grade.to_s)
|
3051
|
+
end
|
3052
|
+
unless ALSO_SHOW_URL
|
3053
|
+
colourized_remote_url = ''
|
3054
|
+
end
|
3055
|
+
if @do_report and cmdline? # We only report this on the commandline.
|
3056
|
+
result << ') '+colourized_remote_url
|
3057
|
+
e result
|
3058
|
+
end
|
3059
|
+
}
|
3060
|
+
if @this_curriculum_has_n_ects_points_in_total >= 270.0
|
3061
|
+
# ===================================================================== #
|
3062
|
+
# This check is to avoid checking for combined bachelor-master
|
3063
|
+
# individual curricula, as we can not show a correct module
|
3064
|
+
# chain in this case really - or at the least not without
|
3065
|
+
# additional code (23.12.2019).
|
3066
|
+
# ===================================================================== #
|
3067
|
+
else
|
3068
|
+
if is_it_an_individual_curriculum? and is_on_roebe?
|
3069
|
+
opne 'Trying to generate an image displaying '\
|
3070
|
+
'the '+steelblue('modules')+' next.'
|
3071
|
+
consider_generating_a_graphviz_image_displaying_the_modules(
|
3072
|
+
i
|
3073
|
+
)
|
3074
|
+
opne 'Trying to generate a '+steelblue('spreadsheet')+' next.'
|
3075
|
+
consider_generating_a_spreadsheet
|
3076
|
+
end
|
3077
|
+
end
|
3078
|
+
end; alias do_the_main_iteration iterate_over_the_lectures # === do_the_main_iteration
|
3079
|
+
|
3080
|
+
# ========================================================================= #
|
3081
|
+
# === return_how_many_lectures_are_in_this_curriculum_and_how_many_of_them_are_already_solved
|
3082
|
+
#
|
3083
|
+
# This method will return an Array with two members. The reason for this
|
3084
|
+
# is that it is easier on the commandline to output two Arrays; and to
|
3085
|
+
# also use this when we autogenerate a .html file.
|
3086
|
+
# ========================================================================= #
|
3087
|
+
def return_how_many_lectures_are_in_this_curriculum_and_how_many_of_them_are_already_solved(
|
3088
|
+
optional_use_colours = true
|
3089
|
+
)
|
3090
|
+
n_percent = (
|
3091
|
+
(@n_lectures_are_already_solved.to_i * 100) / @dataset.size.to_f
|
3092
|
+
).round(1)
|
3093
|
+
case optional_use_colours # Use colours in this case.
|
3094
|
+
# ======================================================================= #
|
3095
|
+
# === :use_for_html
|
3096
|
+
# ======================================================================= #
|
3097
|
+
when :use_for_html # (html tag, www tag)
|
3098
|
+
colourized_n_percent_finished = ' (<b>'+n_percent.to_s+'% finished'+'</b>)'
|
3099
|
+
first_part = "A total of <b>#{@dataset.size.to_s}</b> lectures are part of this Curriculum."
|
3100
|
+
second_part = "<b>#{@n_lectures_are_already_solved.to_s}</b> of these "\
|
3101
|
+
"are already solved.#{colourized_n_percent_finished}"
|
3102
|
+
# ======================================================================= #
|
3103
|
+
# === :no_colours
|
3104
|
+
# ======================================================================= #
|
3105
|
+
when :no_colours, false
|
3106
|
+
colourized_n_percent_finished = ' ('+n_percent.to_s+'% finished'+')'
|
3107
|
+
first_part = "A total of #{@dataset.size.to_s} lectures are part of this Curriculum."
|
3108
|
+
second_part = "#{@n_lectures_are_already_solved.to_s} of these "\
|
3109
|
+
"are already solved.#{colourized_n_percent_finished}"
|
3110
|
+
else # This here is the default clause.
|
3111
|
+
colourized_n_percent_finished = ' ('+orangered(n_percent.to_s+'% finished')+')'
|
3112
|
+
first_part = "A total of #{springgreen(@dataset.size.to_s)} "\
|
3113
|
+
"lectures are part of this Curriculum."
|
3114
|
+
second_part = "#{springgreen(@n_lectures_are_already_solved.to_s)} of these "\
|
3115
|
+
"are already solved.#{colourized_n_percent_finished}"
|
3116
|
+
end
|
3117
|
+
[ first_part, second_part ]
|
3118
|
+
end
|
3119
|
+
|
3120
|
+
# ========================================================================= #
|
3121
|
+
# === do_ignore_outdated_lectures
|
3122
|
+
# ========================================================================= #
|
3123
|
+
def do_ignore_outdated_lectures
|
3124
|
+
@ignore_outdated_lectures = true
|
3125
|
+
end
|
3126
|
+
|
3127
|
+
# ========================================================================= #
|
3128
|
+
# === ignore_outdated_lectures?
|
3129
|
+
# ========================================================================= #
|
3130
|
+
def ignore_outdated_lectures?
|
3131
|
+
@ignore_outdated_lectures
|
3132
|
+
end
|
3133
|
+
|
3134
|
+
# ========================================================================= #
|
3135
|
+
# === Studium::ShowLecturesOnTheCommandline[]
|
3136
|
+
# ========================================================================= #
|
3137
|
+
def self.[](commandline_arguments = ARGV, run_already = true)
|
3138
|
+
new(commandline_arguments, run_already)
|
3139
|
+
end
|
3140
|
+
|
3141
|
+
end; end
|
3142
|
+
|
3143
|
+
if __FILE__ == $PROGRAM_NAME
|
3144
|
+
Studium::ShowLecturesOnTheCommandline.new(ARGV)
|
3145
|
+
end # show_lectures_on_the_commandline
|
3146
|
+
# show_lectures_on_the_commandline individuell
|
3147
|
+
# show_lectures_on_the_commandline bachelor_biologie
|
3148
|
+
# show_lectures_on_the_commandline individuelles_bachelor_studium
|
3149
|
+
# show_lectures_on_the_commandline LBT
|
3150
|
+
# show_lectures_on_the_commandline agrarbiotechnologie
|
3151
|
+
# show_lectures_on_the_commandline biologie
|
3152
|
+
# show_lectures_on_the_commandline botanik
|
3153
|
+
# show_lectures_on_the_commandline pharmazie
|
3154
|
+
# show_lectures_on_the_commandline bachelor_pharmazie
|
3155
|
+
# show_lectures_on_the_commandline tu_master_biotech
|
3156
|
+
# show_lectures_on_the_commandline AW
|
3157
|
+
# show_lectures_on_the_commandline immunbio
|
3158
|
+
# show_lectures_on_the_commandline bachelor_mikrobiologie_und_genetik
|
3159
|
+
# show_lectures_on_the_commandline master_molbio
|
3160
|
+
# show_lectures_on_the_commandline bachelor_molbio
|