-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #45 from Afischbacher/develop
v3.1.0
- Loading branch information
Showing
108 changed files
with
193,195 additions
and
187,918 deletions.
There are no files selected for viewing
15 changes: 7 additions & 8 deletions
15
Nhl.Api.Common/Exceptions/InvalidPlayerPositionException.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,17 @@ | ||
using System; | ||
|
||
namespace Nhl.Api.Common.Exceptions | ||
namespace Nhl.Api.Common.Exceptions; | ||
|
||
/// <summary> | ||
/// An exception for when a request is made to the Nhl.Api and the player/goalie position is invalid | ||
/// </summary> | ||
public class InvalidPlayerPositionException : Exception | ||
{ | ||
/// <summary> | ||
/// An exception for when a request is made to the Nhl.Api and the player/goalie position is invalid | ||
/// </summary> | ||
public class InvalidPlayerPositionException : Exception | ||
public InvalidPlayerPositionException(string message) : base(message) | ||
{ | ||
/// <summary> | ||
/// An exception for when a request is made to the Nhl.Api and the player/goalie position is invalid | ||
/// </summary> | ||
public InvalidPlayerPositionException(string message) : base(message) | ||
{ | ||
|
||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,17 @@ | ||
using System; | ||
|
||
namespace Nhl.Api.Common.Exceptions | ||
namespace Nhl.Api.Common.Exceptions; | ||
|
||
/// <summary> | ||
/// An exception when the season year entered is not a valid NHL season | ||
/// </summary> | ||
public class InvalidSeasonException : Exception | ||
{ | ||
/// <summary> | ||
/// An exception when the season year entered is not a valid NHL season | ||
/// </summary> | ||
public class InvalidSeasonException : Exception | ||
public InvalidSeasonException(string message) : base(message) | ||
{ | ||
/// <summary> | ||
/// An exception when the season year entered is not a valid NHL season | ||
/// </summary> | ||
public InvalidSeasonException(string message) : base(message) | ||
{ | ||
|
||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,17 @@ | ||
using System; | ||
|
||
namespace Nhl.Api.Common.Exceptions | ||
namespace Nhl.Api.Common.Exceptions; | ||
|
||
/// <summary> | ||
/// An exception for a failed Nhl.Api HTTP request | ||
/// </summary> | ||
public class NhlApiRequestException : Exception | ||
{ | ||
/// <summary> | ||
/// An exception for a failed Nhl.Api HTTP request | ||
/// </summary> | ||
public class NhlApiRequestException : Exception | ||
public NhlApiRequestException(string message) : base(message) | ||
{ | ||
/// <summary> | ||
/// An exception for a failed Nhl.Api HTTP request | ||
/// </summary> | ||
public NhlApiRequestException(string message) : base(message) | ||
{ | ||
|
||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,25 +1,24 @@ | ||
using System; | ||
|
||
namespace Nhl.Api.Common.Extensions | ||
namespace Nhl.Api.Common.Extensions; | ||
|
||
/// <summary> | ||
/// A simple library for String extensions for the Nhl.Api | ||
/// </summary> | ||
public static class StringExtensions | ||
{ | ||
/// <summary> | ||
/// A simple library for String extensions for the Nhl.Api | ||
/// Converts a string to a camel case formatted string | ||
/// </summary> | ||
public static class StringExtensions | ||
/// <param name="value">The string value needed to be converted to camel case</param> | ||
/// <returns>A camel cased string, Example: aCamelCasedString</returns> | ||
public static string ToCamelCase(this string value) | ||
{ | ||
/// <summary> | ||
/// Converts a string to a camel case formatted string | ||
/// </summary> | ||
/// <param name="value">The string value needed to be converted to camel case</param> | ||
/// <returns>A camel cased string, Example: aCamelCasedString</returns> | ||
public static string ToCamelCase(this string value) | ||
if (string.IsNullOrWhiteSpace(value)) | ||
{ | ||
if (string.IsNullOrWhiteSpace(value)) | ||
{ | ||
throw new ArgumentNullException(nameof(value)); | ||
} | ||
|
||
return char.ToLowerInvariant(value[0]) + value.Substring(1); | ||
throw new ArgumentNullException(nameof(value)); | ||
} | ||
|
||
return char.ToLowerInvariant(value[0]) + value.Substring(1); | ||
} | ||
} |
Oops, something went wrong.