GUI model#

class besser.BUML.metamodel.gui.graphical_ui.Button(name: str, description: str, label: str, buttonType: ButtonType, actionType: ButtonActionType, targetScreen: Screen = None, visibility: str = 'public')[source]#

Bases: ViewComponent

Represents a button component and encapsulates

specific properties of a button, such as its name and label.

Parameters:
  • name (str) – The name of the button.

  • description (str) – The description of the button.

  • label (str) – The label of the button.

  • buttonType (ButtonType) – The type of the button.

  • actionType (ButtonActionType) – The action type of the button.

  • targetScreen (Screen, optional) – The target Screen associated with the button when the actionType is “Navigate”.

name#

The name of the button.

Type:

str

description#

The description of the button.

Type:

str

label#

The label of the button.

Type:

str

buttonType#

The type of the button.

Type:

ButtonType

actionType#

The action type of the button.

Type:

ButtonActionType

targetScreen#

The target Screen associated with the button when the actionType is “Navigate”

Type:

Screen, optional

_abc_impl = <_abc._abc_data object>#
property actionType: ButtonActionType#

Get the action type of the button.

Type:

str

property buttonType: ButtonType#

Get the type of the button.

Type:

str

property label: str#

Get the label of the button.

Type:

str

property targetScreen: Screen#

Get the target Screen of the button.

Type:

Type

class besser.BUML.metamodel.gui.graphical_ui.ButtonActionType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

Represents a button action type.

About = 'About'#
Add = 'Add'#
Back = 'Back'#
Cancel = 'Cancel'#
Confirm = 'Confirm'#
Delete = 'Delete'#
Exit = 'Exit'#
Filter = 'Filter'#
Help = 'Help'#
Login = 'Login'#
Logout = 'Sign Out'#
Navigate = 'Navigate'#
Next = 'Next'#
OpenForm = 'Open Form'#
Save = 'Save'#
Search = 'Search'#
Select = 'Select'#
Send = 'Send'#
Settings = 'Settings'#
Share = 'Share'#
ShowList = 'Show List'#
Sort = 'Sort'#
SubmitForm = 'Submit Form'#
View = 'View'#
class besser.BUML.metamodel.gui.graphical_ui.ButtonType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

Represents a button type.

CustomizableButton = 'Customizable Button'#
DropdownButton = 'Dropdown Button'#
FloatingActionButton = 'FloatingActionButton'#
IconButton = 'Icon Button'#
OutlinedButton = 'Outlined Button'#
RaisedButton = 'Raised Button'#
TextButton = 'Text Button'#
ToggleButtons = 'Toggle Buttons'#
iOSStyleButton = 'iOS-style Button'#
class besser.BUML.metamodel.gui.graphical_ui.Collection(name: str, type: CollectionSourceType)[source]#

Bases: DataSource

Represents a data source that is a collection.

Parameters:
  • name (str) – The name of the collection data source.

  • type (CollectionSourceType) – The type of the collection data source.

name#

The name of the collection data source.

Type:

str

type#

The type of the collection data source.

Type:

CollectionSourceType

_abc_impl = <_abc._abc_data object>#
property type: CollectionSourceType#

Get the type of the collection data source.

Type:

CollectionSourceType

class besser.BUML.metamodel.gui.graphical_ui.CollectionSourceType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

Represents the type of a collection source.

Array = 'Array'#
Grid = 'Grid'#
List = 'List'#
Stack = 'Stack'#
Table = 'Table'#
Tree = 'Tree'#
class besser.BUML.metamodel.gui.graphical_ui.DataList(name: str, description: str, list_sources: set[DataSource], visibility: str = 'public')[source]#

Bases: ViewComponent

Represents a list component that encapsulates properties

unique to lists, such as list sources.

Parameters:
  • name (str) – The name of the list.

  • list_sources (set[DataSource]) – The set of data sources associated with the list.

name#

The name of the list.

Type:

str

list_sources#

The set of data sources associated with the list.

Type:

set[DataSource]

_abc_impl = <_abc._abc_data object>#
property list_sources: set[DataSource]#

Get the set of data sources associated with the list.

Type:

set[DataSource]

class besser.BUML.metamodel.gui.graphical_ui.DataSource(name: str)[source]#

Bases: NamedElement

Represents a data source.

Parameters:

name (str) – The name of the data source.

name#

The name of the data source.

Type:

str

_abc_impl = <_abc._abc_data object>#
class besser.BUML.metamodel.gui.graphical_ui.DataSourceElement(name: str, dataSourceClass: Class, fields: set[Property])[source]#

Bases: DataSource

Represents a data source associated with a model element.

Parameters:
  • name (str) – The name of the model element data source.

  • dataSourceClass (Class) – The class representing the data source.

  • fields – set[Property]: The fields representing the attributes of the model element.

name#

The name of the model element data source.

Type:

str

dataSourceClass#

The class representing the data source.

Type:

Class

fields#

set[Property]: The fields representing the attributes of the model element.

_abc_impl = <_abc._abc_data object>#
property dataSourceClass: Class#

Get the class representing the data source.

Type:

Class

property fields: set[Property]#

Get the set of properties (fields) of the model element.

Type:

set[Property]

class besser.BUML.metamodel.gui.graphical_ui.File(name: str, type: FileSourceType)[source]#

Bases: DataSource

Represents a data source that is a file.

Parameters:
  • name (str) – The name of the file data source.

  • type (FileSourceType) – The type of the file data source.

name#

The name of the file data source.

Type:

str

type#

The type of the file data source.

Type:

FileSourceType

_abc_impl = <_abc._abc_data object>#
property type: FileSourceType#

Get the type of the file data source.

Type:

FileSourceType

class besser.BUML.metamodel.gui.graphical_ui.FileSourceType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

Represents the type of a file source.

DatabaseFileSystem = 'DatabaseFileSystem'#
FileSystem = 'FileSystem'#
LocalStorage = 'LocalStorage'#
class besser.BUML.metamodel.gui.graphical_ui.Form(name: str, description: str, inputFields: set[InputField], visibility: str = 'public')[source]#

Bases: ViewComponent

Represents a form component and encapsulates the specific

properties of a form, such as its name.

Parameters:
  • name (str) – The name of the form.

  • description (str) – The description of the form.

  • inputFields (set[InputField]) – The set of input fields contained in the form.

name#

The name of the form.

Type:

str

description#

The description of the form.

Type:

str

inputFields#

The set of input fields contained in the form.

Type:

set[InputField]

_abc_impl = <_abc._abc_data object>#
property inputFields: set[InputField]#

Get the set of input Fields contained in the form.

Type:

set[InputField]

class besser.BUML.metamodel.gui.graphical_ui.GUIModel(name: str, package: str, versionCode: str, versionName: str, modules: set[Module], description: str, screenCompatibility: bool = False)[source]#

Bases: Model

It is a subclass of the NamedElement class and encapsulates the properties and behavior

of the GUI part of an application, including its name, package, version code, version name, modules, description, and screen compatibility.

Parameters:
  • name (str) – The name of the model.

  • package (str) – The package of the model.

  • versionCode (str) – The version code of the model.

  • versionName (str) – The version name of the model.

  • modules (set[Module]) – The set of modules contained in the model.

  • description (str) – The description of the model.

  • screenCompatibility (bool) – Indicates whether the model has screen compatibility.

name#

The name of the model.

Type:

str

package#

The package of the model.

Type:

str

versionCode#

The version code of the model.

Type:

str

versionName#

The version name of the model.

Type:

str

modules#

The set of modules contained in the model.

Type:

set[Module]

description#

The description of the model.

Type:

str

screenCompatibility#

Indicates whether the model has screen compatibility.

Type:

bool

_abc_impl = <_abc._abc_data object>#
property description: str#

Get the description of the model.

Type:

str

property modules: set[Module]#

Get the set of modules contained in the model.

Type:

set[Module]

property package: str#

Get the package of the model.

Type:

str

property screenCompatibility: bool#

Get the screen compatibility of the model.

Type:

bool

property versionCode: str#

Get the version code of the model.

Type:

str

property versionName: str#

Get the version name of the model.

Type:

str

class besser.BUML.metamodel.gui.graphical_ui.Image(name: str, description: str)[source]#

Bases: ViewComponent

Represents an image component and encapsulates the specific

properties of a image, such as its name.

Parameters:

name (str) – The name of the image.

name#

The name of the image.

Type:

str

_abc_impl = <_abc._abc_data object>#
class besser.BUML.metamodel.gui.graphical_ui.InputField(name: str, description: str, type: InputFieldType, validationRules: str = None, visibility: str = 'public')[source]#

Bases: ViewComponent

Represents an input field component and encapsulates specific properties

of an input field, such as its type and validation rules.

Args:

name (str): The name of the input field. description (str): The description of the input field. type (str): The type of the input field. validationRules (str): The validation rules for the input field.

name#

The name of the input field.

Type:

str

description#

The description of the input field.

Type:

str

type#

The type of the input field.

Type:

str

validationRules#

The validation rules for the input field.

Type:

str

_abc_impl = <_abc._abc_data object>#
property type: InputFieldType#

Get the type of the input field.

Type:

InputFieldType

property validationRules: str#

Get the validation rules of the input field.

Type:

str

class besser.BUML.metamodel.gui.graphical_ui.InputFieldType(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)[source]#

Bases: Enum

Represents the type of a Input Field.

Color = 'Color'#
Date = 'Date'#
Email = 'Email'#
File = 'File'#
Number = 'Number'#
Password = 'Password'#
Range = 'Range'#
Search = 'Search'#
Tel = 'Tel'#
Text = 'Text'#
Time = 'Time'#
URL = 'URL'#
class besser.BUML.metamodel.gui.graphical_ui.Menu(name: str, description: str, menuItems: set[MenuItem], visibility: str = 'public')[source]#

Bases: ViewComponent

Represents a menu component and encapsulates the

specific properties of a menu, such as its name.

Parameters:
  • name (str) – The name of the menu.

  • description (str) – The description of the menu.

  • menuItems (set[MenuItem]) – The set of menu items contained in the menu.

name#

The name of the menu.

Type:

str

description#

The description of the menu.

Type:

str

menuItems#

The set of menu items contained in the menu.

Type:

set[MenuItem]

_abc_impl = <_abc._abc_data object>#
property menuItems: set[MenuItem]#

Get the set of menuItems.

Type:

set[MenuItem]

class besser.BUML.metamodel.gui.graphical_ui.MenuItem(label: str)[source]#

Bases: Element

Represents an item of a menu.

Parameters:
  • name (str) – The name of the item.

  • label (str) – The label of the menu item.

name#

The name of the item.

Type:

str

label#

The label of the menu item.

Type:

str

_abc_impl = <_abc._abc_data object>#
class besser.BUML.metamodel.gui.graphical_ui.Module(name: str, screens: set[Screen], visibility: str = 'public')[source]#

Bases: NamedElement

Represents a module.

Parameters:
  • name (str) – name (str): The name of the module.

  • screens (set[Screen]) – The set of screens contained in the module.

name#

name (str): The name of the module.

Type:

str

screens#

The set of screens contained in the module.

Type:

set[Screen]

_abc_impl = <_abc._abc_data object>#
property screens: set[Screen]#

Get the set of screens contained.

Type:

set[Screen]

class besser.BUML.metamodel.gui.graphical_ui.Screen(name: str, description: str, view_elements: set[ViewElement], x_dpi: str, y_dpi: str, screen_size: str, is_main_page: bool = False)[source]#

Bases: ViewContainer

Represents a screen.

Parameters:
  • name (str) – The name of the screen.

  • view_elements (set[ViewElement]) – The set of view elements on the screen.

  • x_dpi (str) – The X DPI (dots per inch) of the screen.

  • y_dpi (str) – The Y DPI (dots per inch) of the screen.

  • screen_size (str) – The size of the screen.

  • is_main_page (bool) – wether this screen serves as the main page of the model.

name#

The name of the screen.

Type:

str

view_elements#

The set of view elements on the screen.

Type:

set[ViewElement]

x_dpi#

The X DPI (dots per inch) of the screen.

Type:

str

y_dpi#

The Y DPI (dots per inch) of the screen.

Type:

str

screen_size#

The size of the screen.

Type:

str

is_main_page#

wether this screen serves as the main page of the model.

Type:

bool

_abc_impl = <_abc._abc_data object>#
property is_main_page: bool#

Get whether the screen is main page.

Type:

bool

property screen_size: str#

Get the size of the screen.

Type:

str

property x_dpi: str#

Get the X DPI (dots per inch) of the screen.

Type:

str

property y_dpi: str#

Get the Y DPI (dots per inch) of the screen.

Type:

str

class besser.BUML.metamodel.gui.graphical_ui.ViewComponent(name: str, description: str, visibility: str = 'public')[source]#

Bases: ViewElement

Represents a view component that extends a generic ViewElement.

Parameters:
  • name (str) – The name of the view component.

  • description (str) – A brief description of the view component.

  • visibility (str, optional) – The visibility scope (default: “public”).

name#

The name of the view component.

Type:

str

description#

A brief description of the view component.

Type:

str

visibility#

The visibility scope of the component.

Type:

str

_abc_impl = <_abc._abc_data object>#
class besser.BUML.metamodel.gui.graphical_ui.ViewContainer(name: str, description: str, view_elements: set[ViewElement])[source]#

Bases: ViewElement

Represents a view container.

Parameters:
  • name (str) – The name of the view container.

  • description (str) – The description of the view container.

name#

The name of the view container.

Type:

str

description#

The description of the view container.

Type:

str

_abc_impl = <_abc._abc_data object>#
property view_elements: set[ViewElement]#

Get the set of view elements on the screen.

Type:

set[ViewComponent]

class besser.BUML.metamodel.gui.graphical_ui.ViewElement(name: str, description: str, visibility: str = 'public')[source]#

Bases: NamedElement

Represents a view element.

Parameters:
  • name (str) – The name of the view element.

  • description (str) – A brief description of the view element.

  • visibility (str, optional) – Visibility scope (default: “public”).

name#

The name of the view element.

Type:

str

description#

A brief description of the view element.

Type:

str

visibility#

Visibility scope (default: “public”).

Type:

str

_abc_impl = <_abc._abc_data object>#
property description: str#

Get the description of the view element.

Type:

str