2021-02-21 21:52:41 -06:00
|
|
|
// Decompiled with JetBrains decompiler
|
|
|
|
|
// Type: ZuneXml.HistoryQueryHelper
|
|
|
|
|
// Assembly: ZuneShell, Version=4.7.0.0, Culture=neutral, PublicKeyToken=ddd0da4d3e678217
|
|
|
|
|
// MVID: FC8028F3-A47B-4FB4-B35B-11D1752D8264
|
|
|
|
|
// Assembly location: C:\Program Files\Zune\ZuneShell.dll
|
|
|
|
|
|
|
|
|
|
using Microsoft.Zune.Service;
|
|
|
|
|
using System.Text;
|
|
|
|
|
|
|
|
|
|
namespace ZuneXml
|
|
|
|
|
{
|
|
|
|
|
internal class HistoryQueryHelper : ZuneServiceQueryHelper
|
|
|
|
|
{
|
|
|
|
|
protected string _api;
|
|
|
|
|
|
|
|
|
|
internal HistoryQueryHelper(ZuneServiceQuery query)
|
|
|
|
|
: base(query)
|
|
|
|
|
{
|
|
|
|
|
query.PassportTicketType = EPassportPolicyId.MBI_SSL;
|
|
|
|
|
query.CachePolicy = HttpRequestCachePolicy.BypassCache;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
internal override string GetResourceUri()
|
|
|
|
|
{
|
|
|
|
|
StringBuilder requestUri = new StringBuilder(128);
|
2021-02-21 22:59:09 -06:00
|
|
|
requestUri.Append(Service.GetEndPointUri(EServiceEndpointId.SEID_CommerceV2));
|
2021-02-21 21:52:41 -06:00
|
|
|
requestUri.Append(this._api);
|
|
|
|
|
bool fFirst = true;
|
2021-02-21 22:59:09 -06:00
|
|
|
AppendParam(requestUri, "tunerType", "zunePCClient", ref fFirst);
|
2021-02-21 21:52:41 -06:00
|
|
|
if (this.Query.GetProperty("MediaType") is string property)
|
2021-02-21 22:59:09 -06:00
|
|
|
AppendParam(requestUri, "mediaTypeOrCategory", property, ref fFirst);
|
|
|
|
|
AppendParam(requestUri, "startIndex", "1", ref fFirst);
|
2021-02-21 21:52:41 -06:00
|
|
|
object property1 = this.Query.GetProperty("ChunkSize");
|
|
|
|
|
if (property1 is int)
|
2021-02-21 22:59:09 -06:00
|
|
|
AppendParam(requestUri, "chunkSize", property1.ToString(), ref fFirst);
|
2021-02-21 21:52:41 -06:00
|
|
|
return requestUri.ToString();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
internal override string GetQueryPostBody() => "";
|
|
|
|
|
}
|
|
|
|
|
}
|