1 22 package org.jboss.verifier.event; 23 24 47 48 49 import java.util.Enumeration ; 51 52 53 import org.gjt.lindfors.util.EventGeneratorSupport; 55 import org.jboss.verifier.strategy.VerificationContext; 56 57 58 70 public class VerificationEventGeneratorSupport extends EventGeneratorSupport { 71 72 75 public VerificationEventGeneratorSupport() { 76 77 super(); 78 79 } 80 81 public void addVerificationListener(VerificationListener listener) { 82 83 super.addListener(listener); 84 85 } 86 87 public void removeVerificationListener(VerificationListener listener) { 88 89 super.removeListener(listener); 90 91 } 92 93 94 99 public void fireBeanChecked(VerificationEvent event) { 100 101 Enumeration e = super.getListeners(); 102 103 while (e.hasMoreElements()) { 104 VerificationListener listener = (VerificationListener) e.nextElement(); 105 listener.beanChecked(event); 106 } 107 } 108 109 public void fireSpecViolation(VerificationEvent event) { 110 111 Enumeration e = super.getListeners(); 112 113 while (e.hasMoreElements()) { 114 VerificationListener listener = (VerificationListener) e.nextElement(); 115 listener.specViolation(event); 116 } 117 } 118 119 } 120 121 | Popular Tags |