JSON

data class JSON(val id: String, val name: String, val aPlusUrl: URL, val languages: List<String>, val resources: Map<String, URL>, val vmOptions: Map<String, String>? = null, val autoInstall: List<String>? = null, val repl: CourseConfig.REPL? = null, val modules: List<CourseConfig.Module>, val exerciseModules: Map<String, Map<String, String>>, val hiddenElements: List<Long>? = null)

This class serves as the serializer and documentation for the course configuration file.

Example configuration file:

{
"id": "197",
"name": "O1",
"aPlusUrl": "https://plus.cs.aalto.fi/",
"languages": [
"fi",
"en"
],
"resources": {
"ideSettings": "https://grader.cs.aalto.fi/static/O1_2021/projects/o1_2021_ij_settings.zip",
"ideSettingsMac": "https://grader.cs.aalto.fi/static/O1_2021/projects/o1_2021_ij_mac_settings.zip",
"projectSettings": "https://grader.cs.aalto.fi/static/O1_2021/projects/o1_2021_project_settings.zip"
},
"vmOptions": {
"file.encoding": "UTF-8"
},
"autoInstall": [
"O1Library"
],
"repl": {
"initialCommands": {
"Adventure": [
"import o1.adventure._"
],
"AdventureDraft": [
"import o1.adventure.draft._"
],
"Aliohjelmia": [
"import o1._",
"import o1.aliohjelmia._"
]
}
},
"modules": [
{
"name": "Adventure",
"url": "https://grader.cs.aalto.fi/static/O1_2021/projects/given/Adventure/Adventure.zip",
"version": "1.0",
"changelog": ""
},
{
"name": "AdventureDraft",
"url": "https://grader.cs.aalto.fi/static/O1_2021/projects/given/AdventureDraft/AdventureDraft.zip",
"version": "1.0",
"changelog": ""
},
{
"name": "Aliohjelmia",
"url": "https://grader.cs.aalto.fi/static/O1_2021/projects/given/Aliohjelmia/Aliohjelmia.zip",
"version": "1.0",
"changelog": ""
}
],
"exerciseModules": {
"31353": {
"en": "Subprograms",
"fi": "Aliohjelmia"
},
"31383": {
"en": "IntroOOP",
"fi": "Oliointro"
},
"31427": {
"en": "Ave",
"fi": "Ave"
}
}
}

Constructors

Link copied to clipboard
constructor(id: String, name: String, aPlusUrl: URL, languages: List<String>, resources: Map<String, URL>, vmOptions: Map<String, String>? = null, autoInstall: List<String>? = null, repl: CourseConfig.REPL? = null, modules: List<CourseConfig.Module>, exerciseModules: Map<String, Map<String, String>>, hiddenElements: List<Long>? = null)

Properties

Link copied to clipboard

URL for A+. "aPlusUrl": "https://plus.cs.aalto.fi/"

Link copied to clipboard
val autoInstall: List<String>? = null

An array of the modules that get installed automatically when the project gets turned into an A+ project. "autoInstall": ["O1Library"]

Link copied to clipboard

Information, about which module each assignment uses. The assignment ID is used as a key to a map, where language codes are used as keys for the module names. "exerciseModules": { "31353": { "en": "Subprograms", "fi": "Aliohjelmia" } }

Link copied to clipboard
val hiddenElements: List<Long>? = null

TODO

Link copied to clipboard
val id: String

ID for the course from the A+ API. "id": "197"

Link copied to clipboard

An array of the languages for the assignments. Different languages may use different modules. "languages": ["fi", "en"]

Link copied to clipboard

An array of objects containing information about modules. See Module.

Link copied to clipboard

Name of the course that gets shown in the UI. "name": "O1"

Link copied to clipboard
val repl: CourseConfig.REPL? = null

Settings for the Scala REPL. See REPL.

Link copied to clipboard

URLs for some resources the plugin uses:

Link copied to clipboard
val vmOptions: Map<String, String>? = null

A map of options for the JVM. "vmOptions": {"file.encoding": "UTF-8"}