mirror of
https://github.com/jlengrand/vert.x.git
synced 2026-03-10 08:51:19 +00:00
Doc fix: use backticks instead of Javadoc code block
Signed-off-by: Thomas Segismont <tsegismont@gmail.com>
This commit is contained in:
@@ -52,14 +52,14 @@ Note that buffers created this way *are empty*. It does not create a buffer fill
|
||||
|
||||
There are two ways to write to a buffer: appending, and random access.
|
||||
In either case buffers will always expand automatically to encompass the bytes. It's not possible to get
|
||||
an {@code IndexOutOfBoundsException} with a buffer.
|
||||
an `IndexOutOfBoundsException` with a buffer.
|
||||
|
||||
==== Appending to a Buffer
|
||||
|
||||
To append to a buffer, you use the {@code appendXXX} methods.
|
||||
To append to a buffer, you use the `appendXXX` methods.
|
||||
Append methods exist for appending various different types.
|
||||
|
||||
The return value of the {@code appendXXX} methods is the buffer itself, so these can be chained:
|
||||
The return value of the `appendXXX` methods is the buffer itself, so these can be chained:
|
||||
|
||||
[source,$lang]
|
||||
----
|
||||
@@ -68,7 +68,7 @@ The return value of the {@code appendXXX} methods is the buffer itself, so these
|
||||
|
||||
==== Random access buffer writes
|
||||
|
||||
You can also write into the buffer at a specific index, by using the {@code setXXX} methods.
|
||||
You can also write into the buffer at a specific index, by using the `setXXX` methods.
|
||||
Set methods exist for various different data types. All the set methods take an index as the first argument - this
|
||||
represents the position in the buffer where to start writing the data.
|
||||
|
||||
@@ -81,7 +81,7 @@ The buffer will always expand as necessary to accommodate the data.
|
||||
|
||||
=== Reading from a Buffer
|
||||
|
||||
Data is read from a buffer using the {@code getXXX} methods. Get methods exist for various datatypes.
|
||||
Data is read from a buffer using the `getXXX` methods. Get methods exist for various datatypes.
|
||||
The first argument to these methods is an index in the buffer from where to get the data.
|
||||
|
||||
[source,$lang]
|
||||
@@ -91,8 +91,8 @@ The first argument to these methods is an index in the buffer from where to get
|
||||
|
||||
=== Working with unsigned numbers
|
||||
|
||||
Unsigned numbers can be read from or appended/set to a buffer with the {@code getUnsignedXXX},
|
||||
{@code appendUnsignedXXX} and {@code setUnsignedXXX} methods. This is useful when implementing a codec for a
|
||||
Unsigned numbers can be read from or appended/set to a buffer with the `getUnsignedXXX`,
|
||||
`appendUnsignedXXX` and `setUnsignedXXX` methods. This is useful when implementing a codec for a
|
||||
network protocol optimized to minimize bandwidth consumption.
|
||||
|
||||
In the following example, value 200 is set at specified position with just one byte:
|
||||
|
||||
@@ -36,7 +36,7 @@ this converter:
|
||||
{@link examples.cli.TypedCLIExamples#example3}
|
||||
----
|
||||
|
||||
For booleans, the boolean values are evaluated to {@code true}: `on`, `yes`, `1`, `true`.
|
||||
For booleans, the boolean values are evaluated to `true`: `on`, `yes`, `1`, `true`.
|
||||
|
||||
If one of your option has an `enum` as type, it computes the set of choices automatically.
|
||||
|
||||
|
||||
@@ -33,7 +33,7 @@ describe options and arguments:
|
||||
As you can see, you can create a new {@link io.vertx.core.cli.CLI} using
|
||||
{@link io.vertx.core.cli.CLI#create(java.lang.String)}. The passed string is the name of the CLI. Once created you
|
||||
can set the summary and description. The summary is intended to be short (one line), while the description can
|
||||
contain more details. Each option and argument are also added on the {@code CLI} object using the
|
||||
contain more details. Each option and argument are also added on the `CLI` object using the
|
||||
{@link io.vertx.core.cli.CLI#addArgument(io.vertx.core.cli.Argument)} and
|
||||
{@link io.vertx.core.cli.CLI#addOption(io.vertx.core.cli.Option)} methods.
|
||||
|
||||
|
||||
@@ -56,7 +56,7 @@ WARNING: most browsers won't support `h2c`, so for serving web sites you should
|
||||
When a server accepts an HTTP/2 connection, it sends to the client its {@link io.vertx.core.http.HttpServerOptions#getInitialSettings initial settings}.
|
||||
The settings define how the client can use the connection, the default initial settings for a server are:
|
||||
|
||||
- {@link io.vertx.core.http.Http2Settings#getMaxConcurrentStreams}: {@code 100} as recommended by the HTTP/2 RFC
|
||||
- {@link io.vertx.core.http.Http2Settings#getMaxConcurrentStreams}: `100` as recommended by the HTTP/2 RFC
|
||||
- the default HTTP/2 settings values for the others
|
||||
|
||||
NOTE: Worker Verticles are not compatible with HTTP/2
|
||||
|
||||
@@ -1081,7 +1081,7 @@ The `start`, `stop` and `list` command are also available from the `vertx` tool.
|
||||
* `java-opts` : the Java Virtual Machine options, uses the `JAVA_OPTS` environment variable if not set.
|
||||
* `redirect-output` : redirect the spawned process output and error streams to the parent process streams.
|
||||
|
||||
If option values contain spaces, don't forget to wrap the value between {@code ""} (double-quotes).
|
||||
If option values contain spaces, don't forget to wrap the value between `""` (double-quotes).
|
||||
|
||||
As the `start` command spawns a new process, the java options passed to the JVM are not propagated, so you **must**
|
||||
use `java-opts` to configure the JVM (`-X`, `-D`...). If you use the `CLASSPATH` environment variable, be sure it
|
||||
@@ -1637,13 +1637,13 @@ and {@link io.vertx.core.impl.launcher.VertxCommandLauncher#unregister(java.lang
|
||||
|
||||
When you use the {@link io.vertx.core.Launcher} class as main class, it uses the following exit code:
|
||||
|
||||
* {@code 0} if the process ends smoothly, or if an uncaught error is thrown
|
||||
* {@code 1} for general purpose error
|
||||
* {@code 11} if Vert.x cannot be initialized
|
||||
* {@code 12} if a spawn process cannot be started, found or stopped. This error code is used by the `start` and
|
||||
* `0` if the process ends smoothly, or if an uncaught error is thrown
|
||||
* `1` for general purpose error
|
||||
* `11` if Vert.x cannot be initialized
|
||||
* `12` if a spawn process cannot be started, found or stopped. This error code is used by the `start` and
|
||||
`stop` command
|
||||
* {@code 14} if the system configuration is not meeting the system requirement (shc as java not found)
|
||||
* {@code 15} if the main verticle cannot be deployed
|
||||
* `14` if the system configuration is not meeting the system requirement (shc as java not found)
|
||||
* `15` if the main verticle cannot be deployed
|
||||
|
||||
== Configuring Vert.x cache
|
||||
|
||||
|
||||
@@ -63,5 +63,5 @@ list can be provided:
|
||||
{@link examples.CoreExamples#configureSearchDomains()}
|
||||
----
|
||||
|
||||
When a search domain list is used, the threshold for the number of dots is {@code 1} or loaded from `/etc/resolv.conf`
|
||||
When a search domain list is used, the threshold for the number of dots is `1` or loaded from `/etc/resolv.conf`
|
||||
on Linux, it can be configured to a specific value with {@link io.vertx.core.dns.AddressResolverOptions#setNdots(int)}.
|
||||
|
||||
@@ -44,7 +44,7 @@ The method invocations can be chained because of the fluent API:
|
||||
|
||||
==== Getting values from a JSON object
|
||||
|
||||
You get values from a JSON object using the {@code getXXX} methods, for example:
|
||||
You get values from a JSON object using the `getXXX` methods, for example:
|
||||
|
||||
[source,java]
|
||||
----
|
||||
@@ -106,7 +106,7 @@ You add entries to a JSON array using the {@link io.vertx.core.json.JsonArray#ad
|
||||
|
||||
==== Getting values from a JSON array
|
||||
|
||||
You get values from a JSON array using the {@code getXXX} methods, for example:
|
||||
You get values from a JSON array using the `getXXX` methods, for example:
|
||||
|
||||
[source,java]
|
||||
----
|
||||
|
||||
Reference in New Issue
Block a user