public static ObjectNode from ( Route route , Json json ) { return json . newObject ( ) . put ( "url" , route . getUrl ( ) ) . put ( "controller" , route . getControllerClass ( ) . getName ( ) ) . put ( "method" , route . getControllerMethod ( ) . getName ( ) ) . put ( "http_method" , route . getHttpMethod ( ) . toString ( ) ) ; }
Creates the JSON representation of the given route .