Package com.knappsack.swagger4springweb.testModels

Examples of com.knappsack.swagger4springweb.testModels.MockPojo


    @RequestMapping(value = "/resource1", method = RequestMethod.GET, produces = "application/json")
    public
    @ResponseBody
    MockPojo apiOperation3ToInclude() {
        return new MockPojo();
    }
View Full Code Here


    @RequestMapping(value = "/resource2", method = RequestMethod.GET, produces = "application/json")
    @ApiExclude
    public
    @ResponseBody
    MockPojo apiOperation4ToExclude() {
        return new MockPojo();
    }
View Full Code Here

    @ResponseBody
    List<MockPojo> getTestPojos(HttpServletRequest request,
                                @ApiParam(name = "testVariable", value = "String")
                                @PathVariable String testVariable) {
        List<MockPojo> mockPojos = new ArrayList<MockPojo>();
        MockPojo mockPojo = new MockPojo();
        mockPojo.setId(1);
        mockPojo.setName("Test Pojo");
        mockPojo.setDescription("This is a test pojo for testing purposes.");
        mockPojos.add(mockPojo);

        return mockPojos;
    }
View Full Code Here

    public
    @ResponseBody
    List<MockPojo> getTestPojosNoSwaggerAnnotations(HttpServletRequest request,
                                                    @PathVariable String testVariable) {
        List<MockPojo> mockPojos = new ArrayList<MockPojo>();
        MockPojo mockPojo = new MockPojo();
        mockPojo.setId(1);
        mockPojo.setName("Test Pojo");
        mockPojo.setDescription("This is a test pojo for testing purposes.");
        mockPojos.add(mockPojo);

        return mockPojos;
    }
View Full Code Here

                                            @RequestParam Double doubleVariable,
                                            @RequestParam Date date) {
        List<MockPojo> mockPojos = new ArrayList<MockPojo>();

        if (testVariable != null && !testVariable.isEmpty()) {
            MockPojo mockPojo = new MockPojo();
            mockPojo.setId(1);
            mockPojo.setName("Test Pojo");
            mockPojo.setDescription("This is a test pojo for testing purposes.");
            mockPojos.add(mockPojo);
        }

        return mockPojos;
    }
View Full Code Here

    @ResponseBody
    List<MockPojo> getTestPojoRequestHeader(HttpServletRequest request,
                                            @RequestHeader(("Accept-Encoding")) String encoding) {
        List<MockPojo> mockPojos = new ArrayList<MockPojo>();

        MockPojo mockPojo = new MockPojo();
        mockPojo.setId(1);
        mockPojo.setName("Test Pojo");
        mockPojo.setDescription("This is a test pojo for testing purposes.");
        mockPojos.add(mockPojo);

        return mockPojos;
    }
View Full Code Here

TOP

Related Classes of com.knappsack.swagger4springweb.testModels.MockPojo

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.