EgretDoc
Back to Home
Location:system/protocol.fastcgi

Module

Module documentation.

moduleprotocol.fastcgi

Classes

Classes and inheritance.

Functions

Free functions and class methods.

functionprotocol.fastcgi::version_1
Signaturefunc version_1() -> Int
func version_1() -> Int {
    return 1;
}
@briefProvides the system library operation `version_1`.
@detailsExecutes the `version_1` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::begin_request_type
Signaturefunc begin_request_type() -> Int
func begin_request_type() -> Int {
    return 1;
}
@briefProvides the system library operation `begin_request_type`.
@detailsExecutes the `begin_request_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::abort_request_type
Signaturefunc abort_request_type() -> Int
func abort_request_type() -> Int {
    return 2;
}
@briefProvides the system library operation `abort_request_type`.
@detailsExecutes the `abort_request_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::end_request_type
Signaturefunc end_request_type() -> Int
func end_request_type() -> Int {
    return 3;
}
@briefProvides the system library operation `end_request_type`.
@detailsExecutes the `end_request_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::params_type
Signaturefunc params_type() -> Int
func params_type() -> Int {
    return 4;
}
@briefProvides the system library operation `params_type`.
@detailsExecutes the `params_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::stdin_type
Signaturefunc stdin_type() -> Int
func stdin_type() -> Int {
    return 5;
}
@briefProvides the system library operation `stdin_type`.
@detailsExecutes the `stdin_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::stdout_type
Signaturefunc stdout_type() -> Int
func stdout_type() -> Int {
    return 6;
}
@briefProvides the system library operation `stdout_type`.
@detailsExecutes the `stdout_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::stderr_type
Signaturefunc stderr_type() -> Int
func stderr_type() -> Int {
    return 7;
}
@briefProvides the system library operation `stderr_type`.
@detailsExecutes the `stderr_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::data_type
Signaturefunc data_type() -> Int
func data_type() -> Int {
    return 8;
}
@briefProvides the system library operation `data_type`.
@detailsExecutes the `data_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::get_values_type
Signaturefunc get_values_type() -> Int
func get_values_type() -> Int {
    return 9;
}
@briefReads the state or data for `get_values_type`.
@detailsExecutes the `get_values_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::get_values_result_type
Signaturefunc get_values_result_type() -> Int
func get_values_result_type() -> Int {
    return 10;
}
@briefReads the state or data for `get_values_result_type`.
@detailsExecutes the `get_values_result_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::unknown_type
Signaturefunc unknown_type() -> Int
func unknown_type() -> Int {
    return 11;
}
@briefProvides the system library operation `unknown_type`.
@detailsExecutes the `unknown_type` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::responder_role
Signaturefunc responder_role() -> Int
func responder_role() -> Int {
    return 1;
}
@briefProvides the system library operation `responder_role`.
@detailsExecutes the `responder_role` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::authorizer_role
Signaturefunc authorizer_role() -> Int
func authorizer_role() -> Int {
    return 2;
}
@briefProvides the system library operation `authorizer_role`.
@detailsExecutes the `authorizer_role` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::filter_role
Signaturefunc filter_role() -> Int
func filter_role() -> Int {
    return 3;
}
@briefProvides the system library operation `filter_role`.
@detailsExecutes the `filter_role` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::request_complete
Signaturefunc request_complete() -> Int
func request_complete() -> Int {
    return 0;
}
@briefProvides the system library operation `request_complete`.
@detailsExecutes the `request_complete` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::cant_mpx_conn
Signaturefunc cant_mpx_conn() -> Int
func cant_mpx_conn() -> Int {
    return 1;
}
@briefProvides the system library operation `cant_mpx_conn`.
@detailsExecutes the `cant_mpx_conn` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::overloaded
Signaturefunc overloaded() -> Int
func overloaded() -> Int {
    return 2;
}
@briefProvides the system library operation `overloaded`.
@detailsExecutes the `overloaded` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::unknown_role
Signaturefunc unknown_role() -> Int
func unknown_role() -> Int {
    return 3;
}
@briefProvides the system library operation `unknown_role`.
@detailsExecutes the `unknown_role` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::default_request_id
Signaturefunc default_request_id() -> Int
func default_request_id() -> Int {
    return 1;
}
@briefProvides the system library operation `default_request_id`.
@detailsExecutes the `default_request_id` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::default_timeout_ms
Signaturefunc default_timeout_ms() -> Int
func default_timeout_ms() -> Int {
    return 10000;
}
@briefProvides the system library operation `default_timeout_ms`.
@detailsExecutes the `default_timeout_ms` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::max_content_len
Signaturefunc max_content_len() -> Int
func max_content_len() -> Int {
    return 65535;
}
@briefProvides the system library operation `max_content_len`.
@detailsExecutes the `max_content_len` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::byte
Signaturefunc byte(code: Int) -> String
func byte(code: Int) -> String {
    return encoding.byte_from_code(code & 255);
}
@briefProvides the system library operation `byte`.
@detailsExecutes the `byte` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • codeNumeric status, error, signal, opcode, or platform code handled by this API.
@returnReturns the operation result as `String`.
functionprotocol.fastcgi::byte_at
Signaturefunc byte_at(s: String, idx: Int) -> Int
func byte_at(s: String, idx: Int) -> Int {
    if idx < 0 || idx >= std.len(s) {
        return 0;
@briefProvides the system library operation `byte_at`.
@detailsExecutes the `byte_at` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • sInput string.
  • idxZero-based index.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::u16_be
Signaturefunc u16_be(v: Int) -> String
func u16_be(v: Int) -> String {
    return byte((v >> 8) & 255) + byte(v & 255);
}
@briefProvides the system library operation `u16_be`.
@detailsExecutes the `u16_be` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • vValue argument consumed, stored, encoded, compared, or forwarded by this API.
@returnReturns the operation result as `String`.
functionprotocol.fastcgi::u32_be
Signaturefunc u32_be(v: Int) -> String
func u32_be(v: Int) -> String {
    return byte((v >> 24) & 255) + byte((v >> 16) & 255) + byte((v >> 8) & 255) + byte(v & 255);
}
@briefProvides the system library operation `u32_be`.
@detailsExecutes the `u32_be` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • vValue argument consumed, stored, encoded, compared, or forwarded by this API.
@returnReturns the operation result as `String`.
functionprotocol.fastcgi::read_u16_be
Signaturefunc read_u16_be(s: String, off: Int) -> Int
func read_u16_be(s: String, off: Int) -> Int {
    return (byte_at(s, off) << 8) | byte_at(s, off + 1);
}
@briefReads data with `read_u16_be`.
@detailsExecutes the `read_u16_be` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • sInput string.
  • offZero-based byte offset or element offset at which the operation starts.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::read_u32_be
Signaturefunc read_u32_be(s: String, off: Int) -> Int
func read_u32_be(s: String, off: Int) -> Int {
    return (byte_at(s, off) << 24) | (byte_at(s, off + 1) << 16) | (byte_at(s, off + 2) << 8) | byte_at(s, off + 3);
}
@briefReads data with `read_u32_be`.
@detailsExecutes the `read_u32_be` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • sInput string.
  • offZero-based byte offset or element offset at which the operation starts.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::encode_len
Signaturefunc encode_len(n: Int) -> String
func encode_len(n: Int) -> String {
    if n < 0 {
        return "";
@briefEncodes input data with `encode_len`.
@detailsExecutes the `encode_len` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • nCount, size, or limit value.
@returnReturns the operation result as `String`.
functionprotocol.fastcgi::make_record
Signaturefunc make_record(record_type: Int, request_id: Int, content: String) -> String
func make_record(record_type: Int, request_id: Int, content: String) -> String {
    let n = std.len(content);
    let header = byte(version_1())
@briefProvides the system library operation `make_record`.
@detailsExecutes the `make_record` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • record_typeFastCGI or protocol record type value encoded into the frame header.
  • request_idProtocol request identifier used to correlate frames, commands, or responses.
  • contentContent bytes or text used as a message, file body, or protocol payload.
@returnReturns the operation result as `String`.
functionprotocol.fastcgi::make_begin_request
Signaturefunc make_begin_request(request_id: Int, role: Int, keep_conn: Bool) -> String
func make_begin_request(request_id: Int, role: Int, keep_conn: Bool) -> String {
    let flags = 0;
    if keep_conn {
@briefProvides the system library operation `make_begin_request`.
@detailsExecutes the `make_begin_request` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • request_idProtocol request identifier used to correlate frames, commands, or responses.
  • roleServer role, user role, or protocol role selected by the operation.
  • keep_connWhether the connection should remain open after the request completes.
@returnReturns the operation result as `String`.
functionprotocol.fastcgi::make_empty_record
Signaturefunc make_empty_record(record_type: Int, request_id: Int) -> String
func make_empty_record(record_type: Int, request_id: Int) -> String {
    return make_record(record_type, request_id, "");
}
@briefProvides the system library operation `make_empty_record`.
@detailsExecutes the `make_empty_record` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • record_typeFastCGI or protocol record type value encoded into the frame header.
  • request_idProtocol request identifier used to correlate frames, commands, or responses.
@returnReturns the operation result as `String`.
functionprotocol.fastcgi::chunk_len
Signaturefunc chunk_len(total_len: Int, off: Int) -> Int
func chunk_len(total_len: Int, off: Int) -> Int {
    let take = total_len - off;
    if take > max_content_len() {
@briefProvides the system library operation `chunk_len`.
@detailsExecutes the `chunk_len` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • total_lenSize or length value that limits how much data the operation processes.
  • offZero-based byte offset or element offset at which the operation starts.
@returnReturns the operation result as `Int`.
functionprotocol.fastcgi::encode_params
Signaturefunc encode_params(params: collections.Map<String, String>) -> String
func encode_params(params: collections.Map<String, String>) -> String {
    let keys = params.keys();
    let out = "";
@briefEncodes input data with `encode_params`.
@detailsExecutes the `encode_params` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • paramsName/value parameter map encoded into the request or protocol message.
@returnReturns the operation result as `String`.
functionprotocol.fastcgi::make_params
Signaturefunc make_params(script_filename: String, request_method: String, query_string: String, content_type: String, content_length: Int) -> collections.Map<String, String>
func make_params(script_filename: String, request_method: String, query_string: String, content_type: String, content_length: Int) -> collections.Map<String, String> {
    let params = new collections.Map<String, String>();
    _ = params.set("GATEWAY_INTERFACE", "CGI/1.1");
@briefProvides the system library operation `make_params`.
@detailsExecutes the `make_params` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
  • script_filenameFilesystem path of the script file executed by the FastCGI backend.
  • request_methodHTTP method name associated with the FastCGI or HTTP request.
  • query_stringRaw query string component included in a CGI, HTTP, or URL request.
  • content_typeMIME content type associated with the request or response body.
  • content_lengthSize or length value that limits how much data the operation processes.
@returnReturns the operation result as `collections.Map<String, String>`.

Variables

Class fields (var).