private void ProcessLine(string line) { if (ClusterSpot.TryParse(line, out var spot)) { OnClusterSpotReceived?.Invoke(this, spot); } else { _logger.LogWarning("Could not parse line into spot: \n " + line); } }
public static bool TryParse(string line, out ClusterSpot spot) { if (string.IsNullOrWhiteSpace(line) || !line.StartsWith("DX de ")) { spot = null; return(false); } if (Program.OutputUnitTests) { File.AppendAllText("tests.cs", @$ " [Fact]