From fa440d7bfb4e9812e32eccb3cded5869b255bc63 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Wed, 31 Jul 2019 20:44:06 +0100 Subject: [PATCH] code comments in dynamicpipe --- src/nmutil/dynamicpipe.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/nmutil/dynamicpipe.py b/src/nmutil/dynamicpipe.py index 01a3f99e..b6eb2a7e 100644 --- a/src/nmutil/dynamicpipe.py +++ b/src/nmutil/dynamicpipe.py @@ -1,6 +1,18 @@ # SPDX-License-Identifier: LGPL-2.1-or-later # See Notices.txt for copyright information +""" Meta-class that allows a dynamic runtime parameter-selectable "mixin" + +The reasons why this technique is being deployed is because SimpleHandshake +needs to be dynamically replaced at the end-users' choice, without having +to duplicate dozens of classes using multiple-inheritanc "Mix-in" techniques. + +It is however extremely unusual, and has been explicitly limited to this *one* +module. DO NOT try to use this technique elsewhere, it is extremely hard to +understand (meta-class programming). + +""" + from abc import ABCMeta from nmutil.singlepipe import SimpleHandshake -- 2.30.2