Skip Headers

Oracle® Application Server PL/SQL Web Toolkit Reference 10g Release 3 (10.1.3) B25598-01 |
| Home | Solution Area | Contents | Index

Previous | Next |

# 8 The owa_text Package

The owa_text package contains subprograms used by owa_pattern for manipulating strings. They are externalized so you can use them directly.

## 8.1 Summary

owa_text.add2multi procedure - adds text to an existing multi_line type.

owa_text.multi_line data type - data type for holding large amounts of text.

owa_text.new_row_list - creates a new row_list.

owa_text.print_multi procedure - prints out the contents of a multi_list.

owa_text.print_row_list procedure - prints out the contents of a row_list.

owa_text.row_list data type - data type for holding data to be processed.

owa_text.stream2multi procedure - converts a varchar2 to a multi_line type.

owa_text.vc_arr data type - data type for holding large amounts of text.

## 8.2 owa_text.add2multi procedure

This procedure adds content to an existing owa_text.multi_line data type.

Table 8-1 owa_text.add2multi procedure

Properties | Definitions
--- | ---
Syntax: |
    owa_text.add2multi(
       stream         in       varchar2
       mline          in out   multi_line
       continue       in       boolean   DEFAULT TRUE);
Parameters: | stream - the text to add. mline - the owa_text.multi_line data type. The output of this parameter contains stream. continue - if TRUE, the procedure appends stream within the previous final row (assuming it is less than 32K). If FALSE, the procedure places stream in a new row.
Returns: | None.

## 8.3 owa_text.multi_line data type

This data type is a PL/SQL record that holds large amounts of text. The rows field, of type owa_text.vc_arr data type, contains the text data in the record.

Table 8-2 owa_text.multi_line data type

Properties | Definitions
--- | ---
Syntax: |
    type multi_line is record (
       rows           vc_arr,
       num_rows       integer,
       partial_row    boolean);
Returns: | Not applicable.

## 8.4 owa_text.new_row_list

This function or procedure creates a new owa_text.row_list data type. The function version uses no parameters and returns a new empty row_list. The procedure version creates the row_list data type as an output parameter.

Table 8-3 owa_text.new_row_list

Properties | Definitions
--- | ---
Syntax: |
    /* procedure */
    owa_text.new_row_list(rlist out row_list);
    /* function */
    owa_text.new_row_list return row_list;
Parameters: | rlist - this is an output parameter containing the new row_list data type.
Returns: | The function version returns the new row_list data type.

## 8.5 owa_text.print_multi procedure

This procedure uses htp.print, htp.prn to print the "rows" field of the owa_text.multi_line data type.

Table 8-4 owa_text.print_multi procedure

Properties | Definitions
--- | ---
Syntax: |
    owa_text.print_multi(mline in multi_line);
Parameters: | mline - the multi_line data type to print.
Returns: | The contents of the multi_line.

## 8.6 owa_text.print_row_list procedure

This procedure uses htp.print, htp.prn to print the "rows" field of the owa_text.row_list data type.

Table 8-5 owa_text.print_row_list procedure

Properties | Definitions
--- | ---
Syntax: |
    owa_text.print_row_list(rlist in row_list);
Parameters: | rlist - the row_list data type to print.
Returns: | The contents of the row_list.

## 8.7 owa_text.row_list data type

This is the data type for holding data to be processed.

Table 8-6 owa_text.row_list data type

Properties | Definitions
--- | ---
Syntax: |
    type row_list is record (
       rows           int_arr,
       num_rows       integer);
    int_arr is defined as:
    type int_arr is table of integer index by binary_integer;
Returns: | Not applicable.

## 8.8 owa_text.stream2multi procedure

This procedure converts a string to a multi_line data type.

Table 8-7 owa_text.stream2multi procedure

Properties | Definitions
--- | ---
Syntax: | owa_text.stream2multi( stream in varchar2 mline out multi_line);
Parameters: | stream - the string to convert. mline - the stream in owa_text.multi_line data type format.
Returns: | None.

## 8.9 owa_text.vc_arr data type

This is a component of the owa_text.multi_line data type.

Table 8-8 owa_text.vc_arr data type

Properties | Definitions
--- | ---
Syntax: | type vc_arr is table of varchar2(32767) index by binary_integer;
Returns: | Not applicable.