1 2 23 24 package org.enhydra.tool.codegen.wizard; 25 26 import org.enhydra.tool.ToolBoxInfo; 28 import org.enhydra.tool.common.Browser; 29 import org.enhydra.tool.common.wizard.TBWizardPage; 30 import org.enhydra.tool.codegen.GeneratorException; 31 import org.enhydra.tool.codegen.ValidationException; 32 33 import java.awt.*; 35 import java.beans.*; 36 import java.io.File ; 37 import javax.swing.*; 38 39 47 public class CodeGenPage extends TBWizardPage { 48 51 public CodeGenPage() { 52 super(); 53 } 54 55 private CodeGenPanel getCodeGenPanel() { 56 return (CodeGenPanel) getWizardPanel(); 57 } 58 59 60 66 public void readOptionSet() throws GeneratorException { 67 getCodeGenPanel().readOptionSet(); 68 } 69 70 78 public void writeOptionSet() throws GeneratorException { 79 getCodeGenPanel().writeOptionSet(); 80 } 81 82 91 public void validateOptionSet() throws ValidationException { 92 getCodeGenPanel().validateOptionSet(); 93 } 94 95 public void help() { 96 Browser browser = new Browser(); 97 StringBuffer buf = new StringBuffer (); 98 browser.setOwner(getTopLevelAncestor()); 99 buf.append(ToolBoxInfo.getEnhydraRoot()); 100 buf.append(File.separatorChar); 101 buf.append("doc"); buf.append(File.separatorChar); 103 buf.append("index.html"); browser.open(buf.toString()); 105 } 106 } 107 | Popular Tags |