public static AlarmCacheObject createTestAlarm1(){
  AlarmCacheObject alarm1=new AlarmCacheObject();
  alarm1.setId(Long.valueOf(1));
  alarm1.setFaultFamily("fault family");
  alarm1.setFaultMember("fault member");
  alarm1.setFaultCode(0);
  AlarmCondition condition=AlarmCondition.fromConfigXML("<AlarmCondition class=\"cern.c2mon.server.common.alarm.ValueAlarmCondition\">" + "<alarm-value type=\"String\">DOWN</alarm-value></AlarmCondition>");
  alarm1.setCondition(condition);
  alarm1.setInfo("alarm info");
  alarm1.setState(AlarmCondition.TERMINATE);
  alarm1.setTimestamp(new Timestamp(System.currentTimeMillis() - 2000));
  alarm1.setDataTagId(100003L);
  return alarm1;
}

public static AlarmCacheObject createTestAlarm1 ( ) { AlarmCacheObject alarm1 = new AlarmCacheObject ( ) ; alarm1 . setId ( Long . valueOf ( 1 ) ) ; alarm1 . setFaultFamily ( "fault family" ) ; alarm1 . setFaultMember ( "fault member" ) ; alarm1 . setFaultCode ( 0 ) ; AlarmCondition condition = AlarmCondition . fromConfigXML ( "<AlarmCondition class=\"cern.c2mon.server.common.alarm.ValueAlarmCondition\">" + "<alarm-value type=\"String\">DOWN</alarm-value></AlarmCondition>" ) ; alarm1 . setCondition ( condition ) ; alarm1 . setInfo ( "alarm info" ) ; alarm1 . setState ( AlarmCondition . TERMINATE ) ; alarm1 . setTimestamp ( new Timestamp ( System . currentTimeMillis ( ) - 2000 ) ) ; alarm1 . setDataTagId ( 100003L ) ; return alarm1 ; }
does not set reference to tag id .
