JsonRpcRequest

grapple.json.rpc.JsonRpcRequest
See theJsonRpcRequest companion object
sealed trait JsonRpcRequest extends JsonRpcMessage

Defines JSON-RPC request.

Attributes

See also
Companion
object
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Abstract methods

def isNotification: Boolean

Tests for notification.

Tests for notification.

Attributes

Note

A request is a notification if its identifier is undefined.

def method: String

Gets method.

Gets method.

Attributes

def params: Option[JsonValue]

Gets parameters.

Gets parameters.

Attributes

def put(name: String, value: Any): JsonRpcRequest

Puts attribute.

Puts attribute.

Value parameters

name

attribute name

value

attribute value

Attributes

Returns

new request

Note

If attribute already exists with given name, then its value is replaced.

def remove(name: String): JsonRpcRequest

Removes attribute.

Removes attribute.

Value parameters

name

attribute name

Attributes

Returns

new request

def setAttributes(attributes: Map[String, Any]): JsonRpcRequest

Sets attributes.

Sets attributes.

Attributes

Returns

new request

Inherited methods

def attributes: Map[String, Any]

Gets attributes.

Gets attributes.

Attributes

Note

Attributes are arbitrary values associated with message and are not included in transmission.

Inherited from:
JsonRpcMessage
def get[T](name: String): T

Gets attribute value.

Gets attribute value.

Value parameters

name

attribute name

Attributes

Throws
NoSuchElementException

if attribute does not exist

Inherited from:
JsonRpcMessage
def getOption[T](name: String): Option[T]

Optionally gets attribute value.

Optionally gets attribute value.

Value parameters

name

attribute name

Attributes

Inherited from:
JsonRpcMessage
def getOrElse[T](name: String, default: => T): T

Gets attribute value or returns default if attribute does not exist.

Gets attribute value or returns default if attribute does not exist.

Value parameters

default

default value

name

attribute name

Attributes

Inherited from:
JsonRpcMessage

Gets identifier.

Gets identifier.

Attributes

Inherited from:
JsonRpcMessage
def version: String

Gets JSON-RPC version.

Gets JSON-RPC version.

Attributes

Inherited from:
JsonRpcMessage