Confirmed users
216
edits
(→= handle presentation request: provide detail description) |
(→Receiving UA: separate request handling and connection monitoring) |
||
Line 57: | Line 57: | ||
# PresentationService observe incoming presentation request via "presentation-session-request" topic | # PresentationService observe incoming presentation request via "presentation-session-request" topic | ||
# create receiving browser context via nsIPresentationUIGlue and navigate to presentation URL | # create receiving browser context via nsIPresentationUIGlue and navigate to presentation URL | ||
## presented content should be loaded in a browser element with "mozpresentation" attribute set to the requested presentation URL | |||
# a (windowId, presentationId) mapping will be created at content side while document begins to load | # a (windowId, presentationId) mapping will be created at content side while document begins to load | ||
# | ## corresponding session info object will be removed if failed to load within time limit | ||
# In parallel, establish transport channel between controlling page and presented content | # In parallel, establish transport channel between controlling page and presented content | ||
# transport channel state | |||
==== monitor incoming connection ==== | |||
[[File:CoreService Flow monitor connection list.png|thumb|650px|sequence diagram of monitoring incoming connection on receiving UA]] | |||
* monitor incoming connection | |||
# register PresentationReceiver as a RespondingListener to PresentationService while navigator.presentation.receiver.connectionList is touched first time. | |||
# PresentationService will report the available presentationId via nsIPresentationRespondingListener::NotifySessionConnect. | |||
# corresponding PresentationConnection object will be created in connecting state and register it as a SessionListener to PresentationService. | |||
# transport channel state will be sent to presented content once PresentationConnection object is created | |||
## if fail to create transport channel, PresentationConnection state should be set to 'closed' | ## if fail to create transport channel, PresentationConnection state should be set to 'closed' |