1 19 20 package org.netbeans.modules.j2ee.ddloaders.web.event; 21 22 import org.netbeans.modules.j2ee.ddloaders.web.DDDataObject; 23 24 30 public class DDChangeEvent extends java.util.EventObject { 31 32 33 public static final int SERVLET_ADDED = 1; 34 35 36 public static final int SERVLET_CHANGED = 2; 37 38 39 public static final int SERVLET_DELETED = 3; 41 42 public static final int SERVLET_MOVED = 4; 43 44 45 47 48 public static final int FILTER_CHANGED = 6; 49 50 51 public static final int FILTER_DELETED = 7; 52 53 54 56 57 59 60 public static final int LISTENER_CHANGED = 10; 61 62 63 public static final int LISTENER_DELETED = 11; 64 65 66 68 69 71 72 public static final int JSP_CHANGED = 14; 73 74 75 public static final int JSP_DELETED = 15; 76 77 78 80 81 private String newValue; 82 83 84 private String oldValue; 85 86 87 private int type; 88 89 90 private DDDataObject oldDD; 91 92 97 public DDChangeEvent (Object src, DDDataObject oldDD, String oldVal, String newVal, int type) { 98 super (src); 99 newValue = newVal; 100 oldValue = oldVal; 101 this.type = type; 102 this.oldDD = oldDD; 103 } 104 105 110 public DDChangeEvent (Object src, String oldVal, String newVal, int type) { 111 this (src, null, oldVal, newVal, type); 112 } 113 114 public String getNewValue () { 115 return newValue; 116 } 117 118 public String getOldValue () { 119 return oldValue; 120 } 121 122 public DDDataObject getOldDD () { 123 return oldDD; 124 } 125 126 130 public int getType () { 131 return type; 132 } 133 134 public String toString () { 135 return "DDChangeEvent "+getSource ()+" of type "+type; } 137 138 } 139 | Popular Tags |