Class: Contracts::Builtin::KeywordArgs
- Inherits:
-
CallableClass
- Object
- CallableClass
- Contracts::Builtin::KeywordArgs
- Defined in:
- lib/contracts/builtin_contracts.rb
Overview
Use this for specifying contracts for keyword arguments Example: KeywordArgs[ e: Range, f: Optional[Num] ]
Instance Method Summary collapse
-
#initialize(options) ⇒ KeywordArgs
constructor
A new instance of KeywordArgs.
- #inspect ⇒ Object
- #to_s ⇒ Object
- #valid?(hash) ⇒ Boolean
Methods inherited from CallableClass
Constructor Details
#initialize(options) ⇒ KeywordArgs
Returns a new instance of KeywordArgs.
425 426 427 |
# File 'lib/contracts/builtin_contracts.rb', line 425 def initialize() @options = end |
Instance Method Details
#inspect ⇒ Object
441 442 443 |
# File 'lib/contracts/builtin_contracts.rb', line 441 def inspect to_s end |
#to_s ⇒ Object
437 438 439 |
# File 'lib/contracts/builtin_contracts.rb', line 437 def to_s "KeywordArgs[#{}]" end |