Skip to content

Commit

Permalink
Fixing some unsigned typed issues.
Browse files Browse the repository at this point in the history
  • Loading branch information
babelshift committed Jan 27, 2018
1 parent cf8f2eb commit 3ec39f6
Show file tree
Hide file tree
Showing 25 changed files with 67 additions and 63 deletions.
6 changes: 5 additions & 1 deletion src/SteamWebAPI2/AutoMapperConfiguration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,11 @@ public static void Initialize()

#region Endpoint: SteamRemoteStorage

x.CreateMap<uint, PublishedFileVisibility>();
x.CreateMap<uint, PublishedFileVisibility>()
.ConvertUsing(src =>
{
return (PublishedFileVisibility)src;
});
x.CreateMap<PublishedFileDetails, PublishedFileDetailsModel>()
.ForMember(dest => dest.FileUrl, opts => opts.MapFrom(source => new Uri(source.FileUrl)))
.ForMember(dest => dest.PreviewUrl, opts => opts.MapFrom(source => new Uri(source.PreviewUrl)));
Expand Down
2 changes: 1 addition & 1 deletion src/SteamWebAPI2/Interfaces/SteamNews.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public SteamNews(string steamWebApiKey, ISteamWebInterface steamWebInterface = n
/// <returns></returns>
public async Task<ISteamWebResponse<SteamNewsResultModel>> GetNewsForAppAsync(uint appId, uint? maxLength = null, DateTime? endDate = null, uint? count = null)
{
long? endDateUnixTimeStamp = null;
ulong? endDateUnixTimeStamp = null;

if (endDate.HasValue)
{
Expand Down
4 changes: 2 additions & 2 deletions src/SteamWebAPI2/Interfaces/SteamUserStats.cs
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ public async Task<ISteamWebResponse<IReadOnlyCollection<GlobalAchievementPercent
/// <returns></returns>
public async Task<ISteamWebResponse<IReadOnlyCollection<GlobalStatModel>>> GetGlobalStatsForGameAsync(uint appId, IReadOnlyList<string> statNames, DateTime? startDate = null, DateTime? endDate = null)
{
long? startDateUnixTimeStamp = null;
long? endDateUnixTimeStamp = null;
ulong? startDateUnixTimeStamp = null;
ulong? endDateUnixTimeStamp = null;

if (startDate.HasValue)
{
Expand Down
12 changes: 6 additions & 6 deletions src/SteamWebAPI2/Models/CSGO/ServerStatusResultContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ namespace SteamWebAPI2.Models.CSGO
{
internal class ServerStatusApp
{
public int Version { get; set; }
public long Timestamp { get; set; }
public uint Version { get; set; }
public ulong Timestamp { get; set; }
public string Time { get; set; }
}

Expand All @@ -23,16 +23,16 @@ internal class ServerStatusMatchmaking
public string Scheduler { get; set; }

[JsonProperty(PropertyName = "online_servers")]
public int OnlineServers { get; set; }
public uint OnlineServers { get; set; }

[JsonProperty(PropertyName = "online_players")]
public int OnlinePlayers { get; set; }
public uint OnlinePlayers { get; set; }

[JsonProperty(PropertyName = "searching_players")]
public int SearchingPlayers { get; set; }
public uint SearchingPlayers { get; set; }

[JsonProperty(PropertyName = "search_seconds_avg")]
public int SearchSecondsAverage { get; set; }
public uint SearchSecondsAverage { get; set; }
}

internal class ServerStatusServices
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ internal class MatchDetailResult
public uint Duration { get; set; }

[JsonProperty(PropertyName = "start_time")]
public long StartTime { get; set; }
public ulong StartTime { get; set; }

[JsonProperty(PropertyName = "match_id")]
public ulong MatchId { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion src/SteamWebAPI2/Models/DOTA2/TeamInfoResultContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ internal class TeamInfo
public uint TeamId { get; set; }
public string Name { get; set; }
public string Tag { get; set; }
public long TimeCreated { get; set; }
public ulong TimeCreated { get; set; }
public string Rating { get; set; }
public ulong Logo { get; set; }
public ulong LogoSponsor { get; set; }
Expand Down
6 changes: 3 additions & 3 deletions src/SteamWebAPI2/Models/SchemaForGameResultContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ internal class SchemaGameStat
public string Name { get; set; }

[JsonProperty("defaultvalue")]
public int DefaultValue { get; set; }
public uint DefaultValue { get; set; }

[JsonProperty("displayName")]
public string DisplayName { get; set; }
Expand All @@ -21,13 +21,13 @@ internal class SchemaGameAchievement
public string Name { get; set; }

[JsonProperty("defaultvalue")]
public int DefaultValue { get; set; }
public uint DefaultValue { get; set; }

[JsonProperty("displayName")]
public string DisplayName { get; set; }

[JsonProperty("hidden")]
public int Hidden { get; set; }
public uint Hidden { get; set; }

[JsonProperty("description")]
public string Description { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion src/SteamWebAPI2/Models/SteamAppListResultContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace SteamWebAPI2.Models
internal class SteamApp
{
[JsonProperty("appid")]
public int AppId { get; set; }
public uint AppId { get; set; }

[JsonProperty("name")]
public string Name { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ internal class SteamAppUpToDateCheckResult
public bool VersionIsListable { get; set; }

[JsonProperty("required_version")]
public int RequiredVersion { get; set; }
public uint RequiredVersion { get; set; }

[JsonProperty("message")]
public string Message { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ internal class GlobalStatsForGameResult
public IList<GlobalStat> GlobalStats { get; set; }

[JsonProperty("result")]
public int Status { get; set; }
public uint Status { get; set; }
}

internal class GlobalStatsForGameResultContainer
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,10 +140,10 @@ internal class Trade
public ulong TradeParterSteamId { get; set; }

[JsonProperty("time_init")]
public long TimeTradeStarted { get; set; }
public ulong TimeTradeStarted { get; set; }

[JsonProperty("time_escrow_end")]
public long TimeEscrowEnds { get; set; }
public ulong TimeEscrowEnds { get; set; }

[JsonProperty("status")]
public TradeStatus TradeStatus { get; set; }
Expand Down
8 changes: 4 additions & 4 deletions src/SteamWebAPI2/Models/SteamEconomy/TradeOffer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ internal class TradeOffer
public string Message { get; set; }

[JsonProperty("expiration_time")]
public long TimeExpiration { get; set; }
public ulong TimeExpiration { get; set; }

[JsonProperty("trade_offer_state")]
public TradeOfferState TradeOfferState { get; set; }
Expand All @@ -30,16 +30,16 @@ internal class TradeOffer
public bool IsOfferYouCreated { get; set; }

[JsonProperty("time_created")]
public long TimeCreated { get; set; }
public ulong TimeCreated { get; set; }

[JsonProperty("time_updated")]
public long TimeUpdated { get; set; }
public ulong TimeUpdated { get; set; }

[JsonProperty("from_real_time_trade")]
public bool WasCreatedFromRealTimeTrade { get; set; }

[JsonProperty("escrow_end_date")]
public long TimeEscrowEnds { get; set; }
public ulong TimeEscrowEnds { get; set; }

[JsonProperty("confirmation_method")]
public TradeOfferConfirmationMethod ConfirmationMethod { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion src/SteamWebAPI2/Models/SteamInterface.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public SteamInterface()
internal class SteamMethod
{
public string Name { get; set; }
public int Version { get; set; }
public uint Version { get; set; }
public string HttpMethod { get; set; }
public string Description { get; set; }
public IList<SteamParameter> Parameters { get; private set; }
Expand Down
4 changes: 2 additions & 2 deletions src/SteamWebAPI2/Models/SteamNewsResultContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ internal class NewsItem
public string FeedLabel { get; set; }

[JsonProperty("date")]
public int Date { get; set; }
public uint Date { get; set; }

[JsonProperty("feedname")]
public string Feedname { get; set; }
Expand All @@ -36,7 +36,7 @@ internal class NewsItem
internal class SteamNewsResult
{
[JsonProperty("appid")]
public int AppId { get; set; }
public uint AppId { get; set; }

[JsonProperty("newsitems")]
public IList<NewsItem> NewsItems { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ internal class CurrentPlayersResult
public uint PlayerCount { get; set; }

[JsonProperty("result")]
public int Result { get; set; }
public uint Result { get; set; }
}

internal class CurrentPlayersResultContainer
Expand Down
2 changes: 1 addition & 1 deletion src/SteamWebAPI2/Models/SteamStore/AppDetailsContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ internal class PackageGroup
public string SaveText { get; set; }

[JsonProperty("display_type")]
public int DisplayType { get; set; }
public uint DisplayType { get; set; }

[JsonProperty("is_recurring_subscription")]
public string IsRecurringSubscription { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ internal class Item
public bool StreamingvideoAvailable { get; set; }

[JsonProperty("discount_expiration")]
public int DiscountExpiration { get; set; }
public uint DiscountExpiration { get; set; }

[JsonProperty("header_image")]
public string HeaderImage { get; set; }
Expand Down Expand Up @@ -146,6 +146,6 @@ internal class FeaturedCategoriesContainer
public TrailerSlideshow TrailerSlideshow { get; set; }

[JsonProperty("status")]
public int Status { get; set; }
public uint Status { get; set; }
}
}
42 changes: 21 additions & 21 deletions src/SteamWebAPI2/Models/SteamStore/FeaturedProductsContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ namespace SteamWebAPI2.Models.SteamStore
internal class LargeCapsule
{
[JsonProperty("id")]
public int Id { get; set; }
public uint Id { get; set; }

[JsonProperty("type")]
public int Type { get; set; }
public uint Type { get; set; }

[JsonProperty("name")]
public string Name { get; set; }
Expand All @@ -17,13 +17,13 @@ internal class LargeCapsule
public bool Discounted { get; set; }

[JsonProperty("discount_percent")]
public int DiscountPercent { get; set; }
public uint DiscountPercent { get; set; }

[JsonProperty("original_price")]
public int? OriginalPrice { get; set; }
public uint? OriginalPrice { get; set; }

[JsonProperty("final_price")]
public int FinalPrice { get; set; }
public uint FinalPrice { get; set; }

[JsonProperty("currency")]
public string Currency { get; set; }
Expand Down Expand Up @@ -59,10 +59,10 @@ internal class LargeCapsule
internal class FeaturedWin
{
[JsonProperty("id")]
public int Id { get; set; }
public uint Id { get; set; }

[JsonProperty("type")]
public int Type { get; set; }
public uint Type { get; set; }

[JsonProperty("name")]
public string Name { get; set; }
Expand All @@ -71,13 +71,13 @@ internal class FeaturedWin
public bool Discounted { get; set; }

[JsonProperty("discount_percent")]
public int DiscountPercent { get; set; }
public uint DiscountPercent { get; set; }

[JsonProperty("original_price")]
public int? OriginalPrice { get; set; }
public uint? OriginalPrice { get; set; }

[JsonProperty("final_price")]
public int FinalPrice { get; set; }
public uint FinalPrice { get; set; }

[JsonProperty("currency")]
public string Currency { get; set; }
Expand Down Expand Up @@ -113,10 +113,10 @@ internal class FeaturedWin
internal class FeaturedMac
{
[JsonProperty("id")]
public int Id { get; set; }
public uint Id { get; set; }

[JsonProperty("type")]
public int Type { get; set; }
public uint Type { get; set; }

[JsonProperty("name")]
public string Name { get; set; }
Expand All @@ -125,13 +125,13 @@ internal class FeaturedMac
public bool Discounted { get; set; }

[JsonProperty("discount_percent")]
public int DiscountPercent { get; set; }
public uint DiscountPercent { get; set; }

[JsonProperty("original_price")]
public int? OriginalPrice { get; set; }
public uint? OriginalPrice { get; set; }

[JsonProperty("final_price")]
public int FinalPrice { get; set; }
public uint FinalPrice { get; set; }

[JsonProperty("currency")]
public string Currency { get; set; }
Expand Down Expand Up @@ -164,10 +164,10 @@ internal class FeaturedMac
internal class FeaturedLinux
{
[JsonProperty("id")]
public int Id { get; set; }
public uint Id { get; set; }

[JsonProperty("type")]
public int Type { get; set; }
public uint Type { get; set; }

[JsonProperty("name")]
public string Name { get; set; }
Expand All @@ -176,13 +176,13 @@ internal class FeaturedLinux
public bool Discounted { get; set; }

[JsonProperty("discount_percent")]
public int DiscountPercent { get; set; }
public uint DiscountPercent { get; set; }

[JsonProperty("original_price")]
public int? OriginalPrice { get; set; }
public uint? OriginalPrice { get; set; }

[JsonProperty("final_price")]
public int FinalPrice { get; set; }
public uint FinalPrice { get; set; }

[JsonProperty("currency")]
public string Currency { get; set; }
Expand Down Expand Up @@ -230,6 +230,6 @@ internal class FeaturedProductsContainer
public string Layout { get; set; }

[JsonProperty("status")]
public int Status { get; set; }
public uint Status { get; set; }
}
}
4 changes: 2 additions & 2 deletions src/SteamWebAPI2/Models/TF2/GoldenWrenchResultContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ internal class GoldenWrench
public DateTime Timestamp { get; set; }

[JsonProperty("itemID")]
public int ItemId { get; set; }
public uint ItemId { get; set; }

[JsonProperty("wrenchNumber")]
public int WrenchNumber { get; set; }
public uint WrenchNumber { get; set; }
}

internal class GoldenWrenchResult
Expand Down
2 changes: 1 addition & 1 deletion src/SteamWebAPI2/Models/UGCFileDetailsResultContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ internal class UGCFileDetails
{
public string FileName { get; set; }
public string URL { get; set; }
public int Size { get; set; }
public uint Size { get; set; }
}
}
2 changes: 1 addition & 1 deletion src/SteamWebAPI2/Models/UserStatsForGameResultContainer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ internal class UserStatAchievement
public string Name { get; set; }

[JsonProperty("achieved")]
public int Achieved { get; set; }
public uint Achieved { get; set; }
}

internal class UserStatsForGameResult
Expand Down
Loading

0 comments on commit 3ec39f6

Please sign in to comment.