Class actuate.RequestOptions
Description
The request options that loginServlet requires to authenticate requests. RequestOptions is used by other classes to provide authentication information. It also adds any customized options to the request URL.
Constructor
Syntax
actuate.RequestOptions( actuate.RequestOptions requestOptions)
Constructs a new RequestOptions object.
Parameters
requestOptions
actuate.RequestOptions object. Optional. Provides request option settings to copy into this RequestOptions object
Function summary
Table 4-46 lists actuate.RequestOptions functions.
actuate.RequestOptions.getIServerUrl
Syntax
string RequestOptions.getIserverurl( )
Returns the BIRT iServer URL.
Returns
String. The URL for BIRT iServer.
Example
To retrieve the BIRT iServer URL from the RequestOptions object reqOpts, use code similar to the following:
var iServerUrl = reqOpts.getIServerUrl( );
actuate.RequestOptions.getLocale
Syntax
string RequestOptions.getLocale( )
Returns the current locale or null if no locale is set.
Returns
String. The locale value; null for default.
Example
This example pops up an alert box if the locale value is set to the default:
var locale = reqOpts.getLocale( );
if (locale == null){
  alert("Locale value is default");
}
actuate.RequestOptions.getRepositoryType
Syntax
string RequestOptions.getRepositoryType( )
Returns the repository type: enterprise or workgroup.
Returns
String. Valid repository type values are enterprise or workgroup.
Example
To retrieve the repository type for the RequestOptions object reqOpts, use code similar to the following:
var repositorytype = reqOpts.getRepositoryType( );
actuate.RequestOptions.getVolume
Syntax
string RequestOptions.getVolume( )
Returns the Encyclopedia volume.
Returns
String. The name of the Encyclopedia volume.
Example
To retrieve the Encyclopedia volume for the RequestOptions object reqOpts, use code similar to the following:
var encyVol = reqOpts.getVolume( );
actuate.RequestOptions.getVolumeProfile
Syntax
string RequestOptions.getVolumeProfile( )
Returns the volume profile by name. Valid volume profile names are listed in the service’s WEB-INF\volumeProfile.xml file.
Returns
String. The volume profile.
Example
To retrieve the volume profile for the RequestOptions object reqOpts, use code similar to the following:
var volProfile = reqOpts.getVolumeProfile( );
actuate.RequestOptions.setCustomParameters
Syntax
void RequestOptions.setCustomParameters(object parameters)
Returns a custom parameter in the request URL.
Parameters
parameters
Object. An associative array of name:value pairs for URL parameters.
Example
To add "&myParam=myValue" in a request URL derived from RequestOptions object, use code similar to the following:
MyRequestOptions.setCustomParameters({myParam: "myValue"});
actuate.RequestOptions.setIServerUrl
Syntax
void RequestOptions.setIServerUrl(string iServerUrl)
Sets the BIRT iServer URL.
Parameters
Iserverurl
String. The BIRT iServer URL value.
Example
This example sets the BIRT iServer URL for the reqOpts RequestOptions object:
reqOpts.setIserverUrl("http://localhost:8700");
actuate.RequestOptions.setLocale
Syntax
void RequestOptions.setLocale(string Locale)
Sets the locale.
Parameters
Locale
String. Optional. The locale value. Null indicates the default locale.
Example
This example resets the locale for the reqOpts RequestOptions object to the default:
reqOpts.setLocale( );
actuate.RequestOptions.setRepositoryType
Syntax
void RequestOptions.setRepositoryType(string repositoryType)
Sets the repository type, either enterprise or workgroup.
Parameters
repositoryType
String. Valid repository type values are enterprise or standalone, as designated by the Actuate web application service with which to connect. Use the following constants:
*
*
Example
This example sets the repository to workgroup:
reqOpts.setRepositoryType(actuate.RequestOptions.REPOSITORY_STANDALONE);
actuate.RequestOptions.setVolume
Syntax
void RequestOptions.setVolume(string volume)
Sets the Encyclopedia volume.
Parameters
volume
String. The Encyclopedia volume.
Example
To set the Encyclopedia volume to marcom if the RequestOptions object reqOpts volume is null, use code similar to the following:
if( reqOpts.getVolume( ) == null){
  reqOpts.setVolume("marcom");
}
actuate.RequestOptions.setVolumeProfile
Syntax
void RequestOptions.setVolumeProfile(string volumeProfile)
Sets the volume profile to use. Valid volume profile names are listed in the service’s WEB-INF\volumeProfile.xml file.
Parameters
volumeProfile
String. The volume profile.
Example
To set the volume profile to myServer if the RequestOptions object reqOpts volume profile is null, use code similar to the following:
if( reqOpts.getVolume( ) == null){
  reqOpts.setVolumeProvile("myServer");
}

Additional Links:

Copyright Actuate Corporation 2012