1 23 24 package com.sun.enterprise.admin.event; 25 26 import javax.management.QueryExp ; 27 import javax.management.ObjectName ; 28 29 import com.sun.enterprise.admin.common.constant.AdminConstants; 30 import java.util.logging.Level ; 31 import java.util.logging.Logger ; 32 33 34 43 public class EventKey implements java.io.Serializable { 44 45 static Logger logger = Logger.getLogger(AdminConstants.kLoggerName); 46 47 static final String MALFORMED_OBJECT_NAME = "event.object_name_in_event_is_invalid"; 48 49 52 private ObjectName objName; 53 54 57 private QueryExp qry; 58 59 60 63 public EventKey ( String name, QueryExp q) { 64 try { 65 objName = new ObjectName ( name); 66 qry = q; 67 } catch( Exception e) { 68 logger.log(Level.WARNING, MALFORMED_OBJECT_NAME, name); 71 } 72 } 73 74 77 public ObjectName getObjectName() { return objName; } 78 79 84 public QueryExp getQuery() { return qry; } 85 86 87 90 public void setObjectName(ObjectName obj) { objName = obj; } 91 92 95 public void setQuery(QueryExp q) { qry = q;} 96 } 97 | Popular Tags |