Global

Type Definitions

Address

Type:
  • Object
Properties:
Name Type Description
ipaddress string The IP address
port number The port for this address
Source:

BodyHandler(buffer)

A BodyHandler is a Handler that accepts a Buffer as it's parameter.
Parameters:
Name Type Description
buffer module:vertx/buffer~Buffer A Buffer object containing the body of the message
Source:

ConnectHandler(netSocket)

A ConnectHandler is a Handler that accepts a module:vertx/net.NetSocket as it's parameter.
Parameters:
Name Type Description
netSocket module:vertx/net.NetSocket The raw socket
Source:

DeploymentId

A DeploymentId is used to identify a specific verticle deployment.
Type:
  • string
Source:
See:

FileProps

Type:
  • Object
Properties:
Name Type Description
creationTime date The date the file was created
lastAccessTime date The date the file was last accessed
lastModifiedTime date The date the file was last modified
isDirectory boolean is the file a directory?
isOther boolean Is the file some other type? I.e. not a directory, regular file or symbolic link
isRegularFile boolean is the file a regular file?
isSymbolicLink boolean is the file a symlink?
size number the size of the file in bytes
Source:

FileSystemProps

Type:
  • Object
Properties:
Name Type Description
totalSpace number The total space on the file system, in bytes
unallocatedSpace number The total unallocated space on the file syste, in bytes
usableSpace number The total usable space on the file system, in bytes
Source:

Flag

Flags used when opening files working with the vert.x FileSystem
Type:
  • number
Source:

Handler()

Vert.x makes heavy use of callback handlers in the API. A basic handler is simply a function that is called when vert.x events are fired, and expects no parameters.
Source:
See:

ListenHandler()

A ListenHandler is a Handler that is notified when a call to module:vertx/net.NetServer#listen has been initiated and the underlying socket has been bound.
Source:

Message

While JSON is the preferred messaging on the event bus, you can send any basic type as a message, for example, string, boolean, etc. can all be passed directly into module:vertx/event_bus.send. You may also send module:vertx/buffer~Buffers and plain old Javascript objects. Objects will be converted to JSON before being placed on the bus.
Type:
Source:
See:

MessageHandler(message)

A MessageHandler is a Handler that responds to messages on the module:vertx/event_bus module. MessageHandlers are called with a Message object as the parameter.
Parameters:
Name Type Description
message Message The message
Source:
See:

MxRecord

Represents a DNS MX record.
Type:
  • Object
Properties:
Name Type Description
priority number The record priority
name string The record name
Source:

PacketHandler(datagramPacket)

A PacketHandler is a Handler that accepts a module:vertx/datagram.DatagramPacket as it's parameter.
Parameters:
Name Type Description
datagramPacket module:vertx/datagram.DatagramPacket The received packet
Source:

RequestHandler(request)

A RequestHandler is a Handler that responds to notifications from objects in the vertx/http module and expects an HttpServerRequest object as its parameter.
Parameters:
Name Type Description
request message The incoming message
Source:
See:
Example
var http = require('vertx/http');
var server = http.createHttpServer();

server.requestHandler( function( request ) {
  // This function is executed for each
  // request event on our server
} );

ResponseHandler(response)

A ResponseHandler is a Handler that accepts a ClientResponse object as it's parameter.
Parameters:
Name Type Description
response module:vertx/http.HttpClientResponse The HTTP client response
Source:

ResultHandler(cause, result)

File system operations are handled asynchronously. The result of the operations are given to a ResultHandler. The ResultHandler is just a Handler that accepts two parameters: 1) an exception object if an error occurred; and 2) the result of the operation, the type of which is determined by the firing event.
Parameters:
Name Type Description
cause Exception This will be null if the operation succeeded
result Object The result of the operation event this handler cares about
Source:

SockJSHandler(sockJSSocket)

A SockJSHandler is a Handler that is called when new SockJSSockets are created. It takes a {module:vertx/sockjs.SockJSSocket} as its only parameter.
Parameters:
Name Type Description
sockJSSocket module:vertx/sockjs.SockJSSocket The socket object
Source:

SrvRecord

Represents a DNS SRV record
Type:
  • Object
Properties:
Name Type Description
priority number The record priority
weight number The record weight
port number The record port
name string The record name
protocol string The record protocol
service string The record service
target string The record target
Source:

TimerId

A TimerId is just a number that identifies a given timer.
Type:
  • number
Source:
See:

UploadHandler(upload)

An UploadHandler is a Handler that accepts a HttpServerFileUpload object as it's parameter. This allows server code to handle and process uploaded files from HTTP clients.
Parameters:
Name Type Description
upload module:vertx/http.HttpServerFileUpload The file being uploaded
Source:

WebSocketHandler(websocket)

A WebSocketHandler is a Handler that accepts a WebSocket as it's parameter.
Parameters:
Name Type Description
websocket module:vertx/http.WebSocket the active WebSocket
Source: