private Map<String, ShapeModel> constructOutputShapes() {
        // C2j model components
        final Map<String, Operation> operations = getServiceModel().getOperations();
        final Map<String, Shape> c2jShapes = getServiceModel().getShapes();

        // Java shape models, to be constructed
        final Map<String, ShapeModel> javaShapes = new HashMap<String, ShapeModel>();

        for (Map.Entry<String, Operation> entry : operations.entrySet()) {

            String operationName = entry.getKey();
            Operation operation = entry.getValue();

            Output output = operation.getOutput();

            if (output != null) {

                String javaResponseClassName = getNamingStrategy()
                        .getResponseClassName(operationName);

                ShapeModel outputShape = generateOutputShapeModel(operation, javaResponseClassName,
                                                                  c2jShapes);

                if (outputShape.getDocumentation() == null) {
                    outputShape.setDocumentation(output.getDocumentation());
                }

                javaShapes.put(javaResponseClassName, outputShape);
            }
        }

        return javaShapes;
    }
Constructs the result shapes for the intermediate model. Analyzes the operations in the service
model to identify the result shapes that are to be generated.
aws-java-sdk-code-generator/src/main/java/com/amazonaws/codegen/AddOutputShapes.java