mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-08 07:27:29 -06:00
Add boilerplate version upgrade plug-in
This plug-in does nothing at the moment. It merely says that it is able to upgrade configuration from version 2.1 to 2.2, but then raises exceptions when you actually try to use it. This is by design. I will now implement the functions that do the conversion. Contributes to issue CURA-844.
This commit is contained in:
parent
b072b7935f
commit
2f4e63a944
5 changed files with 141 additions and 0 deletions
20
plugins/VersionUpgrade/VersionUpgrade21to22/Preferences.py
Normal file
20
plugins/VersionUpgrade/VersionUpgrade21to22/Preferences.py
Normal file
|
@ -0,0 +1,20 @@
|
|||
# Copyright (c) 2015 Ultimaker B.V.
|
||||
# Cura is released under the terms of the AGPLv3 or higher.
|
||||
|
||||
## Creates a new preferences instance by parsing a serialised preferences file
|
||||
# in version 2 of the file format.
|
||||
#
|
||||
# \param serialised The serialised form of a preferences file in version 2.
|
||||
# \return A preferences instance, or None if the file format is incorrect.
|
||||
def importVersion2(serialised):
|
||||
return None #Not implemented yet.
|
||||
|
||||
## A representation of a preferences file used as intermediary form for
|
||||
# conversion from one format to the other.
|
||||
class Preferences:
|
||||
## Serialises this preferences file as file format version 3.
|
||||
#
|
||||
# \return A serialised form of this preferences file, serialised in
|
||||
# version 3 of the file format.
|
||||
def exportVersion3():
|
||||
raise Exception("Not implemented yet.")
|
Loading…
Add table
Add a link
Reference in a new issue