guillotina.content
¶
-
class
guillotina.content.
Resource
(id=None)¶ Base resource object class
-
acl
¶ Access control list stores security information on the object
Return type: dict
-
add_behavior
(iface)¶ We need to apply the marker interface.
value: Interface to add
Return type: None
-
remove_behavior
(iface)¶ We need to apply the marker interface.
value: Interface to add
Return type: None
-
uuid
¶ The unique id of the content object
-
-
class
guillotina.content.
Item
(id=None)¶ Basic item content type. Inherits from Resource
-
class
guillotina.content.
Folder
(id=None)¶ Basic folder content type. Inherits from Resource but provides interface to work with contained objects asynchronously.
-
async_contains
(key)¶ Asynchronously check if key exists inside this folder
Parameters: key ( str
) – key of child object to checkReturn type: bool
-
async_del
(key)¶ Asynchronously delete object in the folder
Parameters: key ( str
) – key of child objec to deleteReturn type: None
-
async_get
(key, default=None, suppress_events=False)¶ Asynchronously get an object inside this folder
Parameters: key ( str
) – key of child object to getReturn type: Optional
[guillotina.db.orm.interfaces.IBaseObject]
-
async_items
(suppress_events=False)¶ Asynchronously iterate through contents of folder
Return type: Asynciterator
[Tuple
[str
,Resource
]]
-
async_keys
()¶ Asynchronously get the sub object keys in this folder
Return type: List
[str
]
-
async_len
()¶ Asynchronously calculate the len of the folder
Return type: int
-
async_multi_get
(keys, default=None, suppress_events=False)¶ Asynchronously get an multiple objects inside this folder
Parameters: keys ( List
[str
]) – keys of child objects to getReturn type: Asynciterator
[guillotina.db.orm.interfaces.IBaseObject]
-
-
class
guillotina.content.
Container
(id=None)¶
-
guillotina.content.
create_content_in_container
(parent, type_, id_, request=None, check_security=True, check_constraints=True, **kw)¶ Utility to create a content.
This method is the one to use to create content. id_ can be None
Parameters: - parent (
Folder
) – where to create content inside of - type – content type to create
- id – id to give content in parent object
- request (
Optional
[guillotina.interfaces.misc.IRequest]) – <optional> - check_security (
bool
) – be able to disable security checks
Return type: - parent (
-
guillotina.content.
get_all_possible_schemas_for_type
(type_name)¶ Return type: List
[zope.interface.Interface]
-
guillotina.content.
iter_schemata
(obj)¶ Return type: Iterator
[zope.interface.Interface]
-
guillotina.content.
move
(context, destination=None, new_id=None, check_permission=True)¶ Return type: None
-
guillotina.content.
duplicate
(context, destination=None, new_id=None, check_permission=True, reset_acl=False)¶ Return type: guillotina.interfaces.content.IResource