".rules"));
try {
if (file != null) {
CompilerPreferenceDialog d = new CompilerPreferenceDialog();
d.setVisible(true);
if (d.getReturnStatus() < 0)
return;
else {
String templateAlias = d.getSelectedTemplate();
URL url = Templates.getTemplate(templateAlias);
// URL url = ProfileCompilerImpl.class.getResource( template
// );
if (url == null) {
JOptionPane
.showMessageDialog(
WebPolicyEditor.getWindow(),
"An error occured! The selected template has not been found!",
"Template not found!",
JOptionPane.ERROR_MESSAGE);
return;
} else {
System.setProperty(
PolicyCompilerImpl.PROPERTY_COMPILER_XSLT_FILE,
url.toString());
if (d.rememberUserSelection()) {
System.setProperty(
"org.jwall.web.profile.compiler.use-template",
templateAlias);
}
}