get_portlet_list function

Contained in package wwpro_api_provider.

Call this function to return a list of portlets implemented by the provider.

The value of the p_security_level parameter indicates whether security checks will be performed to determine whether a portlet will be returned in the list. When a portlet repository refresh operation retrieves the master list of portlets implemented by the provider, the parameter p_security_level has a value of false. A value of false indicates to the provider that no portlet security check is required and that a master list of all of the portlets implemented by the provider must be returned.

The master list of portlets returned is used to populate the portlet repository for that provider. If the value of p_security_level is true, then it is up to the provider implementation to decide whether portlet security should be performed. If portlet security is implemented, the provider may return a different list of portlets depending on the currently logged on user.

Example: A provider serves portlets 'A', 'B', and 'C'. Because of different user privileges, in response to a wwpro_api_provider.get_portlet_list call, the provider might return 'A' and 'B' as portlets for one user and 'A' and 'C' as portlets for another user.

Notes:

  • The provider can use the methods in the context package wwctx_api to get the user logged in and to determine which portlets that user can see.

  • The provider can call the get_portlet function to return information about individual portlets and to populate the portlet table.

  • Because a provider can change the security of a given portlet at any time, callers of this API that store the returned portlet ID should be prepared to receive either a PORTLET_NOT_FOUND_EXCEPTION or a PORTLET_SECURITY_EXCEPTION when attempting to invoke the methods of the portlet.

function get_portlet_list

(

p_provider_id in integer

p_start_row in integer,

p_row_count in integer,

p_language in varchar2 default null,

p_security_level in boolean default TRUE,

p_type in integer default LIST_PORTLET

)

return portlet_table;

Any user can use this function.

Version: Oracle Portal 3.0.6.6.5 or later

Parameters:

p_provider_id

A unique identifier for the portlet provider.

Datatype: in integer

p_start_row

The number for the first row of the requested data table.

Datatype: in integer

p_row_count

The maximum number of rows to be returned.

Datatype: in integer

p_language

The national language name in which the strings are returned to the caller of this API.

Datatype: in varchar2
Default: null

p_security_
level

Indicates whether user-level security is in use.

Datatype: in boolean
Default: TRUE

p_type

Indicates the type of the list to be returned (portlet or component), as specified by a list constant.

Datatype: in integer
Default: LIST_PORTLET

Returns:

This function returns a list of portlets available from a provider.

Exceptions:

  • If invalid information about the provider is returned, PROVIDER_VALIDATION_EXCEPTION is raised.

  • If the provider cannot be located, PROVIDER_NOT_FOUND_EXCEPTION is raised.

  • If the provider cannot be executed, PROVIDER_EXECUTION_EXCEPTION is raised.

Example:

Calling code:

l_portlet_table := wwpro_api_provider.get_portlet_list

(

p_provider_id =>137,

p_start_row =>1,

p_row_count =>100,

p_language =>wwnls_api.AMERICAN,

p_security_level =>false

);

Provider call:

l_portlet_table := example_provider.get_portlet_list

(

p_provider_id => 137,

p_start_row =>1,

p_row_count =>100,

p_language =>wwnls_api.AMERICAN,

p_security_level => false

);

Related topics

The PL/SQL API Reference is part of the Portal Developer Kit on Portal Studio