The syntax and rules of extension functions are explained also explained elsewhere, but this page is more tutorial style, covers the background and 'why do we need extensions' and 'what is the benefit', together with simple examples, and even useful examples. The topics are: What are extension functions/properties? What is the advantage of extension functions?… Continue reading Extension Functions & Extension Properties
Python data classes are a new feature in Python 3.7, which is currently in Beta 4 and scheduled for final release in June 2018. However, a simple pip install brings a backport to Python 3.6. The name dataclass sounds like this feature is specifically for classes with data and no methods, but in reality, just… Continue reading Python dataclasses: A revolution
Python class variables offer a key tool for building libraries with DSL type syntax, as well as data shared between all instances of the class. This page explains how Python class variables work and gives some examples of usage. Class & Instance Variables Instances vs the class object Instance Variables Class Variables Using Class and… Continue reading Python Class vs Instance Variables
Not to be confused with the use of the @ symbol, which is an annotation in Kotlin but a decorator in python. Python syntax allows for two flavours of annotations: variable annotations: Introduced in Python 3.6 (2016) function annotations: Introduced in Python 3.0 (2008) Introduction. Both flavours of annotation work in the same manner. They… Continue reading Python Annotations
With Kotlin the term ‘Kotlin DSL’ usually refers to DSLs built in Kotlin using specific Kotlin features (as discussed in 'Kotlin DSLs'), this page, however, is about DSLs in general. Introduction: DSL: The general definition DSL vs 'a DSL' The Types of DSL: External DSL Internal Detached DSL Internal Augmentation DSL Detached vs Internal DSL:… Continue reading What is a DSL?
With Kotlin the term 'DSL' has taken on a specific meaning, and that more specific meaning is explored in another page on Kotlin DSLs like kotlinx.html and how to write them. DSL methodology is a key reason that the capabilities of a language to write domain specific extensions to the language becomes important. This page… Continue reading DSL Methodology: A key software concept.
Yes, building is needed with python. Python normally uses an environment build approach which allows the developer to run code without noticing a build, and simple programs even when shared can seem to need no build. To get started with programming with python, you just don't notice builds, although usually they become important later. But… Continue reading Building: No need with python?