@Test public void checkRename() { final Path path = mock(Path.class); final String newFileName = "newFileName"; final String comment = "comment"; service.rename(path, newFileName, comment); verify(renameService, times(1)).rename(eq(path), eq(newFileName), eq(comment)); }
@Override public Path rename(final Path path, final String newName, final String comment) { try { return renameService.rename(path, newName, comment); } catch (Exception e) { throw ExceptionUtilities.handleException(e); } }
GuidedDecisionTableEditorServiceImpl extends KieService<GuidedDecisionTableEditorContent> implements GuidedDecisionTableEditorService { @Override public Path rename(final Path path, final String newName, final String comment) { try { return renameService.rename(path, newName, comment); } catch (Exception e) { throw ExceptionUtilities.handleException(e); } } }
GuidedDecisionTableEditorServiceImpl extends KieService<GuidedDecisionTableEditorContent> implements GuidedDecisionTableEditorService { @Override public Path rename(final Path path, final String newName, final String comment) { try { return renameService.rename(path, newName, comment); } catch (Exception e) { throw ExceptionUtilities.handleException(e); } } GuidedDecisionTableEditorServiceImpl(); @Inject  GuidedDecisionTableEditorServiceImpl(final @Named("ioStrategy") IOService ioService,
                                                final CopyService copyService,
                                                final DeleteService deleteService,
                                                final RenameService renameService,
                                                final DataModelService dataModelService,
                                                final WorkItemsEditorService workItemsService,
                                                final KieModuleService moduleService,
                                                final VersionRecordService versionRecordService,
                                                final GuidedDecisionTableGraphEditorService dtableGraphService,
                                                final DecisionTableGuidedToDecisionTableXLSConverter decisionTableGuidedToDecisionTableXLSConverter,
                                                final GuidedDTableGraphResourceTypeDefinition dtableGraphType,
                                                final Event<ResourceOpenedEvent> resourceOpenedEvent,
                                                final GenericValidator genericValidator,
                                                final CommentedOptionFactory commentedOptionFactory,
                                                final SaveAndRenameServiceImpl<GuidedDecisionTable52, Metadata> saveAndRenameService,
                                                final SessionInfo sessionInfo); }
GuidedDecisionTableEditorServiceImpl extends KieService<GuidedDecisionTableEditorContent> implements GuidedDecisionTableEditorService { @Override public Path rename(final Path path, final String newName, final String comment) { try { return renameService.rename(path, newName, comment); } catch (Exception e) { throw ExceptionUtilities.handleException(e); } } GuidedDecisionTableEditorServiceImpl(); @Inject  GuidedDecisionTableEditorServiceImpl(final @Named("ioStrategy") IOService ioService,
                                                final CopyService copyService,
                                                final DeleteService deleteService,
                                                final RenameService renameService,
                                                final DataModelService dataModelService,
                                                final WorkItemsEditorService workItemsService,
                                                final KieModuleService moduleService,
                                                final VersionRecordService versionRecordService,
                                                final GuidedDecisionTableGraphEditorService dtableGraphService,
                                                final DecisionTableGuidedToDecisionTableXLSConverter decisionTableGuidedToDecisionTableXLSConverter,
                                                final GuidedDTableGraphResourceTypeDefinition dtableGraphType,
                                                final Event<ResourceOpenedEvent> resourceOpenedEvent,
                                                final GenericValidator genericValidator,
                                                final CommentedOptionFactory commentedOptionFactory,
                                                final SaveAndRenameServiceImpl<GuidedDecisionTable52, Metadata> saveAndRenameService,
                                                final SessionInfo sessionInfo); @PostConstruct void init(); @Override Path create(final Path context,
                       final String fileName,
                       final GuidedDecisionTable52 content,
                       final String comment); @Override GuidedDecisionTable52 load(final Path path); @Override GuidedDecisionTableEditorContent loadContent(final Path path); @Override PackageDataModelOracleBaselinePayload loadDataModel(final Path path); @Override Path save(final Path resource,
                     final GuidedDecisionTable52 model,
                     final Metadata metadata,
                     final String comment); @Override Path saveAndUpdateGraphEntries(final Path resource,
                                          final GuidedDecisionTable52 model,
                                          final Metadata metadata,
                                          final String comment); @Override XLSConversionResult convert(final Path path); @Override void delete(final Path path,
                       final String comment); @Override Path rename(final Path path,
                       final String newName,
                       final String comment); @Override Path copy(final Path path,
                     final String newName,
                     final String comment); @Override Path copy(final Path path,
                     final String newName,
                     final Path targetDirectory,
                     final String comment); @Override @SuppressWarnings("unchecked") String toSource(final Path path,
                           final GuidedDecisionTable52 model); @Override List<ValidationMessage> validate(final Path path,
                                            final GuidedDecisionTable52 content); @Override Path saveAndRename(final Path path,
                              final String newFileName,
                              final Metadata metadata,
                              final GuidedDecisionTable52 content,
                              final String comment); }
GuidedDecisionTableEditorServiceImpl extends KieService<GuidedDecisionTableEditorContent> implements GuidedDecisionTableEditorService { @Override public Path rename(final Path path, final String newName, final String comment) { try { return renameService.rename(path, newName, comment); } catch (Exception e) { throw ExceptionUtilities.handleException(e); } } GuidedDecisionTableEditorServiceImpl(); @Inject  GuidedDecisionTableEditorServiceImpl(final @Named("ioStrategy") IOService ioService,
                                                final CopyService copyService,
                                                final DeleteService deleteService,
                                                final RenameService renameService,
                                                final DataModelService dataModelService,
                                                final WorkItemsEditorService workItemsService,
                                                final KieModuleService moduleService,
                                                final VersionRecordService versionRecordService,
                                                final GuidedDecisionTableGraphEditorService dtableGraphService,
                                                final DecisionTableGuidedToDecisionTableXLSConverter decisionTableGuidedToDecisionTableXLSConverter,
                                                final GuidedDTableGraphResourceTypeDefinition dtableGraphType,
                                                final Event<ResourceOpenedEvent> resourceOpenedEvent,
                                                final GenericValidator genericValidator,
                                                final CommentedOptionFactory commentedOptionFactory,
                                                final SaveAndRenameServiceImpl<GuidedDecisionTable52, Metadata> saveAndRenameService,
                                                final SessionInfo sessionInfo); @PostConstruct void init(); @Override Path create(final Path context,
                       final String fileName,
                       final GuidedDecisionTable52 content,
                       final String comment); @Override GuidedDecisionTable52 load(final Path path); @Override GuidedDecisionTableEditorContent loadContent(final Path path); @Override PackageDataModelOracleBaselinePayload loadDataModel(final Path path); @Override Path save(final Path resource,
                     final GuidedDecisionTable52 model,
                     final Metadata metadata,
                     final String comment); @Override Path saveAndUpdateGraphEntries(final Path resource,
                                          final GuidedDecisionTable52 model,
                                          final Metadata metadata,
                                          final String comment); @Override XLSConversionResult convert(final Path path); @Override void delete(final Path path,
                       final String comment); @Override Path rename(final Path path,
                       final String newName,
                       final String comment); @Override Path copy(final Path path,
                     final String newName,
                     final String comment); @Override Path copy(final Path path,
                     final String newName,
                     final Path targetDirectory,
                     final String comment); @Override @SuppressWarnings("unchecked") String toSource(final Path path,
                           final GuidedDecisionTable52 model); @Override List<ValidationMessage> validate(final Path path,
                                            final GuidedDecisionTable52 content); @Override Path saveAndRename(final Path path,
                              final String newFileName,
                              final Metadata metadata,
                              final GuidedDecisionTable52 content,
                              final String comment);  }