本文整理匯總了Java中org.pentaho.di.repository.Repository.readJobMetaSharedObjects方法的典型用法代碼示例。如果您正苦於以下問題:Java Repository.readJobMetaSharedObjects方法的具體用法?Java Repository.readJobMetaSharedObjects怎麽用?Java Repository.readJobMetaSharedObjects使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.pentaho.di.repository.Repository
的用法示例。
在下文中一共展示了Repository.readJobMetaSharedObjects方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: editProperties
import org.pentaho.di.repository.Repository; //導入方法依賴的package包/類
public static boolean editProperties(JobMeta jobMeta, Spoon spoon, Repository rep, boolean allowDirectoryChange) {
if (jobMeta == null)
return false;
JobDialog jd = new JobDialog(spoon.getShell(), SWT.NONE, jobMeta, rep);
jd.setDirectoryChangeAllowed(allowDirectoryChange);
JobMeta ji = jd.open();
// In this case, load shared objects
//
if (jd.isSharedObjectsFileChanged()) {
try {
SharedObjects sharedObjects = rep!=null ? rep.readJobMetaSharedObjects(jobMeta) : jobMeta.readSharedObjects();
spoon.sharedObjectsFileMap.put(sharedObjects.getFilename(), sharedObjects);
} catch (Exception e) {
new ErrorDialog(spoon.getShell(), BaseMessages.getString(PKG, "Spoon.Dialog.ErrorReadingSharedObjects.Title"),
BaseMessages.getString(PKG, "Spoon.Dialog.ErrorReadingSharedObjects.Message", spoon.delegates.tabs.makeTabName(jobMeta, true)), e);
}
}
// If we added properties, add them to the variables too, so that they appear in the CTRL-SPACE variable completion.
//
spoon.setParametersAsVariablesInUI(jobMeta, jobMeta);
if (jd.isSharedObjectsFileChanged() || ji != null) {
spoon.refreshTree();
spoon.delegates.tabs.renameTabs(); // cheap operation, might as will do it anyway
}
spoon.setShellText();
return ji != null;
}