Signed-off-by: Xiao Shenwei xiaoshenwei96@163.com --- providers/libvirt/lib/base.rb | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 providers/libvirt/lib/base.rb
diff --git a/providers/libvirt/lib/base.rb b/providers/libvirt/lib/base.rb new file mode 100644 index 0000000..2e8a74d --- /dev/null +++ b/providers/libvirt/lib/base.rb @@ -0,0 +1,13 @@ +# SPDX-License-Identifier: MulanPSL-2.0+ +# Copyright (c) 2020 Huawei Technologies Co., Ltd. All rights reserved. +# frozen_string_literal: true + +# save common variables and methods +class Base + attr_reader :logger + + def add_logger(logger) + @logger = logger + self + end +end