We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Protocol::HTTP::Methods
1 parent d3c27a4 commit d16c545Copy full SHA for d16c545
lib/protocol/http/methods.rb
@@ -50,6 +50,11 @@ class Methods
50
# The PATCH method applies partial modifications to a resource.
51
PATCH = "PATCH"
52
53
+ # Check if the given name is a valid HTTP method, according to this module.
54
+ #
55
+ # Note that this method only knows about the methods defined in this module, however there are many other methods defined in different specifications.
56
57
+ # @returns [Boolean] True if the name is a valid HTTP method.
58
def self.valid?(name)
59
const_defined?(name)
60
rescue NameError
0 commit comments