本文整理汇总了Java中org.insightech.er.preference.PreferenceInitializer.getTemplatePath方法的典型用法代码示例。如果您正苦于以下问题:Java PreferenceInitializer.getTemplatePath方法的具体用法?Java PreferenceInitializer.getTemplatePath怎么用?Java PreferenceInitializer.getTemplatePath使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.insightech.er.preference.PreferenceInitializer
的用法示例。
在下文中一共展示了PreferenceInitializer.getTemplatePath方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: initTemplateCombo
import org.insightech.er.preference.PreferenceInitializer; //导入方法依赖的package包/类
private void initTemplateCombo() {
this.templateCombo.setVisibleItemCount(20);
this.templateCombo.add(ResourceString
.getResourceString("label.template.default.en"));
this.templateCombo.add(ResourceString
.getResourceString("label.template.default.ja"));
List<String> fileNames = PreferenceInitializer
.getAllExcelTemplateFiles();
for (String fileName : fileNames) {
File file = new File(
PreferenceInitializer.getTemplatePath(fileName));
if (file.exists()) {
this.templateCombo.add(fileName);
}
}
}
示例2: getSelectedTemplate
import org.insightech.er.preference.PreferenceInitializer; //导入方法依赖的package包/类
private InputStream getSelectedTemplate() throws FileNotFoundException {
if (!Check.isEmpty(this.exportExcelSetting.getExcelTemplatePath())) {
return new FileInputStream(FileUtils.getFile(this.projectDir,
this.exportExcelSetting.getExcelTemplatePath()));
}
String lang = this.exportExcelSetting.getUsedDefaultTemplateLang();
if ("en".equals(lang)) {
return TemplatePreferencePage.getDefaultExcelTemplateEn();
} else if ("ja".equals(lang)) {
return TemplatePreferencePage.getDefaultExcelTemplateJa();
}
String templateName = this.exportExcelSetting.getExcelTemplate();
File file = new File(
PreferenceInitializer.getTemplatePath(templateName));
return new FileInputStream(file);
}
示例3: initTemplateCombo
import org.insightech.er.preference.PreferenceInitializer; //导入方法依赖的package包/类
private void initTemplateCombo() {
this.templateCombo.setVisibleItemCount(20);
this.templateCombo.add(ResourceString
.getResourceString("label.template.default.en"));
this.templateCombo.add(ResourceString
.getResourceString("label.template.default.ja"));
this.templateCombo.add(ResourceString
.getResourceString("label.template.default.ko"));
List<String> fileNames = PreferenceInitializer
.getAllExcelTemplateFiles();
for (String fileName : fileNames) {
File file = new File(
PreferenceInitializer.getTemplatePath(fileName));
if (file.exists()) {
this.templateCombo.add(fileName);
}
}
}
示例4: getSelectedTemplate
import org.insightech.er.preference.PreferenceInitializer; //导入方法依赖的package包/类
private InputStream getSelectedTemplate() throws FileNotFoundException {
if (!Check.isEmpty(this.exportExcelSetting.getExcelTemplatePath())) {
return new FileInputStream(FileUtils.getFile(this.projectDir,
this.exportExcelSetting.getExcelTemplatePath()));
}
String lang = this.exportExcelSetting.getUsedDefaultTemplateLang();
if ("en".equals(lang)) {
return TemplatePreferencePage.getDefaultExcelTemplateEn();
} else if ("ja".equals(lang)) {
return TemplatePreferencePage.getDefaultExcelTemplateJa();
} else if ("ko".equals(lang)) {
return TemplatePreferencePage.getDefaultExcelTemplateKo();
}
String templateName = this.exportExcelSetting.getExcelTemplate();
File file = new File(
PreferenceInitializer.getTemplatePath(templateName));
return new FileInputStream(file);
}
示例5: initTemplateCombo
import org.insightech.er.preference.PreferenceInitializer; //导入方法依赖的package包/类
private void initTemplateCombo() {
templateCombo.setVisibleItemCount(20);
templateCombo.add(ResourceString.getResourceString("label.template.default.en"));
templateCombo.add(ResourceString.getResourceString("label.template.default.ja"));
final List<String> fileNames = PreferenceInitializer.getAllExcelTemplateFiles();
for (final String fileName : fileNames) {
final File file = new File(PreferenceInitializer.getTemplatePath(fileName));
if (file.exists()) {
templateCombo.add(fileName);
}
}
}
示例6: getStorePath
import org.insightech.er.preference.PreferenceInitializer; //导入方法依赖的package包/类
@Override
protected String getStorePath(final String name) {
return PreferenceInitializer.getTemplatePath(name);
}
示例7: getSelectedTemplate
import org.insightech.er.preference.PreferenceInitializer; //导入方法依赖的package包/类
private InputStream getSelectedTemplate() throws FileNotFoundException {
if (!Check.isEmpty(exportExcelSetting.getExcelTemplatePath())) {
return new FileInputStream(FileUtils.getFile(projectDir, exportExcelSetting.getExcelTemplatePath()));
}
final String lang = exportExcelSetting.getUsedDefaultTemplateLang();
if ("en".equals(lang)) {
return TemplatePreferencePage.getDefaultExcelTemplateEn();
} else if ("ja".equals(lang)) {
return TemplatePreferencePage.getDefaultExcelTemplateJa();
}
final String templateName = exportExcelSetting.getExcelTemplate();
final File file = new File(PreferenceInitializer.getTemplatePath(templateName));
return new FileInputStream(file);
}
示例8: getStorePath
import org.insightech.er.preference.PreferenceInitializer; //导入方法依赖的package包/类
@Override
protected String getStorePath(String name) {
return PreferenceInitializer.getTemplatePath(name);
}