From 3fe8da9b1255983d2470e5cca66dce1f292a6ff4 Mon Sep 17 00:00:00 2001 From: Adam R Grey Date: Wed, 30 Nov 2022 18:29:44 -0500 Subject: [PATCH] topic liszter! --- topiclister/Program.cs | 30 ++++++++++++++++++++++++++++++ topiclister/topiclister.csproj | 12 ++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 topiclister/Program.cs create mode 100644 topiclister/topiclister.csproj diff --git a/topiclister/Program.cs b/topiclister/Program.cs new file mode 100644 index 0000000..ea65dd7 --- /dev/null +++ b/topiclister/Program.cs @@ -0,0 +1,30 @@ +using franz; +using System; +using System.Linq; + +namespace topiclister +{ + class Program + { + static void Main(string[] args) + { + Telefranz.Configure("shut up", "localhost:9092"); + var listOfBs = AppDomain.CurrentDomain.GetAssemblies() + .SelectMany(domainAssembly => domainAssembly.GetTypes()) + .Where(type => type.IsSubclassOf(typeof(gray_messages.message)) && !type.IsAbstract) + .ToList(); + + if (listOfBs != null && listOfBs.Any()) + { + foreach (var b in listOfBs) + { + Console.WriteLine(b); + } + } + else + { + Console.WriteLine(":("); + } + } + } +} \ No newline at end of file diff --git a/topiclister/topiclister.csproj b/topiclister/topiclister.csproj new file mode 100644 index 0000000..ac85f5e --- /dev/null +++ b/topiclister/topiclister.csproj @@ -0,0 +1,12 @@ + + + + + + + + Exe + net6.0 + + +