1
0
mirror of https://github.com/ZetaKebab/MpcNET.git synced 2025-07-02 00:57:38 +00:00

Response from MPD will be specific type. MpdDirectory and MpdFile created. Metadata for MpdFile still to be done.

This commit is contained in:
glucaci
2016-12-19 12:12:22 +01:00
parent 15c81b96e9
commit f6653e0075
15 changed files with 275 additions and 711 deletions

View File

@ -3,18 +3,10 @@ using System.Linq;
namespace LibMpc
{
public interface IMpcCommand<T>
public interface IMpcCommand<out T>
{
string Value { get; }
IDictionary<string, T> FormatResponse(IList<KeyValuePair<string, string>> response);
}
internal static class MpdCommandExtensions
{
public static IDictionary<string, string> ToDefaultDictionary(this IList<KeyValuePair<string, string>> items)
{
return items.ToDictionary(item => item.Key, item => item.Value);
}
T FormatResponse(IList<KeyValuePair<string, string>> response);
}
}