Package com.denimgroup.threadfix.data.entities

Examples of com.denimgroup.threadfix.data.entities.RemoteProviderType


  }
 
  @RequestMapping(value="/{typeId}/update", method = RequestMethod.GET)
  public @ResponseBody RestResponse<List<RemoteProviderApplication>> updateApps(@PathVariable("typeId") int typeId) {
    log.info("Processing request for RemoteProviderType update.");
    RemoteProviderType remoteProviderType = remoteProviderTypeService.load(typeId);

        if (remoteProviderType == null) {
            return RestResponse.failure("The requested Remote Provider type was not found.");
        } else {
            List<RemoteProviderApplication> returnApps = remoteProviderApplicationService.updateApplications(remoteProviderType);
View Full Code Here


    }
 
  @RequestMapping(value="/{typeId}/importAll", method = RequestMethod.GET)
  public @ResponseBody RestResponse<String> importAllScans(@PathVariable("typeId") int typeId) {
    log.info("Processing request for RemoteProviderType bulk import.");
    RemoteProviderType remoteProviderType = remoteProviderTypeService.load(typeId);
   
    remoteProviderApplicationService.addBulkImportToQueue(remoteProviderType);
   
    return RestResponse.success("Importing scans.");
  }
View Full Code Here

          " Please ensure that the credentials are valid and that there are applications " +
          "available in the account.";
            log.error(error);
      return RestResponse.failure(error);
    } else if (test.equals(ResponseCode.SUCCESS)) {
            RemoteProviderType type = remoteProviderTypeService.load(typeId);
      return ControllerUtils.writeSuccessObjectWithView(type, AllViews.TableRow.class);
    } else {
            log.warn("Response code was not success but we're still returning success. This shouldn't happen.");
            return RestResponse.failure("Response was " + test);
    }
View Full Code Here

  @PreAuthorize("hasRole('ROLE_CAN_MANAGE_REMOTE_PROVIDERS')")
  @RequestMapping(value="/{typeId}/clearConfiguration", method = RequestMethod.POST)
  public @ResponseBody RestResponse<RemoteProviderType> clearConfiguration(@PathVariable("typeId") int typeId,
      HttpServletRequest request) {
   
    RemoteProviderType type = remoteProviderTypeService.load(typeId);
   
    if (type != null) {
      remoteProviderTypeService.clearConfiguration(typeId);
      ControllerUtils.addSuccessMessage(request, type.getName() + " configuration was cleared successfully.");
            return RestResponse.success(remoteProviderTypeService.load(typeId));
    } else {
            return RestResponse.failure("Unable to find that Remote Provider Type");
        }
  }
View Full Code Here

TOP

Related Classes of com.denimgroup.threadfix.data.entities.RemoteProviderType

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.