Skip to content

Commit

Permalink
Merge pull request #70 from rdkcentral/devlipment/R5_StartMode
Browse files Browse the repository at this point in the history
[STARTMODE] Preperations for R5, starmode supersedes the autostart flag.
  • Loading branch information
pwielders authored Jan 10, 2024
2 parents 829de57 + f714e58 commit 847446f
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
4 changes: 2 additions & 2 deletions ConfigGenerator/params.config
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
autostart
startmode
callsign
communicator
configuration
Expand All @@ -10,4 +10,4 @@ startuporder
systemrootpath
terminations
volatilepathpostfix
webui
webui
8 changes: 4 additions & 4 deletions JsonGenerator/source/documentation_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -759,9 +759,9 @@ def mergedict(d1, d2, prop):
if "locator" in info:
commonConfig["locator"] = {"type": "string", "description": 'Library name: *%s*' % info["locator"]}

commonConfig["autostart"] = {
"type": "boolean",
"description": "Determines if the plugin shall be started automatically along with the framework"
commonConfig["startmode"] = {
"type": "string",
"description": "Determines in which state the plugin should be moved to at startup of the framework"
}

required = []
Expand All @@ -777,7 +777,7 @@ def mergedict(d1, d2, prop):
totalConfig["properties"] = commonConfig2

if "configuration" not in schema or ("nodefault" not in schema["configuration"] or not schema["configuration"]["nodefault"]):
totalConfig["required"] = ["callsign", "classname", "locator", "autostart"] + required
totalConfig["required"] = ["callsign", "classname", "locator", "startmode"] + required

ParamTable("", totalConfig)

Expand Down
6 changes: 5 additions & 1 deletion cmake/FindConfigGenerator.cmake.in
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,11 @@ if(CMAKE_VERSION VERSION_LESS 3.20.0 AND LEGACY_CONFIG_GENERATOR)
endif()

if (NOT ${autostart} STREQUAL "")
map_append(${plugin_config} autostart ${autostart})
if (${autostart} STREQUAL "false")
map_append(${plugin_config} startmode "Deactivated")
else()
map_append(${plugin_config} startmode "Activated")
endif()
endif()

if (NOT ${resumed} STREQUAL "")
Expand Down

0 comments on commit 847446f

Please sign in to comment.