Use the BIThinSession JSP tag on every page to store initialization information
for the following objects: BISession
, PersistenceManager
,
Connection
, MetadataManager
, and QueryManager
.
The scripting variable BIThinSession
is defined by the BIThinSession tag. You might want to reference this variable to retrieve BI Beans state information or to provide support for a login page. This topic provides information about performing these tasks.
id -- (Required) A unique identifier for this tag.
configuration -- (Required) Full path for the configuration file that contains the application settings.
scope -- Determines the accessibility and lifetime of the object; select one of the following values: Session, which is the default value, or Application.
stateful -- Indicates whether state information is to be stored for each tag.
charset -- Specifies character set encoding; defaults to
the CharacterEncoding
value that is found in the HttpServletResponse
object. To view valid values, right-click your project in the System - Navigator
and choose Project Settings and then Compiler.
The Character Encoding box contains a drop-down list of the valid values.
As you insert additional JSP tags on a page, JDeveloper inserts a definition for each tag automatically within the code for the BIThinSession tag. The following methods in the oracle.dss.addins.BIThinSession
class are available to allow you to retrieve state information that is related to the beans that are defined in a BIThinSession tag:
getState
method -- Retrieves state information in a java.util.Dictionary
object for all the beans that are defined in the BIThinSession tag. (This method does not take a parameter.)
getStateString
method -- Retrieves state information in a String
for all the beans that are defined in the BIThinSession tag. (This method does not take a parameter.)
By default, the BI User property, which is defined in the BI Beans configuration file, is provided to the BIThinSession object after the application starts but before the application needs this information to connect to the BI Beans Catalog.
To support a login page for an application that uses BI Beans JSP tags, you must provide for dynamic specification of the BI User before the application establishes a Catalog connection. To provide user information (for user "BIBEANS") to the BIThinSession tag (bithinsession1), write the following code:
<orabi:BIThinSession id = "BIThinSession1", . . . /> <% bithinsession1.setBIUser (new BIUser( "BIBEANS" )); %> <!-- Other code that is not included in this example --> </orabi:BIThinSession>
Important: Insert this line of code immediately after the start of the BIThinSession tag (that is, before the definitions of other tags).