using JT1078.Gateway.Codecs; using JT1078.Gateway.Interfaces; using JT1078.Gateway.Session; using JT1078.Gateway.Udp; using JT1078.Gateway.Udp.Handlers; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.DependencyInjection.Extensions; using System.Runtime.CompilerServices; namespace JT1078.Gateway { public static class JT1078UdpExtensions { public static IJT1078UdpBuilder AddUdpHost(this IJT1078Builder builder) { builder.Services.TryAddSingleton(); builder.Services.TryAddSingleton(); builder.Services.TryAddScoped(); builder.Services.TryAddScoped(); builder.Services.AddHostedService(); return new JT1078UdpBuilderDefault(builder); } } }