27 #ifndef __SB_MEDIALIST_BATCH_CALLBACK_H__
28 #define __SB_MEDIALIST_BATCH_CALLBACK_H__
30 #include <sbIMediaList.h>
37 typedef nsresult (*sbMediaListBatchCallbackFunc)(
nsISupports* aUserData);
42 : mCallbackFunc(aCallbackFunc)
44 NS_ASSERTION(aCallbackFunc,
"Null function pointer!");
49 NS_PRECONDITION(PRInt32(
mRefCnt) >= 0,
"illegal refcnt");
52 NS_LOG_ADDREF(
this,
mRefCnt,
"sbMediaListBatchCallback",
sizeof(*
this));
58 NS_PRECONDITION(0 !=
mRefCnt,
"dup release");
61 NS_LOG_RELEASE(
this,
mRefCnt,
"sbMediaListBatchCallback");
72 NS_ASSERTION(aInstancePtr,
73 "QueryInterface requires a non-NULL destination!");
74 nsresult rv = NS_ERROR_FAILURE;
81 return (*mCallbackFunc)(aUserData);
89 sbMediaListBatchCallbackFunc mCallbackFunc;