aboutsummaryrefslogtreecommitdiffstats
path: root/bitbake/lib/toaster/orm/models.py
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/toaster/orm/models.py')
-rw-r--r--bitbake/lib/toaster/orm/models.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/bitbake/lib/toaster/orm/models.py b/bitbake/lib/toaster/orm/models.py
index 1cf997cfe52..b70fa18feb3 100644
--- a/bitbake/lib/toaster/orm/models.py
+++ b/bitbake/lib/toaster/orm/models.py
@@ -749,6 +749,20 @@ class Package(models.Model):
section = models.CharField(max_length=80, blank=True)
license = models.CharField(max_length=80, blank=True)
+ @property
+ def is_locale_package(self):
+ """ Returns True if this package is identifiable as a locale package """
+ if self.name.find('locale') != -1:
+ return True
+ return False
+
+ @property
+ def is_packagegroup(self):
+ """ Returns True is this package is identifiable as a packagegroup """
+ if self.name.find('packagegroup') != -1:
+ return True
+ return False
+
class CustomImagePackage(Package):
# CustomImageRecipe fields to track pacakges appended,
# included and excluded from a CustomImageRecipe