Class: JSONRPC::Notification

Inherits:
SmartCore::ValueObject
  • Object
show all
Defined in:
lib/jsonrpc/notification.rb

Overview

Since:

  • 0.1.0

Constant Summary collapse

Schema =

Returns:

  • (SmartCore::Schema)

Since:

  • 0.1.0

Class.new(SmartCore::Schema) do
  schema do
    required(:jsonrpc).type(:string).filled
    required(:method).type(:string).filled
    required(:params).type(:hash).filled
  end
end.new

Instance Method Summary collapse

Instance Method Details

#notification?Boolean

Returns:

  • (Boolean)

Since:

  • 0.1.0



34
# File 'lib/jsonrpc/notification.rb', line 34

def notification? = true

#request?Boolean

Returns:

  • (Boolean)

Since:

  • 0.1.0



40
# File 'lib/jsonrpc/notification.rb', line 40

def request? = false