From a26cc96ba6caa1ac8c0e142c2ec93a20e8fdbdc4 Mon Sep 17 00:00:00 2001 From: Igor Artamonov Date: Fri, 26 Mar 2021 22:54:18 -0400 Subject: [PATCH] solution: improve logging --- .../kotlin/io/emeraldpay/dshackle/upstream/Selector.kt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/main/kotlin/io/emeraldpay/dshackle/upstream/Selector.kt b/src/main/kotlin/io/emeraldpay/dshackle/upstream/Selector.kt index ef3357bf..15945945 100644 --- a/src/main/kotlin/io/emeraldpay/dshackle/upstream/Selector.kt +++ b/src/main/kotlin/io/emeraldpay/dshackle/upstream/Selector.kt @@ -126,6 +126,10 @@ class Selector { "ALLOF[" + matchers.joinToString(",") { it.describeInternal() } + "]" } } + + override fun toString(): String { + return "Matcher: ${describeInternal()}" + } } class MethodMatcher( @@ -138,6 +142,10 @@ class Selector { override fun describeInternal(): String { return "allow method $method" } + + override fun toString(): String { + return "Matcher: ${describeInternal()}" + } } abstract class LabelSelectorMatcher: Matcher {