class Circed::Network::FastMessageParser

Overview

High-performance IRC message parser optimized for server-to-server communication Uses efficient string scanning and minimal allocations

Defined in:

circed/network/fast_message_parser.cr

Constant Summary

PARSE_BUFFER_SIZE = 1024

Pre-allocated buffer for message parsing

Class Method Summary

Class Method Detail

def self.high_priority?(command : String) : Bool #

Check if message is a high-priority server command


[View source]
def self.parse(line : String) : ParsedMessage | Nil #

Parse IRC message with optimized string operations


[View source]
def self.parse_batch(lines : Array(String)) : Array(ParsedMessage) #

Batch parse multiple messages for better performance


[View source]
def self.parse_command_only(line : String) : String | Nil #

Parse only the command part for routing decisions (very fast)


[View source]
def self.valid_format?(line : String) : Bool #

Validate message format without full parsing


[View source]