Class Qww.Hub
Central hub class which other controls and functionality can register with.
Defined in: <JavaScript\QWW\QwwJs_Hub.js>.
| Constructor Attributes | Constructor Name and Description |
|---|---|
|
Qww.Hub()
Creates a new Hub object.
|
| Field Attributes | Field Name and Description |
|---|---|
|
Whether the Hub should start the QVS communication.
|
| Method Attributes | Method Name and Description |
|---|---|
|
DoAvqSelect(applicationID, objectId)
Returns the specified XML element from the latest set of results.
|
|
|
DoAvqSet(applicationID, object, lhs, rhs, isFinal)
Sends through a set command tto QlikView Server.
|
|
|
Register(obj)
Registers a JavaScript object with the hub.
|
|
|
RegisterDocument(cfg, showMessageFunction)
Registers a connection with a QlikView Application on the server.
|
|
|
This sets up a connection with a QlikView application using only the
QlikWeb WorkBench JavaScript files (in other words meaning you don't need
to reference any of the Qv????.js files which ship with QlikView Server.
|
Class Detail
Qww.Hub()
Creates a new Hub object. You should NOT create this, a single
instance is automatically created named qwwHub.
Field Detail
{Bool}
HubShouldStartClient
Whether the Hub should start the QVS communication.
- Default Value:
- true
Method Detail
DoAvqSelect(applicationID, objectId)
Returns the specified XML element from the latest set of results.
- Parameters:
- {String} applicationID
- Application which object applied to. Set to null if you are not connecting to multiple application.
- {String} objectId
- Path to the object to return from the latest results.
DoAvqSet(applicationID, object, lhs, rhs, isFinal)
Sends through a set command tto QlikView Server. e.g.
<set name="Application.Object" add="text,mode" />
- Parameters:
- {String} applicationID
- Application which object applied to. Set to null if you are not connecting to multiple application.
- {String} object
- Object identifier which set applies to.
- {String} lhs
- Left hand side argument
- {String} rhs
- Right hand side argument
- {Bool} isFinal
- Whether to send this and any other previously Set commands (where isFinal was set to false) now.
Register(obj)
Registers a JavaScript object with the hub.
this.OnAvqComplete = function(){alert("QVS Updated");};
this.OnAvqUpdateBegin = function(){alert("QVS About to update");};
this.OnDocumentLoaded = function(){alert("Document loaded");}
qwwHub.Register(this);
- Parameters:
- {Object} obj
- Object which implements any of the following: .OnAvqUpdateComplete .OnAvqUpdateBegin .OnDocumentLoaded
RegisterDocument(cfg, showMessageFunction)
Registers a connection with a QlikView Application on the server. NOTE that
the QvDataSource ASP.NET control calls this method with the approriate arguments. This connection
method depends on the various Qv???.js files shipped with QlikView Server. See Qww.Hub#RegisterWorkBenchOnlyDocument
for a 'light weight' connection method
- Parameters:
- {Object} cfg
- JSON Configuration object.
- {String} cfg.QvApplicationFile
- Name of the QlikView Application.
- {String} cfg.AvqAutoview Optional
- This is an optional property which allows the server to respond with only the data that is used on a single page to minimize the traffic to the client
- {String} cfg.DataPump Optional, Default: ""QvsViewClientEx.ashx"
- {Function} showMessageFunction
- Function to call to display messages (errors, session timeouts etc.) from QlikView Server.
RegisterWorkBenchOnlyDocument(cfg)
This sets up a connection with a QlikView application using only the
QlikWeb WorkBench JavaScript files (in other words meaning you don't need
to reference any of the Qv????.js files which ship with QlikView Server. This however
means that you can only use the controls and features available in the QlikWeb WorkBench and,
for example, do not have access to the 'native' QlikView Server ZFC controls (listbox, table, etc.).
<script src="../../Javascript/QWW/jquery.js" type="text/javascript"></script>
<script src="../../Javascript/QWW/QwwAllCompressed.js" type="text/javascript"></script>
qwwHub.RegisterWorkBenchOnlyDocument({Application: "Entertainment"});
var myFlexiGridCtlMgr = new Qww.Ctls.FlexiGrid.Mgr(
{
"ObjectID" : 'TBDEMO_RESULTS',
"OnRenderRecord" : onRenderRecord,
// .... Other config ...
});
- Parameters:
- {Object} cfg
- JSON Configuration object.
- {String} cfg.Application
- Name of the QlikView Application.
- {Qww.QvsConnector.Mode} cfg.Mode Optional, Default: Qww.QvsConnector.Mode.Direct
- Connection method to use.
- {Functin} cfg.OnUpdateComplete Optional
- Function to call when update is received. Accepts one argument which is a reference to the new data.
