2009-06-06 17:39:04 +00:00
|
|
|
/*
|
|
|
|
* This file Copyright (C) 2008-2009 Charles Kerr <charles@transmissionbt.com>
|
2007-01-19 04:42:31 +00:00
|
|
|
*
|
2009-06-06 17:39:04 +00:00
|
|
|
* This file is licensed by the GPL version 2. Works owned by the
|
|
|
|
* Transmission project are granted a special exemption to clause 2(b)
|
|
|
|
* so that the bulk of its code can remain under the MIT license.
|
|
|
|
* This exemption does not extend to derived works not owned by
|
|
|
|
* the Transmission project.
|
2007-01-19 04:42:31 +00:00
|
|
|
*
|
2009-06-06 17:39:04 +00:00
|
|
|
* $Id$
|
|
|
|
*/
|
2007-01-19 04:42:31 +00:00
|
|
|
|
2008-11-24 20:17:36 +00:00
|
|
|
#ifndef __TRANSMISSION__
|
|
|
|
#error only libtransmission should #include this header.
|
|
|
|
#endif
|
|
|
|
|
2007-01-19 04:42:31 +00:00
|
|
|
#ifndef SHARED_H
|
|
|
|
#define SHARED_H 1
|
|
|
|
|
|
|
|
#include "transmission.h"
|
2009-04-15 21:05:58 +00:00
|
|
|
#include "net.h"
|
2007-01-19 04:42:31 +00:00
|
|
|
|
2009-08-12 14:40:32 +00:00
|
|
|
/**
|
2009-05-29 19:17:12 +00:00
|
|
|
* @addtogroup port_forwarding Port Forwarding
|
|
|
|
* @{
|
|
|
|
*/
|
|
|
|
|
2009-05-14 13:42:29 +00:00
|
|
|
struct tr_bindsockets;
|
|
|
|
|
2007-09-20 16:32:01 +00:00
|
|
|
typedef struct tr_shared tr_shared;
|
2007-07-30 18:04:10 +00:00
|
|
|
|
2009-10-23 03:41:36 +00:00
|
|
|
tr_shared* tr_sharedInit( tr_session* );
|
2008-09-23 19:11:04 +00:00
|
|
|
|
2009-05-14 13:42:29 +00:00
|
|
|
void tr_sharedClose( tr_session * );
|
2008-09-23 19:11:04 +00:00
|
|
|
|
2009-05-14 13:42:29 +00:00
|
|
|
void tr_sharedPortChanged( tr_session * );
|
2008-09-23 19:11:04 +00:00
|
|
|
|
2008-12-14 11:21:11 +00:00
|
|
|
void tr_sharedTraversalEnable( tr_shared *, tr_bool isEnabled );
|
2008-09-23 19:11:04 +00:00
|
|
|
|
2008-12-14 11:21:11 +00:00
|
|
|
tr_port tr_sharedGetPeerPort( const tr_shared * s );
|
2008-09-23 19:11:04 +00:00
|
|
|
|
2008-12-14 11:21:11 +00:00
|
|
|
tr_bool tr_sharedTraversalIsEnabled( const tr_shared * s );
|
2008-09-23 19:11:04 +00:00
|
|
|
|
|
|
|
int tr_sharedTraversalStatus( const tr_shared * );
|
2007-01-19 04:42:31 +00:00
|
|
|
|
2009-05-29 19:17:12 +00:00
|
|
|
/** @} */
|
2007-01-19 04:42:31 +00:00
|
|
|
#endif
|