Search Results g_api_type




Overview

OKL_LA_STREAM_PUB is a public application programming interface (API) package body in the Oracle Lease and Finance Management (OKL) module of Oracle E-Business Suite. The package supports the Lease Administration (LA) subsystem by generating, allocating, and maintaining the financial streams associated with lease and loan contracts. A "stream" in this context is a scheduled series of cash flows — such as interest accruals, principal reductions, payments, or yields — that the lease accounting engine uses to amortize and account for a contract over its life.

The package is classified as a public (PUB) API, meaning its procedures are intended for external invocation by other application components, concurrent programs, forms, and custom extensions. The header revision ($Header: OKLPSGAB.pls 120.4 2006/04/20) indicates the package has been part of the OKL codebase since early releases and remains available in EBS 12.1.1 and 12.2.2.

The specific routine the user searched for, allocate_streams, is the entry point exposed at line 28 of the package body. It accepts the standard API calling convention (p_api_version, p_init_msg_list, x_return_status, x_msg_count, x_msg_data) plus a contract header identifier (p_chr_id). Its purpose is to allocate the generated financial streams across the correct contract lines and accounting periods, driving downstream lease accounting and revenue recognition. Note that allocate_streams appears in the package source but is not listed among the seven procedures documented in the ETRM 12.2.2 metadata, suggesting it is an internal or legacy routine referenced by sibling procedures.

Key Procedures and Functions

  • GENERATE_STREAMS — The primary driver that builds the financial stream records for a contract. It orchestrates the creation of cash-flow schedules consumed by lease accounting processes.
  • UPDATE_CONTRACT_YIELDS — Recalculates and updates the yield (effective interest rate) figures associated with a contract, ensuring streams reflect the current contractual terms.
  • EXTRACT_PARAMS_LEASE — Extracts lease-specific parameters required to build or refresh lease streams, isolating lease attributes from the general contract record.
  • EXTRACT_PARAMS_LOAN — Parallel routine that extracts loan-specific parameters for loan contracts, which follow different amortization rules than leases.
  • GEN_INTR_EXTR_STREAM — Generates the interest and extra (residual or supplemental) streams that supplement the primary payment schedule.
  • EXTRACT_PARAMS_LOAN_PAYDOWN — Extracts parameters governing paydown (principal reduction) events on loan contracts.
  • EXTRACT_PARAMS_LOAN_REAMORT — Extracts the parameters needed when a loan must be re-amortized, such as after a rate change or partial prepayment.

Tables Accessed

The only table directly documented in the ETRM metadata is OKC_K_HEADERS_B, accessed through an APPS synonym. This is the core Contracts (OKC) header table holding the contract's primary attributes — contract number, dates, currency, and status. The package reads this table to resolve the contract context before stream generation, and the OKL stream tables (OKL_LA_STREAM_*) are populated by its procedures. The package is referenced by ten other packages, confirming its central role in the lease accounting flow.

Usage Notes

OKL_LA_STREAM_PUB is normally invoked indirectly by lease accounting concurrent programs and by the contract maintenance forms during contract booking, amendment, or rebooking. Developers writing custom extensions should call GENERATE_STREAMS rather than allocate_streams, since the latter is not part of the documented public interface in 12.2.2. As with all OKL public APIs, callers must pass OKL_API.G_FALSE or G_TRUE to p_init_msg_list, inspect x_return_status against OKL_API.G_RET_STS_SUCCESS, and call OKL_API.GET_MESSAGE_COUNT/GET_MESSAGE to retrieve error text. Exceptions raised inside the package use the G_EXCEPTION_HALT_VALIDATION and G_EXCEPTION_STOP_VALIDATION control-flow markers.