Package org.snmp4j.smi

Examples of org.snmp4j.smi.TimeTicks


                variable = new OID(value);
                break;
            }

            case 't': {
                variable = new TimeTicks(Long.parseLong(value));
                break;
            }

            case 'a': {
                variable = new IpAddress(value);
View Full Code Here


        long delta;
        if (bootTime != null) {
            delta = now - bootTime.getTime();
        } else
            delta = 0;
        setSysUpTime(new TimeTicks(delta / 100)); // TT is 100th of a second

    }
View Full Code Here

            if (pdu instanceof PDUv1) {
                PDUv1 v1pdu = (PDUv1) pdu;
                long timeTicks = v1pdu.getTimestamp();
                payload.append("Traptype (generic, specific): ");
                payload.append(v1pdu.getGenericTrap()).append(", ").append(v1pdu.getSpecificTrap()).append("\n");
                payload.append("Timestamp: " + new TimeTicks(timeTicks).toString());
                payload.append("\n");
            }

            SnmpTrapdComponent.trapCount++;
            EventSeverity severity = EventSeverity.INFO;
View Full Code Here

      }
      else if ((type == PDU.TRAP) || (type == PDU.INFORM)) {
        Number tu = (Number) ArgumentParser.getValue(settings, oTrapSysUpTime, 0);
        if (tu != null) {
          pdu.add(new VariableBinding(SnmpConstants.sysUpTime,
                                      new TimeTicks(tu.longValue())));
        }
        String to = (String) ArgumentParser.getValue(settings, oTrapOID, 0);
        if (to != null) {
          pdu.add(new VariableBinding(SnmpConstants.snmpTrapOID, new OID(to)));
        }
View Full Code Here

TOP

Related Classes of org.snmp4j.smi.TimeTicks

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.