jsbindings/jsbindings.cpp
/**
 * @brief Callback invoked from JS to set the reportInterval property value
 *
 * @param[in]  context       JS exception context
 * @param[in]  thisObject    JSObject on which to set the property's value
 * @param[in]  propertyName  JSString containing the name of the property to set
 * @param[in]  value         JSValue to use as the property's value
 * @param[out] exception     Pointer to a JSValueRef in which to return an exception, if any
 *
 * @retval true if the property was set, otherwise false
 */


@retval true if the property was set, otherwise false
@retval true if the property was set otherwise false
static bool AAMP_setProperty_reportInterval(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef value, JSValueRef* exception)
{
	LOG("[AAMP_JS] %s()", __FUNCTION__);
	AAMP_JS* pAAMP = (AAMP_JS*)JSObjectGetPrivate(thisObject);
	if (pAAMP == NULL)
	{
		ERROR("[AAMP_JS] %s() Error: JSObjectGetPrivate returned NULL!", __FUNCTION__);
		*exception = aamp_GetException(context, AAMPJS_MISSING_OBJECT, "Can only call AAMP.reportInterval on instances of AAMP");
		return false;
	}
	pAAMP->_aamp->SetReportInterval(JSValueToNumber(context, value, exception));
	return true;
}
static bool AAMP_setProperty_reportInterval ( JSContextRef context , JSObjectRef thisObject , JSStringRef propertyName , JSValueRef value , JSValueRef * exception ) { LOG ( " " , __FUNCTION__ ) ; AAMP_JS * pAAMP = ( AAMP_JS * ) JSObjectGetPrivate ( thisObject ) ; if ( pAAMP == NULL ) { ERROR ( " " , __FUNCTION__ ) ; * exception = aamp_GetException ( context , AAMPJS_MISSING_OBJECT , " " ) ; return false ; } pAAMP -> _aamp -> SetReportInterval ( JSValueToNumber ( context , value , exception ) ) ; return true ; }
@brief Callback invoked from JS to set the reportInterval property value
 @param[in]  context       JS exception context
 @param[in]  thisObject    JSObject on which to set the property's value
 @param[in]  propertyName  JSString containing the name of the property to set
 @param[in]  value         JSValue to use as the property's value
 @param[out] exception     Pointer to a JSValueRef in which to return an exception, if any
@brief Callback invoked from JS to set the reportInterval property value @param [ in ] context JS exception context @param [ in ] thisObject JSObject on which to set the property ' s value @param [ in ] propertyName JSString containing the name of the property to set @param [ in ] value JSValue to use as the property ' s value @param [ out ] exception Pointer to a JSValueRef in which to return an exception if any