ooodev.adapter.frame.storable_partial module
- class ooodev.adapter.frame.storable_partial.StorablePartial(component, interface=com.sun.star.frame.XStorable)[source]
Bases:
object
Partial class for XStorable.
- Parameters:
component (XStorable) –
interface (UnoInterface | None) –
- __init__(component, interface=com.sun.star.frame.XStorable)[source]
Constructor
- Parameters:
component (XStorable) – UNO Component that implements
com.sun.star.frame.XStorable
interface.interface (UnoInterface, optional) – The interface to be validated. Defaults to
XStorable
.
- Return type:
None
- get_location()[source]
After XStorable.storeAsURL() it returns the URL the object was stored to.
- Return type:
str
- has_location()[source]
The object may know the location because it was loaded from there, or because it is stored there.
- Return type:
bool
- is_readonly()[source]
It is not possible to call XStorable.store() successfully when the data store is read-only.
- Return type:
bool
- store()[source]
Stores the data to the URL from which it was loaded. Only objects which know their locations can be stored.
- Raises:
com.sun.star.io.IOException –
IOException
- Return type:
None
- store_as_url(url, *args)[source]
Stores the object’s persistent data to a URL and makes this URL the new location of the object. This is the normal behavior for UI
save-as
feature. The change of the location makes it necessary to store the document in a format that the object can load. For this reason the implementation of XStorable.storeAsURL() will throw an exception if a pure export filter is used, it will accept only combined import/export filters. For such filters the method XStorable.storeToURL() must be used that does not change the location of the object.- Parameters:
url (str) – The URL to be stored.
*args (PropertyValue) – Additional parameters for storing process.
- Raises:
com.sun.star.io.IOException –
IOException
- Return type:
None
- store_to_url(url, *args)[source]
Stores the object’s persistent data to a URL and continues to be a representation of the old URL. This is the normal behavior for UI export feature. This method accepts all kinds of export filters, not only combined import/export filters because it implements an exporting capability, not a persistence capability.
- Parameters:
url (str) – The URL to be stored.
*args (PropertyValue) – Additional parameters for storing process.
- Raises:
com.sun.star.io.IOException –
IOException
- Return type:
None