Oracle Application Server Wireless Java API Reference
B10400-01

oracle.panama.rt
Interface Request

All Superinterfaces:
RequestParameterNames
All Known Implementing Classes:
oracle.panama.rt.common.AbstractConnection

public interface Request
extends RequestParameterNames

This interface represents the request objects in PTG Runtime.

Since:
Oracle9i Application Server Wireless Edition

Field Summary

 

Fields inherited from interface oracle.panama.rt.RequestParameterNames
BRAND_NAME, CALLBACK_LABEL, CALLBACK_URL, CHARACTER_ENCODING, CONNXN_ID, DEBUG, DEVICE_ID, EFFECTIVE_USER_NAME, FULL_CALLBACK_URL, GET_PAGE, GO_SESSION_HOME, LOCALE_PREFERENCE, LOGIN, LOGOFF, MODULE_STACK_SIZE, MS_XFORMER, PASSWORD, PATFOCUS, PATSELECTOR, REDIRECT, REFERER, REQUEST_LANDMARK, REQUEST_USER_PROFILE, SECTION, SERVICE_DESIGNER, SERVICE_OID, SERVICE_PATH, SESSION_HOME, SESSION_ID, SESSION_LANDMARK, SESSION_USER_PROFILE, SHORT_NAME, USER_NAME, VIRTUAL_URL, XFORMS_DOC_ID, XFORMS_EVENT_ID_PREFIX, XFORMS_RESERVED_PREFIX

 

Method Summary
 void addRequestListener(RequestListener listener)
          Add a listener for events from this request.
 void addRequestListeners(java.util.Vector listeners)
          Add a collection of listeners for events from request object.
 Response execute()
          Execute a newly created request.
 Arguments getArguments()
          Get the arguments containing all URL parameters and header attributes.
 java.lang.Object getAttribute(AttributeCategory category, java.lang.String name)
          Get the value of the named attribute in the chosen category
 java.util.Enumeration getAttributeNames(AttributeCategory category)
          Get an enumeration of all attribute names in a given category
 java.lang.String getAuthenticationType()
          Get the type of authentication used to identify the user.
 java.lang.String[] getCarriers()
           
 java.lang.String getCharacterEncoding()
          Get the language and locale used for character encoding
 Point getCurrentLocation()
          Get the location of the user using one of the following sources, 1.
 Device getDevice()
          Get the device model derived from the user agent type.
 DeviceAddress getDeviceAddress()
           
 java.lang.String getDeviceId()
          Get the device id,
 FileParameter getFileParameter(java.lang.String paramName)
          Get the value of a parameter from the "FileParameters" category
 java.util.Enumeration getFileParameterNames()
          Get the names of all file parameters
 FileParameter[] getFileParameterValues(java.lang.String paramName)
          Get the values of a parameter from the "FileParameters" category
 java.util.Enumeration getHeaderAttributes()
          Get the enumeration of attributes obtained from http header or equivalent source.
 java.util.Date getLocationAcquisitionTime()
          Get the time when the user location was acquired
 LocationMark getLocationMark()
          Get the landmark that identifies the location of the caller.
 java.lang.String getMobileId()
          Get the mobile id, which can be used for automatic location acquisition.
 java.lang.String getParameter(java.lang.String paramName)
          Get the value of a parameter from the "Parameters" category
 java.util.Enumeration getParameterNames()
          Get the names of all parameters
 java.lang.String[] getParameterValues(java.lang.String paramName)
          Get the values of a parameter from the "Parameters" category
 Profile getProfile()
          Get the user profile.
 java.lang.String getRemoteAddress()
          Get the IP address or other network address of the user agent.
 java.lang.String getRemoteAuthenticationType()
          Returns the name of the authentication scheme used to authenticate the user.
 java.lang.String getRemoteUser()
          Returns the name of the user making this request, if the user has been authenticated (say thru mod_sso), or null if the user has not been authenticated.
 java.lang.String getRequestedSessionId()
          Get the session id contained in the request.
 Response getResponse()
          Get the Response interface associated with this request.
 java.lang.String getScheme()
          Get the schema used for the request message.
 ServiceContext getServiceContext()
          Get the service context for the current request, current session, and requested service.
 java.lang.String getServiceHomeURL()
           
 long getServiceOid()
          Get the value of "PAoid" parameter which specifies the object id of the requested service.
 java.lang.String getServiceParentURL()
           
 java.lang.String getServicePath()
          Get the value of "PAservicepath" which specifies the path of the requested service in the repository.
 Session getSession()
          Get the session associated with the current request.
 java.lang.String getSubscriberId()
          Deprecated. use getMobileId instead
 java.lang.String getUserHomeURL()
           
 void invalidate()
          Invalidate the request and the associated service context and response objects.
 boolean isAutoLocated()
          Get the auto located (boolean) value.
 boolean isDebugOn()
          Test whether logging of debug information is requested.
 boolean isRequestedSessionIdValid()
          Test if the requested session id is valid.
 boolean isSecure()
          Verify whether the request is transmitted over a secure channel such HTTPS or SSL.
 boolean isValid()
          Test if the user is authenticated and session has been established.
 void removeAttribute(AttributeCategory category, java.lang.String name)
          Remove the named attribute from the given category
 void removeFileParameter(java.lang.String paramName)
          Remove the parameter from the "FileParameters" category
 void removeParameter(java.lang.String paramName)
          Remove the parameter from the "Parameters" category
 void removeRequestListener(RequestListener listener)
          Remove a listener for events from this request.
 void removeRequestListeners(java.util.Vector listeners)
          Remove a collection of listeners for events from request object.
 void setAttribute(AttributeCategory category, java.lang.String name, java.lang.Object value)
          Set the value of the named attribute in the chosen category
 void setAutoLocated(boolean autoLocated)
          Set the auto located (boolean) parameter.
 void setDebugOn(boolean value)
          Set the flag to request logging of debug information for the current request.
 void setFileParameter(java.lang.String paramName, FileParameter paramValue)
          Set the value of a named parameter in the "FileParameters" category
 void setLocationMark(LocationMark landmark)
          Set the landmark that identifies the location of the caller.
 void setParameter(java.lang.String paramName, java.lang.String paramValue)
          Set the value of a named parameter in the "Parameters" category
 void setProfile(Profile profile)
          Set the user profile.
 void setSenderAddress(DeliveryType deliveryType, java.lang.String address, java.lang.String[] carrierInfo)
          Sets the address of the sender
 void setUserAgent(java.lang.String userAgent)
          Set the type of the user agent.
 void terminateSession()
          Terminate the user's session and return a logon page.
 ServiceContext validate()
          Validate the request by authenticating the user and authorizing the service.

 

Method Detail

getAttribute

public java.lang.Object getAttribute(AttributeCategory category,
                                     java.lang.String name)
Get the value of the named attribute in the chosen category
Parameters:
category - the attribute category
name - the name of the attribute
Returns:
the value of the attribute

setAttribute

public void setAttribute(AttributeCategory category,
                         java.lang.String name,
                         java.lang.Object value)
Set the value of the named attribute in the chosen category
Parameters:
category - the attribute category
name - the name of the attribute
value - the value for named attribute

getAttributeNames

public java.util.Enumeration getAttributeNames(AttributeCategory category)
Get an enumeration of all attribute names in a given category
Parameters:
category - the attribute category
Returns:
an enumeration of Strings for attribute names

removeAttribute

public void removeAttribute(AttributeCategory category,
                            java.lang.String name)
Remove the named attribute from the given category
Parameters:
category - the attribute category
name - the name of the attribute

getParameterNames

public java.util.Enumeration getParameterNames()
Get the names of all parameters
Returns:
an enumeration of parameter names

getParameter

public java.lang.String getParameter(java.lang.String paramName)
Get the value of a parameter from the "Parameters" category
Parameters:
paramName - name of the parameter
Returns:
value of the named parameter

getParameterValues

public java.lang.String[] getParameterValues(java.lang.String paramName)
Get the values of a parameter from the "Parameters" category
Parameters:
paramName - name of the parameter
Returns:
a array containing values of the named parameter

setParameter

public void setParameter(java.lang.String paramName,
                         java.lang.String paramValue)
Set the value of a named parameter in the "Parameters" category
Parameters:
paramName - name of the parameter
paramValue - value of the parameter

removeParameter

public void removeParameter(java.lang.String paramName)
Remove the parameter from the "Parameters" category
Parameters:
paramName - name of the parameter

getFileParameterNames

public java.util.Enumeration getFileParameterNames()
Get the names of all file parameters
Returns:
an enumeration of parameter names

getFileParameter

public FileParameter getFileParameter(java.lang.String paramName)
Get the value of a parameter from the "FileParameters" category
Parameters:
paramName - name of the parameter
Returns:
value of the named parameter

getFileParameterValues

public FileParameter[] getFileParameterValues(java.lang.String paramName)
Get the values of a parameter from the "FileParameters" category
Parameters:
paramName - name of the parameter
Returns:
a array containing values of the named parameter

setFileParameter

public void setFileParameter(java.lang.String paramName,
FileParameter paramValue)
Set the value of a named parameter in the "FileParameters" category
Parameters:
paramName - name of the parameter
paramValue - value of the parameter

removeFileParameter

public void removeFileParameter(java.lang.String paramName)
Remove the parameter from the "FileParameters" category
Parameters:
paramName - name of the parameter

getCharacterEncoding

public java.lang.String getCharacterEncoding()
Get the language and locale used for character encoding
Returns:
a string value like ISO-8859-n

getScheme

public java.lang.String getScheme()
Get the schema used for the request message. For device user agents, possible values of schema are "http", "https", or "ftp". For runtime agent or recursive invocation, the schema is "internal".
Returns:
the name of the schema used for request messaging

getRemoteAddress

public java.lang.String getRemoteAddress()
Get the IP address or other network address of the user agent. Returns "local" if the request is from an internal runtime agent.
Returns:
the network address of the user agent or runtime agent

isSecure

public boolean isSecure()
Verify whether the request is transmitted over a secure channel such HTTPS or SSL.
Returns:
true if the messaging channel is secure

getAuthenticationType

public java.lang.String getAuthenticationType()
Get the type of authentication used to identify the user.
Returns:
the type may be name of AuthenticationContext
See Also:
AuthenticationContext

getRemoteUser

public java.lang.String getRemoteUser()
Returns the name of the user making this request, if the user has been authenticated (say thru mod_sso), or null if the user has not been authenticated.
Returns:
the name of the user making this request or null

getRemoteAuthenticationType

public java.lang.String getRemoteAuthenticationType()
Returns the name of the authentication scheme used to authenticate the user.
Returns:
the name of the authentication scheme

getRequestedSessionId

public java.lang.String getRequestedSessionId()
Get the session id contained in the request.
Returns:
return the value of "PAsid" parameter if any

isRequestedSessionIdValid

public boolean isRequestedSessionIdValid()
Test if the requested session id is valid. Session id is valid if the user session has not expired.
Returns:
true if the session id is still valid or authentication succeeds and a new session has been validated.

isValid

public boolean isValid()
Test if the user is authenticated and session has been established.
Returns:
true if the user is authenticated and service is authorized

getSession

public Session getSession()
Get the session associated with the current request. The session id in the request may be used to locate the session.
Returns:
the session for the user agent that sends the request

getServiceContext

public ServiceContext getServiceContext()
Get the service context for the current request, current session, and requested service. A service context provides an API based on the XML document model for setting and transforming response data.
Returns:
a service context for current request, session, and service

getDevice

public Device getDevice()
Get the device model derived from the user agent type.
Returns:
the device model

getServiceOid

public long getServiceOid()
                   throws PanamaException
Get the value of "PAoid" parameter which specifies the object id of the requested service.
Returns:
the unique object id of the requested service
PanamaException

getServicePath

public java.lang.String getServicePath()
Get the value of "PAservicepath" which specifies the path of the requested service in the repository.
Returns:
the absolute path of the requested service in the repository

setUserAgent

public void setUserAgent(java.lang.String userAgent)
Set the type of the user agent. Using this method, non-http clients can programmatically set the user agent name to have an equivalent effect as the "user-agent" attribute in http header. The user agent is used to determine the device type.
Parameters:
userAgent - the type of the user-agent
See Also:
DeviceIdentificationHook

getArguments

public Arguments getArguments()
                       throws PanamaException
Get the arguments containing all URL parameters and header attributes. return the input arguments
PanamaException

execute

public Response execute()
                 throws PanamaException
Execute a newly created request. It applies the business logics such as authentication, authorization, and invocation of the service using the given parameters.
Returns:
the response that contains data from the invoked service
PanamaException

validate

public ServiceContext validate()
                        throws PanamaException
Validate the request by authenticating the user and authorizing the service.
Returns:
the service context if the validation succeeds
PanamaException

invalidate

public void invalidate()
Invalidate the request and the associated service context and response objects. Resources associated with the service context will be released. Invalidation may be mandatory for some type of requests.

isDebugOn

public boolean isDebugOn()
Test whether logging of debug information is requested. This flag may be set through setDebugOn(boolean value) method. It may also be set through the URL using the "PAdebug" parameter.
Returns:
true if logging of debug information is selected

setDebugOn

public void setDebugOn(boolean value)
Set the flag to request logging of debug information for the current request.
Parameters:
value - true to select debug logging

addRequestListener

public void addRequestListener(RequestListener listener)
Add a listener for events from this request.

removeRequestListener

public void removeRequestListener(RequestListener listener)
Remove a listener for events from this request.

addRequestListeners

public void addRequestListeners(java.util.Vector listeners)
Add a collection of listeners for events from request object.

removeRequestListeners

public void removeRequestListeners(java.util.Vector listeners)
Remove a collection of listeners for events from request object.

setLocationMark

public void setLocationMark(LocationMark landmark)
Set the landmark that identifies the location of the caller. End-users may specify their location by selecting from a list of predefined land marks.
Parameters:
landmark - the landmark that identifies the location of the caller

getLocationMark

public LocationMark getLocationMark()
Get the landmark that identifies the location of the caller. End-users may specify their location by selecting from a list of predefined location marks.
Returns:
the landmark that identifies the location of the caller

getCurrentLocation

public Point getCurrentLocation()
                         throws CallerLocationException
Get the location of the user using one of the following sources, 1. from automatic location tracking module 2. from current landmark specified by user 3. or from the default landmark in the user profile
Throws:
CallerLocationException

getLocationAcquisitionTime

public java.util.Date getLocationAcquisitionTime()
Get the time when the user location was acquired
Returns:
Date the time

isAutoLocated

public boolean isAutoLocated()
Get the auto located (boolean) value.
Returns:
the boolean value of the boolean parameter
See Also:
setAutoLocated(boolean)

setAutoLocated

public void setAutoLocated(boolean autoLocated)
Set the auto located (boolean) parameter.
Parameters:
autoLocated - the new value for the boolean parameter
See Also:
isAutoLocated()

getHeaderAttributes

public java.util.Enumeration getHeaderAttributes()
Get the enumeration of attributes obtained from http header or equivalent source.

getDeviceId

public java.lang.String getDeviceId()
Get the device id,
Returns:
the device id string

getMobileId

public java.lang.String getMobileId()
Get the mobile id, which can be used for automatic location acquisition.
Returns:
the mobile id string

getSubscriberId

public java.lang.String getSubscriberId()
Deprecated. use getMobileId instead
Get the subscriber id, which can be used for automatic location acquisition.
Returns:
the subscriber id string

terminateSession

public void terminateSession()
Terminate the user's session and return a logon page.

getProfile

public Profile getProfile()
Get the user profile.

setProfile

public void setProfile(Profile profile)
Set the user profile.

setSenderAddress

public void setSenderAddress(DeliveryType deliveryType,
                             java.lang.String address,
                             java.lang.String[] carrierInfo)
Sets the address of the sender
Parameters:
deliveryType - the delivery type
address - the address of the sender
carrierInfo - delivery type specific parameters. For example, imap/pop server address for EMAIL delivery type

getDeviceAddress

public DeviceAddress getDeviceAddress()

getCarriers

public java.lang.String[] getCarriers()

getUserHomeURL

public java.lang.String getUserHomeURL()
Returns:
the user's home deck url

getServiceHomeURL

public java.lang.String getServiceHomeURL()
Returns:
service home url

getServiceParentURL

public java.lang.String getServiceParentURL()
Returns:
the containing folder url

getResponse

public Response getResponse()
Get the Response interface associated with this request.

Oracle Application Server Wireless Java API Reference
B10400-01

Copyright © 2003 Oracle Corporation. All Rights Reserved.