protected internal virtual void deleteProcessDefinitions(DeleteProcessDefinitionsBuilder builder, bool cascade, bool skipCustomListeners, bool skipIoMappings) { if (skipCustomListeners) { builder = builder.skipCustomListeners(); } if (cascade) { builder = builder.cascade(); } if (skipIoMappings) { builder = builder.skipIoMappings(); } try { builder.delete(); } catch (NotFoundException e) { // rewrite status code from bad request (400) to not found (404) throw new InvalidRequestException(Status.NOT_FOUND, e.Message); } }
public virtual void deleteProcessDefinition(string processDefinitionId, bool cascade, bool skipCustomListeners, bool skipIoMappings) { DeleteProcessDefinitionsBuilder builder = deleteProcessDefinitions().byIds(processDefinitionId); if (cascade) { builder.cascade(); } if (skipCustomListeners) { builder.skipCustomListeners(); } if (skipIoMappings) { builder.skipIoMappings(); } builder.delete(); }