public static AlarmCacheObject createTestAlarm2(){
  AlarmCacheObject alarm1=new AlarmCacheObject();
  alarm1.setId(Long.valueOf(2));
  alarm1.setFaultFamily("fault family 2");
  alarm1.setFaultMember("fault member 2");
  alarm1.setFaultCode(2);
  AlarmCondition condition=AlarmCondition.fromConfigXML("<AlarmCondition class=\"cern.c2mon.server.common.alarm.ValueAlarmCondition\">" + "<alarm-value type=\"Boolean\">false</alarm-value></AlarmCondition>");
  alarm1.setCondition(condition);
  alarm1.setInfo("alarm info");
  alarm1.setState(AlarmCondition.ACTIVE);
  alarm1.setTimestamp(new Timestamp(System.currentTimeMillis() - 2000));
  return alarm1;
}

public static AlarmCacheObject createTestAlarm2 ( ) { AlarmCacheObject alarm1 = new AlarmCacheObject ( ) ; alarm1 . setId ( Long . valueOf ( 2 ) ) ; alarm1 . setFaultFamily ( "fault family 2" ) ; alarm1 . setFaultMember ( "fault member 2" ) ; alarm1 . setFaultCode ( 2 ) ; AlarmCondition condition = AlarmCondition . fromConfigXML ( "<AlarmCondition class=\"cern.c2mon.server.common.alarm.ValueAlarmCondition\">" + "<alarm-value type=\"Boolean\">false</alarm-value></AlarmCondition>" ) ; alarm1 . setCondition ( condition ) ; alarm1 . setInfo ( "alarm info" ) ; alarm1 . setState ( AlarmCondition . ACTIVE ) ; alarm1 . setTimestamp ( new Timestamp ( System . currentTimeMillis ( ) - 2000 ) ) ; return alarm1 ; }
does not set reference to tag id . created alarm has not been published to external alarm system ( i . e . publication field is null )
