src/MonoTorrent.Client/MonoTorrent/Torrent.cs
/// <summary>
/// Loads a .torrent from the specified byte[]. A return value indicates
/// whether the operation was successful.
/// </summary>
/// <param name="data">The byte[] to load the .torrent from</param>
/// <param name="torrent">If loading was successful, it contains the Torrent</param>
/// <returns>True if successful</returns>
Loads a .torrent from the specified byte[]. A return value indicates
whether the operation was successful.
Loads a . torrent from the specified byte [] . A return value indicates whether the operation was successful .
public static bool TryLoad (byte[] data, out Torrent torrent)
        {
            Check.Data (data);
            try {
                torrent = Load (data);
            } catch {
                torrent = null;
            }
            return torrent != null;
        }
public static bool TryLoad ( byte [ ] data , out Torrent torrent ) { Check . Data ( data ) ; try { torrent = Load ( data ) ; } catch { torrent = null ; } return torrent != null ; }
Loads a .torrent from the specified byte[].
Loads a . torrent from the specified byte [] .
True if successful
True if successful
data
byte[]
The byte[] to load the .torrent from
The byte [] to load the . torrent from
Torrent
out
torrent
If loading was successful, it contains the Torrent
If loading was successful it contains the Torrent