1 56 57 package org.objectstyle.cayenne.event; 58 59 import java.util.Collections ; 60 import java.util.EventObject ; 61 import java.util.Map ; 62 63 70 71 public class CayenneEvent extends EventObject { 72 73 protected Map info; 74 protected transient Object postedBy; 75 76 public CayenneEvent(Object source) { 77 this(source, null); 78 } 79 80 public CayenneEvent(Object source, Map info) { 81 this(source, source, info); 82 } 83 84 87 public CayenneEvent(Object source, Object postedBy, Map info) { 88 super(source); 89 this.postedBy = postedBy; 90 this.info = (info != null ? info : Collections.EMPTY_MAP); 91 } 92 93 public Map getInfo() { 94 return info; 95 } 96 97 100 void setSource(Object source) { 101 super.source = source; 102 } 103 104 108 public Object getPostedBy() { 109 return postedBy; 110 } 111 112 public void setPostedBy(Object postedBy) { 113 this.postedBy = postedBy; 114 } 115 } 116 | Popular Tags |