AbstractPageManager

page/manager/AbstractPageManager~ AbstractPageManager

Page manager for controller.

Constructor

new AbstractPageManager(pageFactory, pageRenderer, pageStateManager)

Source:
Initializes the page manager.
Parameters:
Name Type Description
pageFactory PageFactory Factory used by the page manager to create instances of the controller for the current route, and decorate the controllers and page state managers.
pageRenderer PageRenderer The current renderer of the page.
pageStateManager PageStateManager The current page state manager.

Members

(protected) _managedPage :Object

Source:
Details of the currently managed page.
Type:
  • Object

(protected) _pageFactory :PageFactory

Source:
Factory used by the page manager to create instances of the controller for the current route, and decorate the controllers and page state managers.
Type:
  • PageFactory

(protected) _pageRenderer :PageRenderer

Source:
The current renderer of the page.
Type:
  • PageRenderer

(protected) _pageStateManager :PageStateManager

Source:
The current page state manager.
Type:
  • PageStateManager

Methods

(protected) _activateController()

Source:
Activate managed instance of controller.

(protected) _activateExtensions()

Source:
Activate extensions for managed instance of controller.

(protected) _activatePageSource()

Source:
Activate page source so call activate method on controller and his extensions.

_clearComponentState(options)

Source:
The method clear state on current renderred component to DOM.
Parameters:
Name Type Description
options Object The current route options.

(protected) _clearManagedPageValue()

Source:
Clear value from managed page.

(protected) _deactivateController()

Source:
Deactivate last managed instance of controller only If controller was activated.

(protected) _deactivateExtensions()

Source:
Deactivate extensions for last managed instance of controller only if they were activated.

(protected) _deactivatePageSource()

Source:
Deactivate page source so call deactivate method on controller and his extensions.

(protected) _destroyController()

Source:
Destroy last managed instance of controller.

(protected) _destroyExtensions()

Source:
Destroy extensions for last managed instance of controller.

(protected) _destroyPageSource()

Source:
Destroy page source so call destroy method on controller and his extensions.

(protected) _getLoadedControllerState() → {Object.<string, (Promise.<*>|*)>}

Source:
Load controller state from managed instance of controller.
Returns:
Type
Object.<string, (Promise.<*>|*)>

(protected) _getLoadedExtensionsState() → {Object.<string, (Promise.<*>|*)>}

Source:
Load extensions state from managed instance of controller.
Returns:
Type
Object.<string, (Promise.<*>|*)>

(protected) _getUpdatedControllerState() → {Object.<string, (Promise.<*>|*)>}

Source:
Return updated controller state for current page controller.
Returns:
Type
Object.<string, (Promise.<*>|*)>

(protected) _getUpdatedExtensionsState() → {Object.<string, (Promise|*)>}

Source:
Return updated extensions state for current page controller.
Returns:
Type
Object.<string, (Promise|*)>

(protected) _hasOnlyUpdate(controller, view, options) → {boolean}

Source:
Return true if manager has to update last managed controller and view.
Parameters:
Name Type Description
controller string | function
view string | function
options Object
Returns:
Type
boolean

(protected) _initController()

Source:
Initializes managed instance of controller with the provided parameters.

(protected) _initExtensions()

Source:
Initialize extensions for managed instance of controller with the provided parameters.

(protected) _initPageSource()

Source:
Initialize page source so call init method on controller and his extensions.

(protected) _loadPageSource() → {Object.<string, (Promise.<*>|*)>}

Source:
Load page source so call load method on controller and his extensions. Merge loaded state and render it.
Returns:
Type
Object.<string, (Promise.<*>|*)>

_onChangeStateHandler(state)

Source:
On change event handler set state to view.
Parameters:
Name Type Description
state Object.<string, *>

(protected) _postManage(options)

Source:
Make defined instruction for current page options after that changed page.
Parameters:
Name Type Description
options Object

(protected) _preManage(options)

Source:
Make defined instruction as scroll for current page options before than change page.
Parameters:
Name Type Description
options Object

_setRestrictedPageStateManager(extension, extensionState)

Source:
Set page state manager to extension which has restricted rights to set global state.
Parameters:
Name Type Description
extension ima.extension.Extension
extensionState Object.<string, *>

(protected) _storeManagedPageValue(controller, view, options, params, controllerInstance, decoratedController, viewInstance)

Source:
Parameters:
Name Type Description
controller string | function
view string | function
options Object
params Object.<string, string> The route parameters.
controllerInstance AbstractController
decoratedController ControllerDecorator
viewInstance React.Component

(protected) _updatePageSource() → {Promise.<{status: number, content: ?string}>}

Source:
Update page source so call update method on controller and his extensions. Merge updated state and render it.
Returns:
Type
Promise.<{status: number, content: ?string}>

destroy()

Source:

init()

Source:

manage()

Source:

(abstract) scrollTo()

Source: