trendminer.sdk.commons.folder module¶
- class trendminer.sdk.commons.folder.Folder(identifier: str, name: str, description: str, owner: User | str, last_modified: datetime)¶
Bases:
ABC
Work organizer folder.
- identifier¶
Unique identifier to the view object on the appliance
- Type:
uuid
- name¶
The view name
- Type:
str
- description¶
The view description
- Type:
str
- last_modified¶
View last modified time
- Type:
datetime
- abstract browse(included: list[str] | None = None, excluded: list[str] | None = None, folders_only: bool = False) list ¶
Browse the items in the current folder.
- Parameters:
included (list of str, optional) –
Included work organizer item types Options are:
”VIEW”, “AGGREGATION”, “VALUE_BASED_SEARCH”, “DIGITAL_STEP_SEARCH”, “SIMILARITY_SEARCH”, “AREA_SEARCH”, “TREND_HUB_2_VIEW”
excluded (list of str, optional) –
Excluded work organizer item types. Options are:
”VIEW”, “AGGREGATION”, “VALUE_BASED_SEARCH”, “DIGITAL_STEP_SEARCH”, “SIMILARITY_SEARCH”, “AREA_SEARCH”, “TREND_HUB_2_VIEW”
folders_only (bool, default False) – Whether to only search for subfolders. Ignores included and èxcluded`
- Returns:
list of objects within the folder
- Return type:
list
Example
# Browse the items in the directory folder = client.folder.get("sdk") folder.browse()
- abstract get(name: str, included: list[str] | None = None) list ¶
Get an object from folder by name.
- Parameters:
name (str) – The name of the work organizer item to retrieve
included (list of str, optional) –
The item types to search in to retrieve by name. Prevents errors if there are work organizer items of another type with the same name. Options are:
”VIEW”, “AGGREGATION”, “VALUE_BASED_SEARCH”, “DIGITAL_STEP_SEARCH”, “SIMILARITY_SEARCH”, “AREA_SEARCH”, “TREND_HUB_2_VIEW”
- Returns:
list of objects within the folder
- Return type:
list
Example
# Retriving the object from the folder name client.folder.get("sdk")
- abstract subfolders() list['Folder'] ¶
Retrieve subfolder in the current folder.
- Returns:
List of folder
- Return type:
list
Example
# Retrive subfolders in the current directory folder.subfolders()