org.bonitasoft.engine.recorder.Recorder.recordDelete()方法的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(9.6k)|赞(0)|评价(0)|浏览(128)

本文整理了Java中org.bonitasoft.engine.recorder.Recorder.recordDelete方法的一些代码示例,展示了Recorder.recordDelete的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Recorder.recordDelete方法的具体详情如下:
包路径:org.bonitasoft.engine.recorder.Recorder
类名称:Recorder
方法名:recordDelete

Recorder.recordDelete介绍

[英]Delete a record from database
[中]从数据库中删除记录

代码示例

代码示例来源:origin: bonitasoft/bonita-engine

private void deleteSADataInstance(final SADataInstance dataInstance) throws SDeleteDataInstanceException {
  try {
    recorder.recordDelete(new DeleteRecord(dataInstance), "DATA_INSTANCE");
  } catch (final SRecorderException e) {
    throw new SDeleteDataInstanceException("Impossible to delete data instance", e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

private void deleteSADataInstance(final SADataInstance dataInstance) throws SDeleteDataInstanceException {
  try {
    recorder.recordDelete(new DeleteRecord(dataInstance), "DATA_INSTANCE");
  } catch (final SRecorderException e) {
    throw new SDeleteDataInstanceException("Impossible to delete data instance", e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteArchivedProcessInstance(final SAProcessInstance archivedProcessInstance)
    throws SProcessInstanceModificationException {
  try {
    recorder.recordDelete(new DeleteRecord(archivedProcessInstance), PROCESSINSTANCE);
  } catch (final SRecorderException e) {
    throw new SProcessInstanceModificationException(e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

protected void deleteUserTaskData(final STaskContractData taskContractData) throws SContractDataDeletionException {
  try {
    recorder.recordDelete(new DeleteRecord(taskContractData), USERTASK_CONTRACT_DATA);
  } catch (final SRecorderException sre) {
    throw new SContractDataDeletionException(sre);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

private void deleteIcon(Long iconId) throws SBonitaReadException, SRecorderException {
  SIcon icon = getIcon(iconId);
  if (icon == null) {
    return;
  }
  recorder.recordDelete(new DeleteRecord(icon), ICON);
}

代码示例来源:origin: bonitasoft/bonita-engine

private void deleteArchivedConnectorInstance(final SAConnectorInstance sConnectorInstance) throws SConnectorInstanceDeletionException {
  try {
    recorder.recordDelete(new DeleteRecord(sConnectorInstance), "CONNECTOR_INSTANCE");
  } catch (final SRecorderException e) {
    throw new SConnectorInstanceDeletionException(e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteMessageInstance(final SMessageInstance messageInstance) throws SMessageModificationException {
  try {
    getRecorder().recordDelete(new DeleteRecord(messageInstance), MESSAGE_INSTANCE);
  } catch (final SRecorderException e) {
    throw new SMessageModificationException(e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteEventTriggerInstance(final STimerEventTriggerInstance eventTriggerInstance) throws SEventTriggerInstanceDeletionException {
  try {
    getRecorder().recordDelete(new DeleteRecord(eventTriggerInstance), EVENT_TRIGGER_INSTANCE);
  } catch (final SRecorderException e) {
    throw new SEventTriggerInstanceDeletionException(e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteDataInstance(final SDataInstance dataInstance) throws SDataInstanceException {
  NullCheckingUtil.checkArgsNotNull(dataInstance);
  try {
    recorder.recordDelete(new DeleteRecord(dataInstance), DATA_INSTANCE);
  } catch (final SRecorderException e) {
    throw new SDeleteDataInstanceException("Impossible to delete data instance", e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void delete(final SComment comment) throws SCommentDeletionException {
  NullCheckingUtil.checkArgsNotNull(comment);
  try {
    recorder.recordDelete(new DeleteRecord(comment), COMMENT);
  } catch (final SRecorderException e) {
    throw new SCommentDeletionException("Can't delete the comment " + comment, e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteWaitingEvent(final SWaitingEvent waitingEvent) throws SWaitingEventModificationException {
  try {
    getRecorder().recordDelete(new DeleteRecord(waitingEvent), EVENT_TRIGGER_INSTANCE);
  } catch (final SRecorderException e) {
    throw new SWaitingEventModificationException(e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteCategory(final long categoryId) throws SCategoryNotFoundException, SCategoryDeletionException {
  final SCategory sCategory = getCategory(categoryId);
  final SCategoryLogBuilder logBuilder = getQueriableLog(ActionType.DELETED, "Deleting a category");
  try {
    recorder.recordDelete(new DeleteRecord(sCategory), CATEGORY);
    initiateLogBuilder(categoryId, SQueriableLog.STATUS_OK, logBuilder, "deleteCategory");
  } catch (final SRecorderException e) {
    initiateLogBuilder(categoryId, SQueriableLog.STATUS_FAIL, logBuilder, "deleteCategory");
    throw new SCategoryDeletionException("Can't delete process category " + sCategory, e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteCategory(final long categoryId) throws SCategoryNotFoundException, SCategoryDeletionException {
  final SCategory sCategory = getCategory(categoryId);
  final SCategoryLogBuilder logBuilder = getQueriableLog(ActionType.DELETED, "Deleting a category");
  try {
    recorder.recordDelete(new DeleteRecord(sCategory), CATEGORY);
    initiateLogBuilder(categoryId, SQueriableLog.STATUS_OK, logBuilder, "deleteCategory");
  } catch (final SRecorderException e) {
    initiateLogBuilder(categoryId, SQueriableLog.STATUS_FAIL, logBuilder, "deleteCategory");
    throw new SCategoryDeletionException("Can't delete process category " + sCategory, e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

private void deleteActor(final SActor actor) throws SActorDeletionException {
  final SActorLogBuilder logBuilder = getQueriableLog(ActionType.DELETED, "Deleting an actor");
  try {
    recorder.recordDelete(new DeleteRecord(actor), ACTOR);
    initiateLogBuilder(actor.getId(), SQueriableLog.STATUS_OK, logBuilder, "deleteActor");
  } catch (final SRecorderException re) {
    initiateLogBuilder(actor.getId(), SQueriableLog.STATUS_FAIL, logBuilder, "deleteActor");
    throw new SActorDeletionException(re);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteProfileEntry(final SProfileEntry profileEntry) throws SProfileEntryDeletionException {
  final SProfileLogBuilderImpl logBuilder = getSProfileLog(ActionType.DELETED, "Deleting profile entry");
  try {
    recorder.recordDelete(new DeleteRecord(profileEntry), ENTRY_PROFILE);
    log(profileEntry.getId(), SQueriableLog.STATUS_OK, logBuilder, "deleteProfileEntry");
  } catch (final SRecorderException re) {
    log(profileEntry.getId(), SQueriableLog.STATUS_FAIL, logBuilder, "deleteProfileEntry");
    throw new SProfileEntryDeletionException(re);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteProcessSupervisor(final SProcessSupervisor supervisor) throws SSupervisorDeletionException {
  final SProcessSupervisorLogBuilder logBuilder = getQueriableLog(ActionType.DELETED, "deleting supervisor");
  try {
    recorder.recordDelete(new DeleteRecord(supervisor), SUPERVISOR);
    log(supervisor.getId(), SQueriableLog.STATUS_OK, logBuilder, "createSupervisor");
  } catch (final SRecorderException e) {
    log(supervisor.getId(), SQueriableLog.STATUS_FAIL, logBuilder, "createSupervisor");
    throw new SSupervisorDeletionException("Can't delete process supervisor " + supervisor, e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteUser(final SUser user) throws SUserDeletionException {
  final String methodName = "deleteUser";
  final SUserLogBuilder logBuilder = getUserLog(ActionType.DELETED, "Deleting user with username " + user.getUserName());
  try {
    recorder.recordDelete(new DeleteRecord(user), USER);
    log(user.getId(), SQueriableLog.STATUS_OK, logBuilder, methodName);
  } catch (final SRecorderException re) {
    log(user.getId(), SQueriableLog.STATUS_FAIL, logBuilder, methodName);
    throw new SUserDeletionException(re);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

@Override
public void deleteUser(final SUser user) throws SUserDeletionException {
  final String methodName = "deleteUser";
  final SUserLogBuilder logBuilder = getUserLog(ActionType.DELETED, "Deleting user with username " + user.getUserName());
  try {
    recorder.recordDelete(new DeleteRecord(user), USER);
    log(user.getId(), SQueriableLog.STATUS_OK, logBuilder, methodName);
  } catch (final SRecorderException re) {
    log(user.getId(), SQueriableLog.STATUS_FAIL, logBuilder, methodName);
    throw new SUserDeletionException(re);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

private void deleteProcessCategoryMapping(final SProcessCategoryMapping mapping) throws SCategoryException {
  final String logMessage = "Deleting a category mapping {processDefinitionId:" + mapping.getProcessId() + " --> categoryId" + mapping.getCategoryId()
      + "}";
  final SCategoryLogBuilder logBuilder = getQueriableLog(ActionType.DELETED, logMessage);
  try {
    recorder.recordDelete(new DeleteRecord(mapping), CATEGORY);
    initiateLogBuilder(mapping.getId(), SQueriableLog.STATUS_OK, logBuilder, "deleteProcessCategoryMapping");
  } catch (final SRecorderException e) {
    initiateLogBuilder(mapping.getId(), SQueriableLog.STATUS_FAIL, logBuilder, "deleteProcessCategoryMapping");
    throw new SCategoryException(e);
  }
}

代码示例来源:origin: bonitasoft/bonita-engine

private void deleteProcessCategoryMapping(final SProcessCategoryMapping mapping) throws SCategoryException {
  final String logMessage = "Deleting a category mapping {processDefinitionId:" + mapping.getProcessId() + " --> categoryId" + mapping.getCategoryId()
      + "}";
  final SCategoryLogBuilder logBuilder = getQueriableLog(ActionType.DELETED, logMessage);
  try {
    recorder.recordDelete(new DeleteRecord(mapping), CATEGORY);
    initiateLogBuilder(mapping.getId(), SQueriableLog.STATUS_OK, logBuilder, "deleteProcessCategoryMapping");
  } catch (final SRecorderException e) {
    initiateLogBuilder(mapping.getId(), SQueriableLog.STATUS_FAIL, logBuilder, "deleteProcessCategoryMapping");
    throw new SCategoryException(e);
  }
}

相关文章