C# – Mastering the Basics – Lambda Expressions

Are you one of the people who are easily intimidated by complicated-looking things? I felt a little bit like that when I saw lambda expressions for the first time. But let me tell you this: they really only look scary on the very first look. This article covers the basics of using lambda expressions and should be seen as quick introduction rather than extensive documentation. What are Lambda Expressions? Lambda expressions somehow belong to the anonymous methods. However, they are not called expression instead of method for nothing. They are therefore only similar, not identical. Under a certain circumstance, i. e. the assignment of a delegate, they can be used identically. ...

January 18, 2018 · 4 min · Marcel Jurtz

Xamarin Debugging over WIFI

Xamarin utilizes the Android Debug Bridge (ADB) for debugging on physical devices, which are usually connected over usb. While this feature definitely is useful, it would sometimes be more practical if you could do this over WIFI instead. Luckily, that is possible! You can simple switch between using USB and TCP/IP for debugging. To get started, you need to connect your device via USB to the computer you’re debugging from. I’m using Windows, so the commands I’ll execute the following commands from the commandline (which runs as an administrator), but since they are adb commands, they should be the same on Linux or macOS. ...

January 10, 2018 · 2 min · Marcel Jurtz

C# – Mastering the Basics – Advanced Statements

In todays episode, I’ll show you how to use three advanced statements in C#. I’ll go over the so-called null-conditional operator, the null-coalescing operator and the ternary operator. Null-Conditional Operator You can use the null-conditional operator to prevent _NullReferenceException_s. The basic principle of the operator is to return a value if it is not null, and return null if it is. The following code shows you how to use the operator, which is initiated by a question mark, followed by a dot. ...

December 26, 2017 · 2 min · Marcel Jurtz

C# – Mastering the Basics - Extension Methods

In this series, I go over the very basics of the C# programming language. In todays guide, I will focus on writing custom extension methods for existing, prebuilt classes. You can use extension methods to add custom functionality to classes that are built by others. In my very case, I’d like to extend the functionality of the String class to set its first letter to upper case. I already implemented this functionality in my sideproject CryptoFolio, be sure to check out my article on the topic! ...

December 22, 2017 · 2 min · Marcel Jurtz

C# – Mastering the Basics – Collections

Altough the topic “Collections” matches programming in general, I’ve decided to add it to my series on mastering the basics of C#. For this reason, you will find some content here that is generally applicable, but I will also discuss different language-specific elements. Collections support several different use cases, e. g. searching through a set for objects with certain properties, or iterating through multiple elements by predefined sorting specifications. In the first part of this article, I will cover the two basic types of collections in C#, lists and dictionaries. Then, I will go over the groups of collections you might know from Java: lists, sets and maps. I’d like to describe and compare their characteristics and then implement their functionality in C#. ...

December 19, 2017 · 5 min · Marcel Jurtz