jsbindings/jsbindings.cpp
/**
 * @brief Callback invoked from JS to get the type property value
 *
 * @param[in] context       JS execution context
 * @param[in] thisObject    JSObject to search for the property
 * @param[in] propertyName  JSString containing the name of the property to get
 * @param[out] exception    Pointer to a JSValueRef in which to return an exception, if any
 *
 * @retval Property's value if object has the property, otherwise NULL
 */


@retval Property's value if object has the property, otherwise NULL
@retval Property ' s value if object has the property otherwise NULL
static JSValueRef Event_getProperty_type(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef* exception)
{
	LOG("[AAMP_JS] %s()", __FUNCTION__);
	const AAMPEvent* pEvent = (const AAMPEvent*)JSObjectGetPrivate(thisObject); 
	if (pEvent == NULL)
	{
		ERROR("[AAMP_JS] %s() Error: JSObjectGetPrivate returned NULL!", __FUNCTION__);
		*exception = aamp_GetException(context, AAMPJS_MISSING_OBJECT, "Can only call Event.type on instances of AAMPEvent");
		return JSValueMakeUndefined(context);
	}
	return JSValueMakeNumber(context, pEvent->type);
}
static JSValueRef Event_getProperty_type ( JSContextRef context , JSObjectRef thisObject , JSStringRef propertyName , JSValueRef * exception ) { LOG ( " " , __FUNCTION__ ) ; const AAMPEvent * pEvent = ( const AAMPEvent * ) JSObjectGetPrivate ( thisObject ) ; if ( pEvent == NULL ) { ERROR ( " " , __FUNCTION__ ) ; * exception = aamp_GetException ( context , AAMPJS_MISSING_OBJECT , " " ) ; return JSValueMakeUndefined ( context ) ; } return JSValueMakeNumber ( context , pEvent -> type ) ; }
@brief Callback invoked from JS to get the type property value
 @param[in] context       JS execution context
 @param[in] thisObject    JSObject to search for the property
 @param[in] propertyName  JSString containing the name of the property to get
 @param[out] exception    Pointer to a JSValueRef in which to return an exception, if any
@brief Callback invoked from JS to get the type property value @param [ in ] context JS execution context @param [ in ] thisObject JSObject to search for the property @param [ in ] propertyName JSString containing the name of the property to get @param [ out ] exception Pointer to a JSValueRef in which to return an exception if any