mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-06-07 06:36:52 +02:00
Also Extern Identity, Destination, Streaming headers
This commit is contained in:
parent
b962a330ad
commit
3330d2bb0c
3 changed files with 20 additions and 9 deletions
|
@ -6,6 +6,7 @@
|
|||
* See full license text in LICENSE file at top of project tree
|
||||
*/
|
||||
|
||||
#include "api.h"
|
||||
#include "capi.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
@ -22,10 +23,10 @@ void C_TerminateI2P ()
|
|||
return i2p::api::TerminateI2P();
|
||||
}
|
||||
|
||||
void C_StartI2P (std::ostream *logStream)
|
||||
void C_StartI2P ()//std::ostream *logStream)
|
||||
{
|
||||
std::shared_ptr<std::ostream> cppLogStream(logStream);
|
||||
return i2p::api::StartI2P(cppLogStream);
|
||||
// std::shared_ptr<std::ostream> cppLogStream(logStream);
|
||||
return i2p::api::StartI2P(nullptr);
|
||||
}
|
||||
|
||||
void C_StopI2P ()
|
||||
|
@ -80,7 +81,7 @@ void C_DestroyStream (i2p::stream::Stream *stream)
|
|||
return i2p::api::DestroyStream(cppStream);
|
||||
}
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
|
|
|
@ -9,17 +9,18 @@
|
|||
#ifndef CAPI_H__
|
||||
#define CAPI_H__
|
||||
|
||||
#include "api.h"
|
||||
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include "Identity.h"
|
||||
#include "Destination.h"
|
||||
#include "Streaming.h"
|
||||
|
||||
// initialization start and stop
|
||||
void C_InitI2P (int argc, char* argv[], const char * appName);
|
||||
void C_TerminateI2P ();
|
||||
void C_StartI2P (std::ostream *logStream = nullptr);
|
||||
void C_StartI2P (); //std::ostream *logStream = nullptr);
|
||||
// write system log to logStream, if not specified to <appName>.log in application's folder
|
||||
void C_StopI2P ();
|
||||
void C_RunPeerTest (); // should be called after UPnP
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue