code: protected <RESULT> JsonResponse<RESULT> asJson(RESULT result) {
          assertArgumentNotNull("result", result);
          return newJsonResponse(result);
      }
docs: Return response as JSON.
  <pre>
  <span style="color: #70226C">public</span> JsonResponse&lt;SeaResult&gt; index() {
  ...
  <span style="color: #70226C">return</span> asJson(<span style="color: #553000">result</span>);
  }
  </pre>
  @param <RESULT> The type of result serialized to JSON.
  @param result The result object converted to JSON string. (NotNull)
  @return The new-created response for JSON. (NotNull)