Rename SNMPClient -> SNMPEngine

master
Harald Wolff 2019-03-04 13:01:59 +01:00
parent 3c135de8db
commit 138fe5eca3
5 changed files with 9 additions and 9 deletions

View File

@ -16,7 +16,7 @@ using System.Threading;
namespace ln.snmp namespace ln.snmp
{ {
public class SNMPClient : IDisposable public class SNMPEngine : IDisposable
{ {
public static bool DEBUG = false; public static bool DEBUG = false;
@ -27,7 +27,7 @@ namespace ln.snmp
private bool shutdown = false; private bool shutdown = false;
private Thread ReceiverThread { get; set; } private Thread ReceiverThread { get; set; }
public SNMPClient(IPEndPoint localEndpoint) public SNMPEngine(IPEndPoint localEndpoint)
{ {
LocalEndpoint = new UdpClient(localEndpoint); LocalEndpoint = new UdpClient(localEndpoint);
ReceiverThread = new Thread(Receiver); ReceiverThread = new Thread(Receiver);

View File

@ -5,12 +5,12 @@ namespace ln.snmp.channel
{ {
public abstract class SnmpPDUChannel public abstract class SnmpPDUChannel
{ {
public SNMPClient SNMPClient { get; set; } public SNMPEngine SNMPClient { get; set; }
public abstract SnmpVersion SnmpVersion { get; } public abstract SnmpVersion SnmpVersion { get; }
public SnmpPDUChannel(SNMPClient client) public SnmpPDUChannel(SNMPEngine client)
{ {
SNMPClient = client; SNMPClient = client;
} }

View File

@ -12,12 +12,12 @@ namespace ln.snmp.channel
public OctetString CommunityString { get; set; } public OctetString CommunityString { get; set; }
public SnmpV1Channel(SNMPClient client) public SnmpV1Channel(SNMPEngine client)
:base(client) :base(client)
{ {
CommunityString = "public"; CommunityString = "public";
} }
public SnmpV1Channel(SNMPClient client,string communityString) public SnmpV1Channel(SNMPEngine client,string communityString)
:base(client) :base(client)
{ {
CommunityString = communityString; CommunityString = communityString;

View File

@ -5,11 +5,11 @@ namespace ln.snmp.channel
{ {
public override SnmpVersion SnmpVersion => SnmpVersion.V2c; public override SnmpVersion SnmpVersion => SnmpVersion.V2c;
public SnmpV2Channel(SNMPClient client) public SnmpV2Channel(SNMPEngine client)
: base(client) : base(client)
{ {
} }
public SnmpV2Channel(SNMPClient client, string communityString) public SnmpV2Channel(SNMPEngine client, string communityString)
: base(client, communityString) : base(client, communityString)
{ } { }

View File

@ -34,7 +34,7 @@
<Reference Include="System.Configuration" /> <Reference Include="System.Configuration" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Compile Include="SNMPClient.cs" /> <Compile Include="SNMPEngine.cs" />
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="types\Variable.cs" /> <Compile Include="types\Variable.cs" />
<Compile Include="BasicEncodingRules.cs" /> <Compile Include="BasicEncodingRules.cs" />