Coverage Report - net.sf.snmpadaptor4j.api.opennms.OpennmsSnmpApiFactory
 
Classes in this File Line Coverage Branch Coverage Complexity
OpennmsSnmpApiFactory
100 %
5/5
N/A
1
 
 1  
 package net.sf.snmpadaptor4j.api.opennms;
 2  
 
 3  
 import java.net.InetAddress;
 4  
 import net.sf.snmpadaptor4j.api.SnmpApiFactory;
 5  
 import net.sf.snmpadaptor4j.api.SnmpDaemon;
 6  
 import net.sf.snmpadaptor4j.api.SnmpDaemonConfiguration;
 7  
 import net.sf.snmpadaptor4j.api.SnmpMib;
 8  
 import net.sf.snmpadaptor4j.api.SnmpTrapSender;
 9  
 
 10  
 /**
 11  
  * Factory of facades to <b>joesnmp</b> API.
 12  
  * @author <a href="http://fr.linkedin.com/in/jpminetti/">Jean-Philippe MINETTI</a>
 13  
  */
 14  
 public final class OpennmsSnmpApiFactory
 15  
                 implements SnmpApiFactory {
 16  
 
 17  
         /**
 18  
          * Constructor.
 19  
          */
 20  
         public OpennmsSnmpApiFactory () {
 21  10
                 super();
 22  10
         }
 23  
 
 24  
         /*
 25  
          * {@inheritDoc}
 26  
          * @see net.sf.snmpadaptor4j.api.SnmpApiFactory#newSnmpDaemon(net.sf.snmpadaptor4j.api.SnmpDaemonConfiguration, net.sf.snmpadaptor4j.api.SnmpMib)
 27  
          */
 28  
         public SnmpDaemon newSnmpDaemon (final SnmpDaemonConfiguration configuration, final SnmpMib snmpMib) {
 29  8
                 return new OpennmsSnmpDaemon(configuration, snmpMib);
 30  
         }
 31  
 
 32  
         /*
 33  
          * {@inheritDoc}
 34  
          * @see net.sf.snmpadaptor4j.api.SnmpApiFactory#newSnmpTrapSender(java.net.InetAddress, java.lang.String, int, int, java.lang.String)
 35  
          */
 36  
         public SnmpTrapSender newSnmpTrapSender (final InetAddress agentAddress, final String managerAddress, final int managerPort, final int managerVersion,
 37  
                         final String managerCommunity) {
 38  7
                 return new OpennmsSnmpTrapSender(agentAddress, managerAddress, managerPort, managerVersion, managerCommunity);
 39  
         }
 40  
 
 41  
         /*
 42  
          * {@inheritDoc}
 43  
          * @see java.lang.Object#toString()
 44  
          */
 45  
         @Override
 46  
         public String toString () {
 47  1
                 return "SnmpApiFactory";
 48  
         }
 49  
 
 50  
 }