8 NicoVideoAuth_P nicoVideoAuth;
13 :nicoVideoAuth(NicoVideoAuth_new()){}
17 NicoVideoAuth_delete(&nicoVideoAuth);
20 VOID SetBrowserType(BROWSERTYPE bt){
23 rslt = NicoVideoAuth_getNicoVideoAuth(nicoVideoAuth,bt);
24 if(rslt != NLIB_ERR_OK){
26 throw NLIBException(TEXT("
\83j
\83R
\83j
\83R
\93®
\89æ
\94F
\8fØ
\8fî
\95ñ
\8eæ
\93¾
\82É
\8e¸
\94s
\82µ
\82Ü
\82µ
\82½"),rslt,__LINE__,TEXT(__FILE__));
31 NicoVideoAuth_P GetAuth(){
33 return this->nicoVideoAuth;
38 class CNicoLiveStream{
41 NicoLiveStream_P nicoLiveStream;
45 :nicoLiveStream(NicoLiveStream_new())
50 NicoLiveStream_delete(&nicoLiveStream);
56 VOID Connect(CNicoVideoAuth &nicoVideoAuth,LPCTSTR url,NicoRecvCallBack callback,LPVOID userData){
60 rslt = NicoLiveStream_connect(nicoLiveStream,nicoVideoAuth.GetAuth(),url,callback,userData);
62 if(rslt != NLIB_ERR_OK){
64 throw NLIBException(TEXT("
\83j
\83R
\83j
\83R
\90¶
\95ú
\91\97\90Ú
\91±
\82É
\8e¸
\94s
\82µ
\82Ü
\82µ
\82½"),rslt,__LINE__,TEXT(__FILE__));
71 NicoLiveStream_disConnect(nicoLiveStream);
74 VOID SendChat(LPCTSTR chatBuf,std::vector<LPCTSTR> mails,std::vector<LPCTSTR> extends){
76 mails.insert( mails.end(),(LPCTSTR)NULL);
77 extends.insert(extends.end(),(LPCTSTR)NULL);
78 rslt = NicoLiveStream_sendChat(nicoLiveStream,chatBuf,&mails[0],&extends[0]);
80 if(rslt != NLIB_ERR_OK){
81 throw NLIBException(TEXT("
\83R
\83\81\83\93\83g
\91\97\90M
\92\86\82É
\8fá
\8aQ
\82ª
\94
\90¶
\82µ
\82Ü
\82µ
\82½"),rslt,__LINE__,TEXT(__FILE__));