Top   Module   Use   Manual   Index 
 EXPORTING SERVICES | METHODS' SUMMARY | METHODS' DETAILS 

com :: sun :: star :: frame ::

interface XModel

Base Interface
com::sun::star::lang::XComponent

Description
represents a component which is created from an URL and arguments.

It is a representation of a resource in the sense that it was created/loaded from the resource. The arguments are passed to the loader to modify its behavior. An example for such an argument is "AsTemplate", which loads the resource as a template for a new document.

Models can be controlled by controller components, which are usually views of the model.

If there is at least one controller, there is by definition a current controller. And if that controller supports the interface XSelectionSupplier , it has a current selection too.



Known Services which Export this Interface

com::sun::star::sheet::SpreadsheetDocument a model component which consists of some settings and one or more spreadsheets.

Methods' Summary

attachResource informs a model about its resource description.
getURL
getArgs
connectController is called whenever a new controller is created for this model.
disconnectController is called whenever a new controller is created for this model.
lockControllers suspends some notifications to the controllers which are used for display updates.
unlockControllers resumes the notifications which were suspended by .
hasControllersLocked determines if there is at least one lock remaining.
getCurrentController
setCurrentController sets a registered controller as the current controller.
getCurrentSelection

Methods' Details

attachResource
 
boolean
attachResource(
[ in ] string aURL,
[ in ] sequence< com::sun::star::beans::PropertyValue > aArgs );

Description
informs a model about its resource description.
getURL
 
string
getURL();
Returns
the URL of the resource which is represented by this model.
See also
XStorable::getLocation
getArgs
 
sequence< com::sun::star::beans::PropertyValue >
getArgs();
Returns
the arguments with which the model was originally created or stored the last time.
connectController
 
[ oneway ] void
connectController(
[ in ] com::sun::star::frame::XController xController );

Description
is called whenever a new controller is created for this model.

The XComponent interface of the controller must be used to recognize when it is deleted.

See also
releaseController
disconnectController
 
[ oneway ] void
disconnectController(
[ in ] com::sun::star::frame::XController xController );

Description
is called whenever a new controller is created for this model.

The XComponent interface of the controller must be used to recognize when it is deleted.

See also
registerController
lockControllers
 
[ oneway ] void
lockControllers();
Description
suspends some notifications to the controllers which are used for display updates.

The calls to and may be nested and even overlapping, but they must be in pairs. While there is at least one lock remaining, some notifications for display updates are not broadcasted.

unlockControllers
 
[ oneway ] void
unlockControllers();
Description
resumes the notifications which were suspended by .

The calls to and may be nested and even overlapping, but they must be in pairs. While there is at least one lock remaining, some notifications for display updates are not broadcasted.

hasControllersLocked
 
boolean
hasControllersLocked();
Description
determines if there is at least one lock remaining.

While there is at least one lock remaining, some notifications for display updates are not broadcasted to the controllers.

getCurrentController
 
com::sun::star::frame::XController
getCurrentController();
Returns
the controller which currently controls this model.

If the controller which is active is a controller of this model, it will be returned. If not, the controller which was the last active of this model is returned. If no controller of this model ever was active, the controller first registered is returned. If no controller is registered for this model, NULL is returned.

setCurrentController
 
void
setCurrentController(
[ in ] com::sun::star::frame::XController xController )
raises ( com::sun::star::container::NoSuchElementException );

Description
sets a registered controller as the current controller.
getCurrentSelection
 
com::sun::star::uno::XInterface
getCurrentSelection();
Returns
the current selection in the current controller.

If there is no current controller, it returns NULL.


Top of Page