Permalink
Browse files

small documentation updates

  • Loading branch information...
1 parent f2daf24 commit 321afb22656d7b5914330c3a8af0b8d4d804400a @movitto committed Aug 30, 2012
Showing with 9 additions and 4 deletions.
  1. +3 −0 lib/rjr.rb
  2. +2 −0 lib/rjr/dispatcher.rb
  3. +2 −2 lib/rjr/message.rb
  4. +2 −2 lib/rjr/ws_node.rb
View
@@ -3,6 +3,9 @@
# Copyright (C) 2010-2012 Mohammed Morsi <mo@morsi.org>
# Licensed under the Apache License, Version 2.0
+# rjr - Ruby Json Rpc
+module RJR ; end
+
require 'rjr/common'
require 'rjr/errors'
require 'rjr/thread_pool'
@@ -225,6 +225,8 @@ def self.init_handlers
# val
# }
#
+ # # TODO define yard macros to construct documentation for a rjr based api
+ # from calls to add_handler
def self.add_handler(method_names, args = {}, &handler)
method_names = Array(method_names) unless method_names.is_a?(Array)
@@handlers ||= {}
View
@@ -79,7 +79,7 @@ def initialize(args = {})
# Class helper to determine if the specified string is a valid json-rpc
# method request
# @param [String] message string message to check
- # @returns [true,false] indicating if message is request message
+ # @return [true,false] indicating if message is request message
def self.is_request_message?(message)
begin
# TODO log error
@@ -168,7 +168,7 @@ def initialize(args = {})
# Class helper to determine if the specified string is a valid json-rpc
# method response
# @param [String] message string message to check
- # @returns [true,false] indicating if message is response message
+ # @return [true,false] indicating if message is response message
def self.is_response_message?(message)
begin
json = JSON.parse(message)
View
@@ -39,9 +39,9 @@ def invoke(callback_method, *data)
end
end
-# Web node definition, listen for and invoke json-rpc requests via web sockets
+# Web socket node definition, listen for and invoke json-rpc requests via web sockets
#
-# Clients should specify the hostname / port when listening for requests.
+# Clients should specify the hostname / port when listening for and invoking requests.
#
# *note* the RJR javascript client also supports sending / receiving json-rpc
# messages over web sockets

0 comments on commit 321afb2

Please sign in to comment.