Wrapping C APIs in Python

When working in Python, there are times when you need more speed than it can deliver. These times to reach for C/C++. The interop between the languages is clean, minimal, and very fast. Here, I’ll give a quick example with a little commentary to assist with understanding the basics. First, the basic problem. Let’s sayContinue reading “Wrapping C APIs in Python”

Accepting Invalid SSL Certificates in .NET WCF Clients

There are times when SSL certificates are used to verify identity and to provide TLS and there are cases when only the wire encryption matters.  In the later case, I sometimes need to be able handle server certificates that are not valid by SSL’s standard rules.  This could be because the cert is not signedContinue reading “Accepting Invalid SSL Certificates in .NET WCF Clients”

XML Interoperability of Serialized Entities in Java and .NET

Abstract: In order to exchange structured data directly between the platforms, we must be able to easily take the marshalled or serialized definition of the object and turn it into an object in memory.  There are standard ways of marshalling of objects to XML in both Java and .NET.  I have found it a littleContinue reading “XML Interoperability of Serialized Entities in Java and .NET”

Hacking C#’s Lambda Expressions Into Hash Rockets

As I move between C# and Ruby, I have found my brain’s internal syntax parser always needing to switch gears and repurpose its understanding of Fat Arrow, =>. In Ruby, it provides a visually salient means of expressing key => value pairing within a Hash. C# on the other hand uses it to indicate theContinue reading “Hacking C#’s Lambda Expressions Into Hash Rockets”

C# Deserves A Better Message Passing API

The structured programming model of C# is decisive and straightforward. There is generally one or only a handful of idiomatically correct ways to facilitate a particular design need. In the case of API design, the language’s conception of access modifiers is fundamental. Exposures of behaviors to client code are controlled by applying public, private, orContinue reading “C# Deserves A Better Message Passing API”