[go: up one dir, main page]

File: PluginObject.py

package info (click to toggle)
uranium 3.3.0-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 5,876 kB
  • sloc: python: 22,349; sh: 111; makefile: 11
file content (26 lines) | stat: -rw-r--r-- 707 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# Copyright (c) 2018 Ultimaker B.V.
# Uranium is released under the terms of the LGPLv3 or higher.


##  Base class for objects that can be provided by a plugin.
#
#   This class should be inherited by any class that can be provided
#   by a plugin. Its only function is to serve as a mapping between
#   the plugin and the object.

class PluginObject:
    def __init__(self):
        self._plugin_id = None
        self._version = None

    def getPluginId(self):
        return self._plugin_id

    def setPluginId(self, plugin_id):
        self._plugin_id = plugin_id

    def setVersion(self, version: str):
        self._version = version

    def getVersion(self) -> str:
        return self._version