+
Point of view
All features
class CGI
Summary
This class provides a simple executable framework for CGI implementation.
It is meant to be instanciated once, used in a one-shot process that dies quickly. Hence the light memory management.
See RFC 3875
Direct parents
Insert list: CGI_IO, DISPOSABLE, SINGLETON
Class invariant
Overview
Creation features
{CGI_HANDLER}
Features
{ANY}
{CGI_HANDLER}
{CGI_HANDLER, CGI_RESPONSE}
{}
{}
  • dispose
    Action to be executed just before garbage collection reclaims an object.
{ANY}
  • is_equal (other: CGI): BOOLEAN
    Is other attached to an object considered equal to current object?
{}
{ANY}
{}
run
effective procedure
{ANY}
require ensure
need_run: BOOLEAN
effective function
{ANY}
need_reply: BOOLEAN
effective function
{ANY}
done: BOOLEAN
effective function
{ANY}
reply (response: CGI_RESPONSE)
effective procedure
require ensure
error: STRING
writable attribute
auth_type: CGI_AUTH_TYPE
effective function
ensure
  • Result = Void implies error /= Void
content_length: CGI_CONTENT_LENGTH
effective function
ensure
  • Result.error implies error /= Void
content_type: CGI_CONTENT_TYPE
effective function
ensure
  • Result /= Void and then Result.error /= Void implies error.is_equal(Result.error)
gateway_interface: CGI_GATEWAY_INTERFACE
effective function
ensure
  • Result.error /= Void implies error.is_equal(Result.error)
path_info: CGI_PATH_INFO
effective function
path_translated: CGI_PATH_TRANSLATED
effective function
query_string: CGI_QUERY_STRING
effective function
ensure
  • Result.error /= Void implies error.is_equal(Result.error)
remote_info: CGI_REMOTE_INFO
effective function
ensure
  • Result.error /= Void implies error.is_equal(Result.error)
request_method: CGI_REQUEST_METHOD
effective function
ensure
  • Result = Void implies error /= Void
script_name: CGI_SCRIPT_NAME
effective function
ensure
  • Result.error /= Void implies error.is_equal(Result.error)
server_info: CGI_SERVER_INFO
effective function
url: URL
effective function
header_pattern: REGULAR_EXPRESSION
once function
^[0-9A-Za-z-]+$
header (field: ABSTRACT_STRING): FIXED_STRING
effective function
require
make (a_handler: CGI_HANDLER)
effective procedure
{}
require
  • a_handler /= Void
ensure
meta_variable (var: STRING): STRING
effective function
{}
handler: CGI_HANDLER
writable attribute
{}
error_memory: STRING
is ""
constant attribute
{}
prepare_error
effective procedure
{}
state: INTEGER_8
writable attribute
{}
once function
{}
content_type_memory: CGI_CONTENT_TYPE
writable attribute
{}
path_info_memory: CGI_PATH_INFO
writable attribute
{}
path_translated_memory: CGI_PATH_TRANSLATED
writable attribute
{}
remote_info_memory: CGI_REMOTE_INFO
writable attribute
{}
request_method_memory: CGI_REQUEST_METHOD
writable attribute
{}
server_info_memory: CGI_SERVER_INFO
writable attribute
{}
url_memory: URL
writable attribute
{}
dispose
effective procedure
{}
Action to be executed just before garbage collection reclaims an object.
is_equal (other: CGI): BOOLEAN
effective function
{ANY}
Is other attached to an object considered equal to current object?
require
  • other /= Void
ensure
  • commutative: generating_type = other.generating_type implies Result = other.is_equal(Current)
is_real_singleton: BOOLEAN
effective function
{}
ensure
  • assertion_check_only: Result
singleton_memory_pool: HASHED_DICTIONARY[POINTER, STRING]
once function
{}
This pool is unique in the whole system.
A memory is kept for each singleton type (type, not class) in the system.
current_is_not_an_expanded_type: BOOLEAN
effective function
{}
Check that the dynamic type of the SINGLETON is not an expanded type.
output: OUTPUT_STREAM
effective function
{ANY}
set_output (a_output: OUTPUT_STREAM) assign output
effective procedure
{ANY}
require
  • a_output /= Void
ensure
output_memory: REFERENCE[OUTPUT_STREAM]
once function
{}