1 56 package org.objectstyle.cayenne.modeler.dialog.validator; 57 58 import javax.swing.JFrame ; 59 60 import org.objectstyle.cayenne.access.DataDomain; 61 import org.objectstyle.cayenne.map.DataMap; 62 import org.objectstyle.cayenne.map.Procedure; 63 import org.objectstyle.cayenne.modeler.ProjectController; 64 import org.objectstyle.cayenne.modeler.event.ProcedureDisplayEvent; 65 import org.objectstyle.cayenne.project.ProjectPath; 66 import org.objectstyle.cayenne.project.validator.ValidationInfo; 67 68 71 public class ProcedureErrorMsg extends ValidationDisplayHandler { 72 public ProcedureErrorMsg(ValidationInfo validationInfo) { 73 super(validationInfo); 74 } 75 76 public void displayField(ProjectController mediator, JFrame frame) { 77 ProjectPath path = super.validationInfo.getPath(); 78 DataDomain domain = (DataDomain)path.firstInstanceOf(DataDomain.class); 79 DataMap map = (DataMap)path.firstInstanceOf(DataMap.class); 80 Procedure procedure = (Procedure)path.firstInstanceOf(Procedure.class); 81 82 ProcedureDisplayEvent event = 83 new ProcedureDisplayEvent(frame, procedure, map, domain); 84 event.setTabReset(true); 85 mediator.fireProcedureDisplayEvent(event); 86 } 87 } 88 | Popular Tags |