Class: Plumb::Codec::Forms::TrueEncoder

Inherits:
Object
  • Object
show all
Defined in:
lib/plumb/codec.rb

Overview

Booleans are two encoders: a field typed Types::Boolean is the True | False union underneath, and each branch matches its own.

Instance Method Summary collapse

Instance Method Details

#decode(_str) ⇒ Object



768
# File 'lib/plumb/codec.rb', line 768

def decode(_str) = true

#encode(_bool) ⇒ Object



767
# File 'lib/plumb/codec.rb', line 767

def encode(_bool) = 'true'