public static bool IsClientVersionLessThanOrEqualTo(this RestApiBaseController controller, string version) { return(controller.GetClientPlatformVersion(version.Count(x => x == '.') + 1) <= new Version(version)); }
public static bool IsClientVersionEqualToOrGreaterThan(this RestApiBaseController controller, string version) { return(controller.GetClientPlatformVersion(version.Count(x => x == '.') + 1) >= new Version(version)); }
public static string GetClientPlatformAndVersion(this RestApiBaseController controller) { return(string.Format("{0}-v{1}", controller.GetClientPlatform(), controller.GetClientPlatformVersion(2))); }