Class: Analytics

ClearBlade. Analytics

new Analytics() → {Object}

Source:
Returns:
ClearBlade.Analytics the created Analytics object
Type
Object

Methods

getCount(topic, start, stop, callback)

Method to retrieve the average payload size for a topic
Parameters:
Name Type Description
topic string Topic to retrieve the average payload size for
start int Point in time in which to begin the query (epoch timestamp)
stop int Point in time in which to end the query (epoch timestamp)
callback function
Source:
Example
cb.MessagingStats().getCount(filter, function(err, body) {
   if(err) {
       //handle error
   } else {
       console.log(body);
   }
});

getEventList(topic, start, stop, callback)

Method to retrieve the average payload size for a topic
Parameters:
Name Type Description
topic string Topic to retrieve the average payload size for
start int Point in time in which to begin the query (epoch timestamp)
stop int Point in time in which to end the query (epoch timestamp)
callback function
Source:
Example
cb.MessagingStats().getEventList(filter, function(err, body) {
   if(err) {
       //handle error
   } else {
       console.log(body);
   }
});

getEventTotals(topic, start, stop, callback)

Method to retrieve the average payload size for a topic
Parameters:
Name Type Description
topic string Topic to retrieve the average payload size for
start int Point in time in which to begin the query (epoch timestamp)
stop int Point in time in which to end the query (epoch timestamp)
callback function
Source:
Example
cb.MessagingStats().getEventTotals(filter, function(err, body) {
   if(err) {
       //handle error
   } else {
       console.log(body);
   }
});

getStorage(topic, start, stop, callback)

Method to retrieve the average payload size for a topic
Parameters:
Name Type Description
topic string Topic to retrieve the average payload size for
start int Point in time in which to begin the query (epoch timestamp)
stop int Point in time in which to end the query (epoch timestamp)
callback function
Source:
Example
cb.MessagingStats().getStorage(filter, function(err, body) {
   if(err) {
       //handle error
   } else {
       console.log(body);
   }
});

getUserEvents(topic, start, stop, callback)

Method to retrieve the average payload size for a topic
Parameters:
Name Type Description
topic string Topic to retrieve the average payload size for
start int Point in time in which to begin the query (epoch timestamp)
stop int Point in time in which to end the query (epoch timestamp)
callback function
Source:
Example
cb.MessagingStats().getUserEvents(filter, function(err, body) {
   if(err) {
       //handle error
   } else {
       console.log(body);
   }
});