Base class for all apps
flagged: bool
name: str
style: TypingStyle
tags: TagList
technical_info: TechnicalInfoDict
uid: str
Constructor, please do not overwrite this method, use the init method instead Leave the constructor without parameters.
List
MessageDispatcher
Add a resource to the AppResource.
Any
bool
- True
Add technical information on the resource. Technical info are useful to set additional information on the resource.
TechnicalInfo
You can redefine this method to define custom logic to check this resource. If there is a problem with the resource, return a string that define the error, otherwise return None This method is called on output resources of a task. If there is an error returned, the task will be set to error and next proceses will not be run. It is also call when uploading a resource (usually for files or folder), if there is an error returned, the resource will not be uploaded
Optional
Clone the resource to create a new instance with a new id. It copies the RFields.
ResourceType
Any
int
You can redefine this method to set a name of the resource. When saving the resource the name will be saved automatically This can be useful to distinguish this resource from another one or to search for the resource
str
Get the default style of the resource
TypingStyle
Get the main app file name that will be used to run the app. This file must be in the app folder.
str
Get the id of the resource model in the database. It is provided by the system for input resources of a task.
str
Get the name of the resource or the default name if the name is None
str
Get the parameters that will be passed to the app.
dict
Return the first resource with the given name
str
gws_core.resource.resource.Resource | None
Return the resource model ids of the sub resources
Set
Return the resource models of the sub resources list
List[ResourceModel]
Return the sub resources as a list
List
Return the sub resources as a set
Set
Get the technical information of the resource
str
TechnicalInfo
Return true if the resource with the given id is in the resource list
str
bool
Any
int
This can be overwritten to perform custom initialization of the resource. This method is called after the init (constructor) of the resource. The values of RFields are set when this method is called.
Initialize the app instance with the shell proxy. This method is used to create the app instance that will be used to run the app.
ShellProxy
str
str
bool
AppInstance
Return true if the resource list is empty
bool
Return True if the app is executed in a virtual environment.
bool
Replace current resources by the resources in the dict
Dict
ResourceOrigin
Scenario
TaskModel
str
List[ResourceModel]
Set the app config that will be used to generate the app. The AppResource stores the app config typing name to find the app config code. As long as the app config typing name does not change, the app config will be working.
If the app config code is updated, the AppResource will automatically use the updated the app config code.
AppConfig
Set the code that will be executed in the app environment. This code is executed before the app is loaded and can be used to load environment variables.
BaseEnvShell
Set the name of the resource. You can override this method to force a format for the name of the resource.
Optional
Set a parameter that will be passed to the app into the 'params' variable.
str
Any
Set the parameters that will be passed to the app into the 'params' variable.
dict
Set if the app requires the user to be authenticated. By default it requires authentication.
bool
Set the folder that contains the app code.
This is only recommended if you want to force the version of the app in this Resource and avoid automatic updates. Otherwise use the set_app_config method. The folder is copied and stored as a sub resource of the AppResource. The app need to be re-generated to update the code.
str
Any
bool
- False
Return the resources as a list
List
Returns the name of the class
bool
- False
bool
- False
bool
- False
str
Copy the style of the resource with the possibility to override some properties. Useful when settings the style for a task based on the resource style.
str
TypingIconType
str
TypingIconColor
TypingStyle
Returns the full name of the class
bool
- False
bool
- False
str
str
Version
Get the human name of the object
str
Get the short description of the object
str
Get the style of the object
TypingStyle
Get the typing name of the object Ex: 'RESOURCE.gws_core.Table'
str
TypingNameObj
Get all the classes that inherit this class
List