Table of Contents Previous Section

Generating a Response

In the final phase of requst-response loop, the response page generates an HTTP response. Generally, the response contains a dynamically generated HTML page.

This is the basic sequence of events in generating a response:

  1. The WOWebScriptApplication object stores the values of all session and persistent variables. Subsequent changes to session and persistent variables will not be preserved in the next cycle of the request-response loop. For more information on how a WebObjects application manages state, see the chapter "Managing State."
  2. The WOWebScriptApplication object receives a willGenerateResponse:inContext: message.
  3. The response component receives a generateResponse:inContext: message. generateResponse:inContext: invokes the request component's willGenerateResponse:inContext: method, generates an HTTP response using the response component's HTML template, and then invokes the response component's didGenerateResponse:inContext: method.
  4. The WOWebScriptApplication object receives a didGenerateResponse:inContext: message.

Table of Contents Next Section