1
0
mirror of https://github.com/ZetaKebab/MpcNET.git synced 2024-09-16 05:30:09 +00:00

Minor clean up

This commit is contained in:
Kim Hugener-Ohlsen 2018-05-20 19:47:33 +02:00
parent 12ddc4bca4
commit 1f59105d4e
3 changed files with 18 additions and 4 deletions

View File

@ -4,14 +4,16 @@
// Licensed under the MIT license. See LICENSE file in the project root for full license information. // Licensed under the MIT license. See LICENSE file in the project root for full license information.
// </copyright> // </copyright>
// -------------------------------------------------------------------------------------------------------------------- // --------------------------------------------------------------------------------------------------------------------
namespace MpcNET namespace MpcNET
{ {
using System; using System;
using Sundew.Base.Reporting;
/// <summary> /// <summary>
/// Interface for implementing an observer for <see cref="MpcConnection"/>. /// Interface for implementing an observer for <see cref="MpcConnection"/>.
/// </summary> /// </summary>
public interface IMpcConnectionReporter public interface IMpcConnectionReporter : IReporter
{ {
/// <summary> /// <summary>
/// Called when connecting. /// Called when connecting.

View File

@ -35,13 +35,23 @@ namespace MpcNET
private string version; private string version;
/// <summary>
/// Initializes a new instance of the <see cref="MpcConnection"/> class.
/// </summary>
/// <param name="server">The server.</param>
/// <param name="mpcConnectionReporter">The MPC connection reporter.</param>
public MpcConnection(IPEndPoint server, IMpcConnectionReporter mpcConnectionReporter = null)
: this(server, null, mpcConnectionReporter)
{
}
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="MpcConnection" /> class. /// Initializes a new instance of the <see cref="MpcConnection" /> class.
/// </summary> /// </summary>
/// <param name="server">The server.</param> /// <param name="server">The server.</param>
/// <param name="commandFactory">The command factory.</param> /// <param name="commandFactory">The command factory.</param>
/// <param name="mpcConnectionReporter">The MPC connection logger.</param> /// <param name="mpcConnectionReporter">The MPC connection logger.</param>
public MpcConnection(IPEndPoint server, ICommandFactory commandFactory = null, IMpcConnectionReporter mpcConnectionReporter = null) public MpcConnection(IPEndPoint server, ICommandFactory commandFactory, IMpcConnectionReporter mpcConnectionReporter = null)
{ {
this.commandFactory = commandFactory ?? new CommandFactory(); this.commandFactory = commandFactory ?? new CommandFactory();
this.mpcConnectionReporter = mpcConnectionReporter; this.mpcConnectionReporter = mpcConnectionReporter;

View File

@ -8,8 +8,10 @@
<GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute> <GenerateAssemblyCompanyAttribute>false</GenerateAssemblyCompanyAttribute>
<GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute> <GenerateAssemblyProductAttribute>false</GenerateAssemblyProductAttribute>
<RootNamespace>MpcNET</RootNamespace> <RootNamespace>MpcNET</RootNamespace>
<Version>0.0.0-pre000</Version> <Version>0.0.1-pre001</Version>
<GeneratePackageOnBuild>true</GeneratePackageOnBuild> <GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<AssemblyVersion>0.0.1.0</AssemblyVersion>
<FileVersion>0.0.1.0</FileVersion>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'"> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
@ -39,7 +41,7 @@
<ItemGroup> <ItemGroup>
<PackageReference Include="Newtonsoft.Json" Version="11.0.2" /> <PackageReference Include="Newtonsoft.Json" Version="11.0.2" />
<PackageReference Include="Sundew.Base" Version="3.2.0-pre014" /> <PackageReference Include="Sundew.Base" Version="3.2.0-pre015" />
<PackageReference Include="System.ValueTuple" Version="4.4.0" /> <PackageReference Include="System.ValueTuple" Version="4.4.0" />
</ItemGroup> </ItemGroup>