class SBAN::Diagnostic

Overview

Reads a SBAN input into a diagnostic string. This consumes the IO and is mostly useful to tests again the example provided in the RFC and ensuring a correct functioning of the SBAN::Lexer.

Defined in:

sban/diagnostic.cr

Constructors

Class Method Summary

Instance Method Summary

Instance methods inherited from class Object

to_sban(io : IO)
to_sban(encoder : SBAN::Encoder)
to_sban : Bytes
to_sban

Class methods inherited from class Object

from_sban(string_or_io) from_sban

Constructor Detail

def self.new(input, context : Nil | Hash(Int32, NamedTuple(name: String)) = nil) #

[View source]

Class Method Detail

def self.to_s(bytes : Bytes) : String #

[View source]

Instance Method Detail

def pretty(pp) #

[View source]
def to_s : String #

Reads the content of the IO and prints out a diagnostic string represation of the input.


[View source]