@Override public JobMeta loadJob( ObjectId idJob, String versionLabel ) throws KettleException { RepositoryObject jobInfo = getObjectInformation( idJob, RepositoryObjectType.JOB ); return loadJob( jobInfo.getName(), jobInfo.getRepositoryDirectory(), null, versionLabel ); }
@Override public TransMeta loadTransformation( ObjectId idTransformation, String versionLabel ) throws KettleException { RepositoryObject jobInfo = getObjectInformation( idTransformation, RepositoryObjectType.TRANSFORMATION ); return loadTransformation( jobInfo.getName(), jobInfo.getRepositoryDirectory(), null, true, versionLabel ); }
public JobMeta loadJob( ObjectId idJob, String versionLabel ) throws KettleException { RepositoryObject jobInfo = getObjectInformation( idJob, RepositoryObjectType.JOB ); return loadJob( jobInfo.getName(), jobInfo.getRepositoryDirectory(), null, versionLabel ); }
public TransMeta loadTransformation( ObjectId idTransformation, String versionLabel ) throws KettleException { RepositoryObject jobInfo = getObjectInformation( idTransformation, RepositoryObjectType.TRANSFORMATION ); return loadTransformation( jobInfo.getName(), jobInfo.getRepositoryDirectory(), null, true, versionLabel ); }
private void selectJob() { RepositoryObject repositoryObject = DialogHelper.selectRepositoryObject( "*.kjb", log ); if ( repositoryObject != null ) { String path = DialogUtils .getPath( jobMeta.getRepositoryDirectory().getPath(), repositoryObject.getRepositoryDirectory().getPath() ); String fullPath = ( path.equals( "/" ) ? "/" : path + "/" ) + repositoryObject.getName(); wPath.setText( fullPath ); } }
private void selectTransformation() { RepositoryObject repositoryObject = DialogHelper.selectRepositoryObject( "*.ktr", log ); if ( repositoryObject != null ) { String path = DialogUtils .getPath( jobMeta.getRepositoryDirectory().getPath(), repositoryObject.getRepositoryDirectory().getPath() ); String fullPath = ( path.equals( "/" ) ? "/" : path + "/" ) + repositoryObject.getName(); wPath.setText( fullPath ); } }
private void selectRepositoryTrans() { RepositoryObject repositoryObject = DialogHelper.selectRepositoryObject( "*.ktr", log ); try { if ( repositoryObject != null ) { loadRepositoryTrans( repositoryObject.getName(), repositoryObject.getRepositoryDirectory() ); String path = DialogUtils .getPath( transMeta.getRepositoryDirectory().getPath(), injectTransMeta.getRepositoryDirectory().getPath() ); String fullPath = ( path.equals( "/" ) ? "/" : path + "/" ) + injectTransMeta.getName(); wPath.setText( fullPath ); specificationMethod = ObjectLocationSpecificationMethod.REPOSITORY_BY_NAME; } } catch ( KettleException ke ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "SingleThreaderDialog.ErrorSelectingObject.DialogTitle" ), BaseMessages.getString( PKG, "SingleThreaderDialog.ErrorSelectingObject.DialogMessage" ), ke ); } }
private void selectRepositoryJob() { RepositoryObject repositoryObject = DialogHelper.selectRepositoryObject( "*.kjb", log ); try { if ( repositoryObject != null ) { loadRepositoryJob( repositoryObject.getName(), repositoryObject.getRepositoryDirectory() ); String path = DialogUtils .getPath( transMeta.getRepositoryDirectory().getPath(), executorJobMeta.getRepositoryDirectory().getPath() ); String fullPath = ( path.equals( "/" ) ? "/" : path + "/" ) + executorJobMeta.getName(); wPath.setText( fullPath ); specificationMethod = ObjectLocationSpecificationMethod.REPOSITORY_BY_NAME; } } catch ( KettleException ke ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "SingleThreaderDialog.ErrorSelectingObject.DialogTitle" ), BaseMessages.getString( PKG, "SingleThreaderDialog.ErrorSelectingObject.DialogMessage" ), ke ); } }
private void selectRepositoryTrans() { RepositoryObject repositoryObject = DialogHelper.selectRepositoryObject( "*.ktr", log ); try { if ( repositoryObject != null ) { loadRepositoryTrans( repositoryObject.getName(), repositoryObject.getRepositoryDirectory() ); String path = DialogUtils .getPath( transMeta.getRepositoryDirectory().getPath(), mappingTransMeta.getRepositoryDirectory().getPath() ); String fullPath = ( path.equals( "/" ) ? "/" : path + "/" ) + mappingTransMeta.getName(); wPath.setText( fullPath ); specificationMethod = ObjectLocationSpecificationMethod.REPOSITORY_BY_NAME; } } catch ( KettleException ke ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "SingleThreaderDialog.ErrorSelectingObject.DialogTitle" ), BaseMessages.getString( PKG, "SingleThreaderDialog.ErrorSelectingObject.DialogMessage" ), ke ); } }
private void selectRepositoryTrans() { RepositoryObject repositoryObject = DialogHelper.selectRepositoryObject( "*.ktr", log ); try { if ( repositoryObject != null ) { loadRepositoryTrans( repositoryObject.getName(), repositoryObject.getRepositoryDirectory() ); String path = DialogUtils .getPath( transMeta.getRepositoryDirectory().getPath(), mappingTransMeta.getRepositoryDirectory().getPath() ); String fullPath = ( path.equals( "/" ) ? "/" : path + "/" ) + mappingTransMeta.getName(); wPath.setText( fullPath ); specificationMethod = ObjectLocationSpecificationMethod.REPOSITORY_BY_NAME; } } catch ( KettleException ke ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "MappingDialog.ErrorSelectingObject.DialogTitle" ), BaseMessages.getString( PKG, "MappingDialog.ErrorSelectingObject.DialogMessage" ), ke ); } }
private void selectRepositoryTrans() { RepositoryObject repositoryObject = DialogHelper.selectRepositoryObject( "*.ktr", log ); try { if ( repositoryObject != null ) { loadRepositoryTrans( repositoryObject.getName(), repositoryObject.getRepositoryDirectory() ); String path = DialogUtils .getPath( transMeta.getRepositoryDirectory().getPath(), mappingTransMeta.getRepositoryDirectory().getPath() ); String fullPath = ( path.equals( "/" ) ? "/" : path + "/" ) + mappingTransMeta.getName(); wPath.setText( fullPath ); specificationMethod = ObjectLocationSpecificationMethod.REPOSITORY_BY_NAME; } } catch ( KettleException ke ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "SimpleMappingDialog.ErrorSelectingObject.DialogTitle" ), BaseMessages.getString( PKG, "SimpleMappingDialog.ErrorSelectingObject.DialogMessage" ), ke ); } }
private void selectRepositoryTrans() { RepositoryObject repositoryObject = DialogHelper.selectRepositoryObject( "*.ktr", log ); try { if ( repositoryObject != null ) { loadRepositoryTrans( repositoryObject.getName(), repositoryObject.getRepositoryDirectory() ); String path = DialogUtils.getPath( transMeta.getRepositoryDirectory().getPath(), executorTransMeta.getRepositoryDirectory().getPath() ); String fullPath = ( path.equals( "/" ) ? "/" : path + "/" ) + executorTransMeta.getName(); wPath.setText( fullPath ); specificationMethod = ObjectLocationSpecificationMethod.REPOSITORY_BY_NAME; } } catch ( KettleException ke ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "TransExecutorDialog.ErrorSelectingObject.DialogTitle" ), BaseMessages.getString( PKG, "TransExecutorDialog.ErrorSelectingObject.DialogMessage" ), ke ); } }
private void getByReferenceData( ObjectId referenceObjectId ) { try { RepositoryObject jobInf = rep.getObjectInformation( referenceObjectId, RepositoryObjectType.JOB ); String path = DialogUtils.getPath( jobMeta.getRepositoryDirectory().getPath(), jobInf.getRepositoryDirectory().getPath() ); String fullPath = Const.NVL( path, "" ) + "/" + Const.NVL( jobInf.getName(), "" ); wPath.setText( fullPath ); } catch ( KettleException e ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "JobEntryJobDialog.Exception.UnableToReferenceObjectId.Title" ), BaseMessages.getString( PKG, "JobEntryJobDialog.Exception.UnableToReferenceObjectId.Message" ), e ); } }
private void getByReferenceData( ObjectId transObjectId ) { try { RepositoryObject transInf = repository.getObjectInformation( transObjectId, RepositoryObjectType.TRANSFORMATION ); String path = DialogUtils .getPath( transMeta.getRepositoryDirectory().getPath(), transInf.getRepositoryDirectory().getPath() ); String fullPath = Const.NVL( path, "" ) + "/" + Const.NVL( transInf.getName(), "" ); wPath.setText( fullPath ); } catch ( KettleException e ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "JobEntryTransDialog.Exception.UnableToReferenceObjectId.Title" ), BaseMessages.getString( PKG, "JobEntryTransDialog.Exception.UnableToReferenceObjectId.Message" ), e ); } }
private void getByReferenceData( ObjectId transObjectId ) { try { RepositoryObject transInf = repository.getObjectInformation( transObjectId, RepositoryObjectType.TRANSFORMATION ); String path = DialogUtils .getPath( transMeta.getRepositoryDirectory().getPath(), transInf.getRepositoryDirectory().getPath() ); String fullPath = Const.NVL( path, "" ) + "/" + Const.NVL( transInf.getName(), "" ); wPath.setText( fullPath ); } catch ( KettleException e ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "JobEntryTransDialog.Exception.UnableToReferenceObjectId.Title" ), BaseMessages.getString( PKG, "JobEntryTransDialog.Exception.UnableToReferenceObjectId.Message" ), e ); } }
private void getByReferenceData( ObjectId transObjectId ) { try { RepositoryObject transInf = rep.getObjectInformation( transObjectId, RepositoryObjectType.TRANSFORMATION ); String path = DialogUtils.getPath( jobMeta.getRepositoryDirectory().getPath(), transInf.getRepositoryDirectory().getPath() ); String fullPath = Const.NVL( path, "" ) + "/" + Const.NVL( transInf.getName(), "" ); wPath.setText( fullPath ); } catch ( KettleException e ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "JobEntryTransDialog.Exception.UnableToReferenceObjectId.Title" ), BaseMessages.getString( PKG, "JobEntryTransDialog.Exception.UnableToReferenceObjectId.Message" ), e ); } }
private void getByReferenceData( ObjectId jobObjectId ) { try { RepositoryObject jobInf = repository.getObjectInformation( jobObjectId, RepositoryObjectType.JOB ); String path = DialogUtils.getPath( transMeta.getRepositoryDirectory().getPath(), jobInf.getRepositoryDirectory().getPath() ); String fullPath = Const.NVL( path, "" ) + "/" + Const.NVL( jobInf.getName(), "" ); wPath.setText( fullPath ); } catch ( KettleException e ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "JobEntryJobDialog.Exception.UnableToReferenceObjectId.Title" ), BaseMessages.getString( PKG, "JobEntryJobDialog.Exception.UnableToReferenceObjectId.Message" ), e ); } }
public static RepositoryFile build( org.pentaho.di.repository.RepositoryObject repositoryObject ) { RepositoryFile repositoryFile = new RepositoryFile(); repositoryFile.setObjectId( repositoryObject.getObjectId() ); repositoryFile.setName( repositoryObject.getName() ); repositoryFile.setType( repositoryObject.getObjectType().getTypeDescription() ); repositoryFile.setExtension( repositoryObject.getObjectType().getExtension() ); repositoryFile.setDate( repositoryObject.getModifiedDate() ); repositoryFile.setPath( repositoryObject.getRepositoryDirectory().getPath() ); return repositoryFile; }
private void getByReferenceData( ObjectId transObjectId ) { try { if ( repository == null ) { throw new KettleException( BaseMessages.getString( PKG, "MappingDialog.Exception.NotConnectedToRepository.Message" ) ); } RepositoryObject transInf = repository.getObjectInformation( transObjectId, RepositoryObjectType.TRANSFORMATION ); String path = DialogUtils .getPath( transMeta.getRepositoryDirectory().getPath(), transInf.getRepositoryDirectory().getPath() ); String fullPath = Const.NVL( path, "" ) + "/" + Const.NVL( transInf.getName(), "" ); wPath.setText( fullPath ); } catch ( KettleException e ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "MappingDialog.Exception.UnableToReferenceObjectId.Title" ), BaseMessages.getString( PKG, "MappingDialog.Exception.UnableToReferenceObjectId.Message" ), e ); } }
private void getByReferenceData( ObjectId transObjectId ) { try { if ( repository == null ) { throw new KettleException( BaseMessages.getString( PKG, "SimpleMappingDialog.Exception.NotConnectedToRepository.Message" ) ); } RepositoryObject transInf = repository.getObjectInformation( transObjectId, RepositoryObjectType.TRANSFORMATION ); String path = DialogUtils .getPath( transMeta.getRepositoryDirectory().getPath(), transInf.getRepositoryDirectory().getPath() ); String fullPath = Const.NVL( path, "" ) + "/" + Const.NVL( transInf.getName(), "" ); wPath.setText( fullPath ); } catch ( KettleException e ) { new ErrorDialog( shell, BaseMessages.getString( PKG, "SimpleMappingDialog.Exception.UnableToReferenceObjectId.Title" ), BaseMessages.getString( PKG, "SimpleMappingDialog.Exception.UnableToReferenceObjectId.Message" ), e ); } }