Libraries · Optimization · Uncategorized

High-Precision Floating-Point Types for Delphi

If Single and Double precision floating-point types don’t cut it for you, then the Neslib.MultiPrecision library may be just the thing. It provides up to 4 times the precision, while still being pretty fast compared to arbitrary precision libraries. Neslib.MultiPrecision Neslib.MultiPrecision is a personal project that adds two additional floating-point types for use with Delphi.… Continue reading High-Precision Floating-Point Types for Delphi

Libraries · Optimization · Tips & Tricks · Uncategorized

An XML DOM with just 8 bytes per node

I present a small XML library that parses or creates XML documents with an extremely light-weight DOM that uses just 8 bytes per node. This post shows some of the interesting algorithms that make this possible. Another XML Library? I know what you are thinking: not another XML library! And you would be right, especially… Continue reading An XML DOM with just 8 bytes per node

Communications · Foundation · Libraries · Uncategorized

Using OpenSSL 1.1.1 with all Delphi target platforms

In this article we are going to discuss how to use the latest version of OpenSsl 1.1.1 with Delphi directly to create X.509 certificates, decode, verify, encode and sign JSON Web Tokens and generate random data. Additionally we will do this in a way that works on Delphi supported platforms including Windows, macOS, iOS, Android… Continue reading Using OpenSSL 1.1.1 with all Delphi target platforms

Libraries · Tips & Tricks · Uncategorized

Wrapping C(++) APIs with Custom Managed Records

Delphi 10.4 introduced Custom Managed Records. In this post we show how you can use this new language feature to wrap third party C(++) APIs in an easy to use model. We also compare this method to some other ways you may have interfaced with C(++) in the past. Ways to interface with C(++) For… Continue reading Wrapping C(++) APIs with Custom Managed Records

Foundation · Libraries · Tips & Tricks · Uncategorized

Using Static Libraries and Assembly with 64-bit macOS

We show how you can use Delphi’s new 64-bit macOS compiler toolchain to link 3rd party static libraries and your own assembly code. We also look into some common linking errors you may run into and how to fix them. LLVM based Compiler and Linker Like all recent Delphi compilers, the new Delphi compiler for… Continue reading Using Static Libraries and Assembly with 64-bit macOS

Foundation · Libraries · Uncategorized

A YAML Library for Delphi

YAML has become a quite popular human-readable data serialization language. Unfortunately, there aren’t many Delphi libraries that provide tools for it. I hope to fill this void with Neslib.Yaml, a personal project build on top of LibYaml that provides support for parsing and generating YAML documents and streams. LibYaml Bindings Neslib.Yaml uses LibYaml to perform… Continue reading A YAML Library for Delphi

Foundation · Libraries · Uncategorized

Query JSON documents with JSONPath

We have extended our JSON and BSON library with functionality to query JSON documents using an XPath-like query language called JSONPath. About JSONPath JSONPath is to JSON what XPath is to XML. It enables you to search for data in a JSON document using a simple query language somewhat similar to XPath. Although there is… Continue reading Query JSON documents with JSONPath

Communications · Libraries

Creating high-performance UDP servers on Windows and Linux

There is a lack of information available on building highly scalable UDP servers on the Internet.  What information exists, often falls short of best practices.  UDP servers are the central backbone of many video game servers and streaming services, but very few good examples or discussions exist on how to construct them on Windows and Linux.  This article… Continue reading Creating high-performance UDP servers on Windows and Linux

Libraries · Tips & Tricks · Uncategorized

Chet – A C Header Translator powered by Clang

In my previous post on libclang for Delphi, I mentioned an obvious use case for libclang: to build a (better) C-to-Pascal header converter. I also suggested I may provide such a tool in the future. Well, the future is here and I put my money where my mouth is. The result is Chet, a sort of… Continue reading Chet – A C Header Translator powered by Clang