OCL Primer

Text Processing and FIX Protocol Libraries

Citing The Work

@book{El_Mahrouss_OCL_org_Primer,
author = {El Mahrouss, Amlal},
year = 2026,
title = {{OCL.org Primer.}},
url = {https://ocl.nekernel.org}
}

Author: Amlal El Mahrouss (amlal at nekernel dot org)

Resources

Requirements

You will need to install:

  • Boost
  • BJam
  • Git
  • MinGW/Clang

The OCL.TProc Primer

Text Processing is a hard task to do — especially for text editors and IDEs. TProc gives you a simple and understandable interface in C++.

int main()
{
    auto rope = tproc::crope("The Quick Brown Fox Jumps Over The Lazy Dog");
    auto new_elem = std::make_unique<tproc::crope>(", and Jumps again.");

    rope.concat(new_elem.get());

    std::cout << *++rope << std::endl;
}

One rope may be converted to string using the following method:

std::basic_string<basic_rope::value_type> basic_rope::to_string();
std::basic_string<basic_rope::value_type> basic_rope::to_string() const;

The OCL.FIX Primer

Take a FIX message:

8=FIX.4.2 | 9=178 | 35=8 | 49=PHLX | 56=PERS | 52=20071123-05:30:00.000 | 
11=ATOMNOCCC9990900 | 20=3 | 150=E | 39=E | 55=MSFT | 167=CS | 54=1 | 
38=15 | 40=2 | 44=15 | 58=PHLX EQUITY TESTING | 59=0 | 47=C | 32=0 | 
31=0 | 151=15 | 14=0 | 6=0 | 10=128 |

Want to parse it? Do the following:

ocl::fix::visitor      basic_visitor;
ocl::fix::range_buffer fix = basic_visitor.visit(default_fix);

You will in return be able to index the message fields now. And print them for example:

ocl::io::print(":value=", fix["35"], "\n");

Next, we'd advise you to read the documentation at https://docs.ocl.nekernel.org to continue further on developing for the OCL.