# Yahoo! UI Library

### DataSource Utility 2.6.0

Yahoo! UI Library > datasource > YAHOO.util.FunctionDataSource

Show Private Show Protected Show Deprecated

## Class YAHOO.util.FunctionDataSource - extends YAHOO.util.DataSourceBase

FunctionDataSource class for JavaScript functions.

### Constructor

YAHOO.util.FunctionDataSource `( oLiveData , oConfigs )`

Parameters:
  `oLiveData <HTMLElement>` Pointer to live data.
  `oConfigs <object>` (optional) Object literal of configuration values.

#### Properties inherited from YAHOO.util.DataSourceBase:

`_aCache, _aIntervals, _oQueue, _sName, dataType, ERROR_DATAINVALID, ERROR_DATANULL, liveData, maxCacheEntries, responseSchema, responseType, TYPE_HTMLTABLE, TYPE_JSARRAY, TYPE_JSFUNCTION, TYPE_JSON, TYPE_LOCAL, TYPE_SCRIPTNODE, TYPE_TEXT, TYPE_UNKNOWN, TYPE_XHR, TYPE_XML`

### Methods

#### makeConnection

`Number makeConnection ( oRequest , oCallback , oCaller )`
Overriding method passes query to a function. The returned response is then forwarded to the handleResponse function.

Parameters:
  `oRequest <Object>` Request object.
  `oCallback <Object>` Callback object literal.
  `oCaller <Object>` (deprecated) Use oCallback.scope.

Returns: `Number`
  Transaction ID.

#### Methods inherited from YAHOO.util.DataSourceBase:

`addToCache, clearAllIntervals, clearInterval, doBeforeCallback, doBeforeParseData, flushCache, getCachedResponse, handleResponse, isCacheHit, makeConnection, parseArrayData, parseData, parseHTMLTableData, parseJSONData, parseTextData, parseXMLData, parseXMLResult, sendRequest, setInterval, toString`

#### Events inherited from YAHOO.util.DataSourceBase:

`cacheFlushEvent, cacheRequestEvent, cacheResponseEvent, dataErrorEvent, requestEvent, responseCacheEvent, responseEvent, responseParseEvent,`

Copyright © 2008 Yahoo! Inc. All rights reserved.