Examples of ResourceNotFoundException


Examples of br.com.caelum.vraptor.http.route.ResourceNotFoundException

  public void whenRefererDontMatchAControllerShouldForwardToPage() throws Exception {
    PageResult page = mock(PageResult.class);
   
    when(request.getHeader("Referer")).thenReturn("http://localhost:8080/vraptor/no-controller");
    when(request.getContextPath()).thenReturn("/vraptor");
    when(router.parse("/no-controller", HttpMethod.GET, request)).thenThrow(new ResourceNotFoundException());
    doReturn(page).when(result).use(page());

    refererResult.forward();
   
    verify(page).forwardTo("/no-controller");
View Full Code Here

Examples of ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException

      }
      return retVal;
    case Constants.STATUS_HTTP_400_BAD_REQUEST:
      throw new InvalidRequestException("Server responded with: " + IOUtils.toString(theResponseReader));
    case Constants.STATUS_HTTP_404_NOT_FOUND:
      throw new ResourceNotFoundException("Server responded with: " + IOUtils.toString(theResponseReader));
    case Constants.STATUS_HTTP_405_METHOD_NOT_ALLOWED:
      throw new MethodNotAllowedException("Server responded with: " + IOUtils.toString(theResponseReader));
    case Constants.STATUS_HTTP_409_CONFLICT:
      throw new ResourceVersionConflictException("Server responded with: " + IOUtils.toString(theResponseReader));
    case Constants.STATUS_HTTP_412_PRECONDITION_FAILED:
View Full Code Here

Examples of ch.bsgroup.scrumit.utils.ResourceNotFoundException

  @RequestMapping(value="{projectid}/", method=RequestMethod.GET)
  public @ResponseBody SerializableProject getProjectById(@PathVariable int projectid) {
    Project p = this.projectService.findProjectById(projectid);
    if (p == null) {
      throw new ResourceNotFoundException(projectid);
    }
    return new SerializableProject(p.getId(), p.getName(), p.getDescription(), p.getCreationDate());
  }
View Full Code Here

Examples of ch.rolandschaer.ascrblr.util.ResourceNotFoundException

        logger.info("Handling error response " + httpConn.getResponseCode());

        switch (httpConn.getResponseCode()) {

        case HttpURLConnection.HTTP_NOT_FOUND:
            throw new ResourceNotFoundException(httpConn);

        case HttpURLConnection.HTTP_BAD_GATEWAY:
            throw new ResourceNotFoundException(httpConn);

        case HttpURLConnection.HTTP_FORBIDDEN:
            throw new AuthenticationException(httpConn);

        default:
View Full Code Here

Examples of com.alibaba.antx.config.resource.ResourceNotFoundException

            SftpATTRS stat;

            try {
                stat = channel.stat(uri.getPath());
            } catch (SftpException e) {
                throw new ResourceNotFoundException(e);
            }

            return new SshResource(this, channel, uri, stat);
        } catch (RuntimeException e) {
            throw e;
View Full Code Here

Examples of com.alibaba.citrus.service.resource.ResourceNotFoundException

        } catch (ResourceNotFoundException e) {
            xsltRes = null;
        }

        if (xsltRes == null && failIfNotFound) {
            throw new ResourceNotFoundException("Could not find XSLT file for " + this + ", resourceName="
                    + filterMatchResult.getResourceName());
        }

        Resource resource = chain.doFilter(filterMatchResult, options);
View Full Code Here

Examples of com.alibaba.citrus.webx.ResourceNotFoundException

        System.setProperty("productionModeFromSystemProperties", "false");
        prepareWebClient(null);

        TestValve.runnerHolder.set(new ValveRunner() {
            public void run(RunData rundata, PipelineContext pipelineContext) throws Exception {
                throw new ResourceNotFoundException("not found!");
            }
        });

        invokeServlet("/app1/test.htm");
View Full Code Here

Examples of com.amazonaws.services.cloudsearch.model.ResourceNotFoundException

        // marshaller understands.
        String errorCode = parseErrorCode(node);
        if (errorCode == null || !errorCode.equals("ResourceNotFound"))
            return null;

        ResourceNotFoundException e = (ResourceNotFoundException)super.unmarshall(node);
       
        return e;
    }
View Full Code Here

Examples of com.amazonaws.services.cloudsearchv2.model.ResourceNotFoundException

        // marshaller understands.
        String errorCode = parseErrorCode(node);
        if (errorCode == null || !errorCode.equals("ResourceNotFound"))
            return null;

        ResourceNotFoundException e = (ResourceNotFoundException)super.unmarshall(node);
       
        return e;
    }
View Full Code Here

Examples of com.amazonaws.services.cloudwatch.model.ResourceNotFoundException

        // marshaller understands.
        String errorCode = parseErrorCode(node);
        if (errorCode == null || !errorCode.equals("ResourceNotFound"))
            return null;

        ResourceNotFoundException e = (ResourceNotFoundException)super.unmarshall(node);
       
        return e;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.