/** * Returns the difference, measured in milliseconds, between the * instantiation time and midnight, January 1, 1970 UTC. * * @jmx:managed-attribute */ public long getInstantiationTime() { return this.clock.instantiationTime(); }
/** * Returns the difference, measured in milliseconds, between the * instantiation time and midnight, January 1, 1970 UTC. * * @jmx:managed-attribute */ public long getInstantiationTime() { return this.clock.instantiationTime(); }
/** * Loads the hashmap with the DCAs of interest. Note that the keys are used * as attribute tags in the mapping resource file **/ public void set(Clock uptime, Counter count) { this.clock = uptime; this.trapCount = count; this.payload.put(STARTTIME_TAG, new Date(this.clock.instantiationTime())); this.payload.put(UPTIME_TAG, // anonymous class new DynamicContentAccessor() { public Object get() { return Long.valueOf(NotificationWrapperSupport.this.clock.uptime()); } }); this.payload.put(TRAPCOUNT_TAG, // anonymous class new DynamicContentAccessor() { public Object get() { return Long.valueOf(NotificationWrapperSupport.this.trapCount.peek()); } }); }
/** * Loads the hashmap with the DCAs of interest. Note that the keys are used * as attribute tags in the mapping resource file **/ public void set(Clock uptime, Counter count) { this.clock = uptime; this.trapCount = count; this.payload.put(STARTTIME_TAG, new Date(this.clock.instantiationTime())); this.payload.put(UPTIME_TAG, // anonymous class new DynamicContentAccessor() { public Object get() { return Long.valueOf(NotificationWrapperSupport.this.clock.uptime()); } }); this.payload.put(TRAPCOUNT_TAG, // anonymous class new DynamicContentAccessor() { public Object get() { return Long.valueOf(NotificationWrapperSupport.this.trapCount.peek()); } }); }