ooodev.adapter.frame.controller_partial module

class ooodev.adapter.frame.controller_partial.ControllerPartial(component, interface=com.sun.star.frame.XController)[source]

Bases: ComponentPartial

Partial class for XController.

Parameters:
  • component (XController) –

  • interface (UnoInterface | None) –

__init__(component, interface=com.sun.star.frame.XController)[source]

Constructor

Parameters:
  • component (XController) – UNO Component that implements com.sun.star.frame.XController interface.

  • interface (UnoInterface, optional) – The interface to be validated. Defaults to XController.

Return type:

None

attach_frame(frame)[source]

Attaches the controller with its managing frame.

Parameters:

frame (XFrame) – The frame to be attached.

Return type:

None

attach_model(model)[source]

Attaches the controller to a new model.

Parameters:

model (XModel) – The model to be attached.

Return type:

None

get_frame()[source]

Gets access to owner frame of this controller.

Returns:

The owner frame of this controller.

Return type:

XFrame

get_model()[source]

Gets access to currently attached model.

Returns:

The currently attached model.

Return type:

XModel

get_view_data()[source]

Gets the view data.

Returns:

The view data.

Return type:

Any

restore_view_data(data)[source]

Restores the view data.

Parameters:

data (Any) – The view data to be restored.

Return type:

None

suspend(suspend)[source]

Is called to prepare the controller for closing the view.

Parameters:

suspend (bool) – True Force the controller to suspend his work, False Try to reactivate the controller.

Returns:

True If request was accepted and successfully finished; Otherwise, False.

Return type:

bool