Skip to content
Snippets Groups Projects
Commit 4f985403 authored by Samuel GAIST's avatar Samuel GAIST
Browse files

[algorithm][Algorithm] Add is_autonomous property

This will allow to simplify checking for autonomous algorithm types
parent 1c8c93d2
Branches
Tags
2 merge requests!281.6.x,!27Soft loop
...@@ -613,6 +613,14 @@ class Algorithm(object): ...@@ -613,6 +613,14 @@ class Algorithm(object):
return self.data.get('type', Algorithm.SEQUENTIAL) return self.data.get('type', Algorithm.SEQUENTIAL)
@property
def is_autonomous(self):
""" Returns whether the algorithm is in the autonomous category"""
return self.type in [Algorithm.AUTONOMOUS,
Algorithm.LOOP_USER,
Algorithm.LOOP]
@language.setter @language.setter
def language(self, value): def language(self, value):
"""Sets the current executable code programming language""" """Sets the current executable code programming language"""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment