Exemple #1
0
		/// <summary>
		/// Adds a torrent from a url. Deluge will attempt to fetch the torrent
		/// from url prior to adding it to the session.
		/// </summary>
		/// <param name='url'>
		/// the url pointing to the torrent file
		/// </param>
		/// <param name='options'>
		/// the options to apply to the torrent on add
		/// </param>
		/// <param name='headers'>
		/// any optional headers to send
		/// </param>
		/// <param name='callback'>
		/// Callback.
		/// </param>
		public void AddTorrentUrl(string url, Dictionary<string, object> options, Dictionary<string, string> headers, object state, AddTorrentCallback callback)
		{
			_protocol.Call("core.add_torrent_url", new object[] {
				url, ConversionHelper.ToObjectDictionary(options),
				ConversionHelper.ToObjectDictionary(headers),
			}, _AddTorrentUrlCallback, null, new object[] { callback, state });
		}
Exemple #2
0
		/// <summary>
		/// Adds a torrent file to the session.
		/// </summary>
		/// <param name='filename'>
		/// The filename of the torrent
		/// </param>
		/// <param name='filedump'>
		/// Base 64 encoded string of the torrent file contents.
		/// </param>
		/// <param name='options'>
		/// Options to apply to the torrent on add
		/// </param>
		/// <param name='callback'>
		/// Method Callback (string torrent_id)
		/// </param>			
		public void AddTorrentFile(string filename, string filedump, Dictionary<string, object> options, object state, AddTorrentCallback callback)
		{
			_protocol.Call("core.add_torrent_file", new object[] {
				filename, filedump, ConversionHelper.ToObjectDictionary(options),
			}, _AddTorrentFileCallback, null, new object[] { callback, state });
		}
Exemple #3
0
		/// <summary>
		/// Adds a torrent from a url. Deluge will attempt to fetch the torrent
		/// from url prior to adding it to the session.
		/// </summary>
		/// <param name='url'>
		/// the url pointing to the torrent file
		/// </param>
		/// <param name='options'>
		/// the options to apply to the torrent on add
		/// </param>
		/// <param name='headers'>
		/// any optional headers to send
		/// </param>
		/// <param name='callback'>
		/// Callback.
		/// </param>
		public void AddTorrentUrl(string url, Dictionary<string, object> options, Dictionary<string, string> headers, AddTorrentCallback callback)
		{
			AddTorrentUrl(url, options, headers, null, callback);
		}
Exemple #4
0
		/// <summary>
		/// Adds a torrent file to the session.
		/// </summary>
		/// <param name='filename'>
		/// The filename of the torrent
		/// </param>
		/// <param name='filedump'>
		/// Base 64 encoded string of the torrent file contents.
		/// </param>
		/// <param name='options'>
		/// Options to apply to the torrent on add
		/// </param>
		/// <param name='callback'>
		/// Method Callback (string torrent_id)
		/// </param>			
		public void AddTorrentFile(string filename, string filedump, Dictionary<string, object> options, AddTorrentCallback callback)
		{
			AddTorrentFile(filename, filedump, options, null, callback);
		}