OracleJavaScript API Reference for Oracle ADF Faces

 

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

oracle.adfinternal.view.js.comm
Class AdfXhrPoolManager

Warning:

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

public class AdfXhrPoolManager
extends AdfObject
Manages the pool of connections to be used to make GET calls outside JSF lifecycle. This class pulls the request items from the AdfRestRequestQueueManager class, by either listening to the request items addition to the queue, or when a connection is reclaimed.



Field Summary

private Object
_connectionTokens
private static Object
_HTTP_METHOD
private Object
_requestQueueManager


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

constructor, superclass


Fields inherited from org.ecmascript.object.Object

prototype


Constructor Summary

public
AdfXhrPoolManager(Object requestQueueManager)
Manages the pool of connections to be used to make GET calls outside JSF lifecycle.


Method Summary

private static Object
_createConfiguredXhr(Object dispatchRequest)
private Object
_dispatch(Object dispatchRequest, Object token)
private Object
_drainRequests()
For each free connection available, pull the next item of the request queue and dispatch it
private static Object
_getXhrProps(Object dispatchRequest)
public Object
hasDispatchedPriorityRequests()
Returns true if the pool has a dispatched priority request item
protected Object
Init(Object requestQueueManager)
Initializes the instance.
protected static Object
InitClass()
private Object
_intializeConnectionTokens()
Creates an array with size based on the number of connections available and initializes the array members with numbers 1 to n.
private Object
_mergeRequests()
Tracks if the request items at the front of the request queue are similar to the request items that are already in flight, and if found, combine the options to trigger a combined notification without making a REST call.
private Object
_readyStateChangeCallback(Object xhrObject, Object dispatchRequest, Object token)
Invokes the callback on AdfRestDataService on completion of the XHR call.


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


_connectionTokens

private Object _connectionTokens

_HTTP_METHOD

private static Object _HTTP_METHOD

_requestQueueManager

private Object _requestQueueManager

Constructor Detail


AdfXhrPoolManager

public AdfXhrPoolManager(Object requestQueueManager)

Manages the pool of connections to be used to make GET calls outside JSF lifecycle. This class pulls the request items from the AdfRestRequestQueueManager class, by either listening to the request items addition to the queue, or when a connection is reclaimed.

Parameters:
requestQueueManager    

Method Detail


_createConfiguredXhr

private static Object _createConfiguredXhr(Object dispatchRequest)

Parameters:
dispatchRequest    
Return:
Object

_dispatch

private Object _dispatch(Object dispatchRequest,
                         Object token)

Parameters:
dispatchRequest    
token    
Return:
Object

_drainRequests

private Object _drainRequests()

For each free connection available, pull the next item of the request queue and dispatch it

Return:
Object

_getXhrProps

private static Object _getXhrProps(Object dispatchRequest)

Parameters:
dispatchRequest    
Return:
Object

hasDispatchedPriorityRequests

public Object hasDispatchedPriorityRequests()

Returns true if the pool has a dispatched priority request item

Return:
Object

Init

protected Object Init(Object requestQueueManager)

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

Parameters:
requestQueueManager    
Return:
Object
Overrides:
AdfObject.Init()

InitClass

protected static Object InitClass()

Return:
Object

_intializeConnectionTokens

private Object _intializeConnectionTokens()

Creates an array with size based on the number of connections available and initializes the array members with numbers 1 to n. These entries represent the valid connection tokens.

Return:
Object

_mergeRequests

private Object _mergeRequests()

Tracks if the request items at the front of the request queue are similar to the request items that are already in flight, and if found, combine the options to trigger a combined notification without making a REST call.

Return:
Object

_readyStateChangeCallback

private Object _readyStateChangeCallback(Object xhrObject,
                                         Object dispatchRequest,
                                         Object token)

Invokes the callback on AdfRestDataService on completion of the XHR call. Also drops the request from the queue and triggers the next request in the queue to be processed.

Parameters:
xhrObject    
dispatchRequest    
token    
Return:
Object

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

 

Generated on 2017.04.19 06:37 UTC
Copyright (c) 1998, 2015, Oracle and/or its affiliates. All rights reserved.