OracleJavaScript API Reference for Oracle ADF Faces

 

SUMMARY: FIELD | CONSTR | METHOD    DETAIL: FIELD | CONSTR | METHOD

oracle.adfinternal.view.js.comm
Class AdfRestDataService

Warning:

org.ecmascript.object.Object
   |
   +--oracle.adf.view.js.base.AdfObject
         |
         +--oracle.adfinternal.view.js.comm.AdfRestDataService

public class AdfRestDataService
extends AdfObject
Manages GET requests to REST services, browser connections, XHR request queue and re-prioritizes GET requests on behalf of the DataSource. An instance from this class can be retrieved from AdfDhtmlPage#getRestDataService This class internally co-ordinates with two other classes 1) AdfXhrPoolManager - which manages the pool of connections to be used to make GET calls 2) AdfRestRequestQueueManager - Manages the queue of outstanding REST requests For internal purpose


Field Summary

public static Object
CLIENT_ID_KEY
public static Object
ERROR_CALLBACK_KEY
private Object
_poolManager
public static Object
PRIORITIZE
public static Object
REQUEST_DATA
private Object
_requestQueueManager
public static Object
SUCCESS_CALLBACK_KEY

Fields inherited from oracle.adf.view.js.base.AdfObject

constructor, superclass

Fields inherited from org.ecmascript.object.Object

prototype

Constructor Summary

public
AdfRestDataService()
Manages GET requests to REST services, browser connections, XHR request queue and re-prioritizes GET requests on behalf of the DataSource.

Method Summary

private static Object
_appendAndMergeQueryString(Object url, Object queryString)
protected Object
Init()
Initializes the instance.
protected static Object
InitClass()
private static Object
_initializeOptions(Object options)
public Object
isBusy()
For automation's waitForServer tracking
public static Object
isRelativeUrl(Object url)
public static String
normalizeUrl(String url, Object queryString)
Normalizes the URL as the browser would, if it had to cache the response.
public Object
queueRequest(Object actionURL, Object options)
Queue's a new request to the REST service.
private static Object
_removeHash(Object url)
static Object
__removeTrailingSlashQuestionMarkAmpersand(Object url)
private static Object
_sortQueryParams(Object url)
Object
__xhrCallback(Object request, Object optionKey, Object callbackArgs)
Invokes a specific callback method identifid by a key, from each of the options object for the request The method is invoked from AdfXhrPoolManager on completion of XHR request

Methods inherited from oracle.adf.view.js.base.AdfObject

adopt, clone, createCallback, createInitializedObject, createSubclass, ensureClassInitialization, equals, exportPrototypeSymbol, getClass, GetLazyArrayProperty, GetLazyMapProperty, getTypeName, toDebugString, toString

Field Detail


CLIENT_ID_KEY

public static Object CLIENT_ID_KEY

ERROR_CALLBACK_KEY

public static Object ERROR_CALLBACK_KEY

_poolManager

private Object _poolManager

PRIORITIZE

public static Object PRIORITIZE

REQUEST_DATA

public static Object REQUEST_DATA

_requestQueueManager

private Object _requestQueueManager

SUCCESS_CALLBACK_KEY

public static Object SUCCESS_CALLBACK_KEY

Constructor Detail


AdfRestDataService

public AdfRestDataService()

Manages GET requests to REST services, browser connections, XHR request queue and re-prioritizes GET requests on behalf of the DataSource. An instance from this class can be retrieved from AdfDhtmlPage#getRestDataService This class internally co-ordinates with two other classes 1) AdfXhrPoolManager - which manages the pool of connections to be used to make GET calls 2) AdfRestRequestQueueManager - Manages the queue of outstanding REST requests For internal purpose

Method Detail


_appendAndMergeQueryString

private static Object _appendAndMergeQueryString(Object url,
                                                 Object queryString)

Parameters:
url  
queryString  
Return:
Object

Init

protected Object Init()

Initializes the instance. Subclasses of AdfObject must call their superclass' Init

Return:
Object
Overrides:
AdfObject.Init()

InitClass

protected static Object InitClass()

Return:
Object

_initializeOptions

private static Object _initializeOptions(Object options)

Parameters:
options  
Return:
Object

isBusy

public Object isBusy()

For automation's waitForServer tracking

Return:
Object

isRelativeUrl

public static Object isRelativeUrl(Object url)

Parameters:
url  
Return:
Object

normalizeUrl

public static String normalizeUrl(String url,
                                  Object queryString)

Normalizes the URL as the browser would, if it had to cache the response. This method assumes the URL is encoded in the server.

Parameters:
url - The serverl encoded url to be normalized
queryString  
Return:
String - normalized url

queueRequest

public Object queueRequest(Object actionURL,
                           Object options)

Queue's a new request to the REST service. Depending on the availability of free connections, the request could be posted immediately or will wait for its turn in a FIFO queue. For the request to be prioritized over other waiting requests in the queue, pass true to the parameter 'priority'

Parameters:
actionURL  
options  
Return:
Object

_removeHash

private static Object _removeHash(Object url)

Parameters:
url  
Return:
Object

__removeTrailingSlashQuestionMarkAmpersand

static Object __removeTrailingSlashQuestionMarkAmpersand(Object url)

Parameters:
url  
Return:
Object

_sortQueryParams

private static Object _sortQueryParams(Object url)

Parameters:
url  
Return:
Object

__xhrCallback

Object __xhrCallback(Object request,
                      Object optionKey,
                      Object callbackArgs)

Invokes a specific callback method identifid by a key, from each of the options object for the request The method is invoked from AdfXhrPoolManager on completion of XHR request

Parameters:
request  
optionKey  
callbackArgs  
Return:
Object

SUMMARY: FIELD | CONSTR | METHOD    DETAIL: FIELD | CONSTR | METHOD

 

Copyright (c) 1998, 2018, Oracle and/or its affiliates. All rights reserved.