From 8448d730837ef6ce3ebc9a869a04560a9e19ae0b Mon Sep 17 00:00:00 2001 From: Natalia Portillo Date: Sat, 2 Nov 2019 02:20:49 +0000 Subject: [PATCH] Move Console to a separate repository. --- .gitmodules | 3 + .../.idea/contentModel.xml | 17 +- DiscImageChef.Console | 1 + DiscImageChef.Console/DicConsole.cs | 171 ------------------ .../DiscImageChef.Console.csproj | 91 ---------- 5 files changed, 8 insertions(+), 275 deletions(-) create mode 160000 DiscImageChef.Console delete mode 100644 DiscImageChef.Console/DicConsole.cs delete mode 100644 DiscImageChef.Console/DiscImageChef.Console.csproj diff --git a/.gitmodules b/.gitmodules index 267806b63..bfcf3b7b8 100644 --- a/.gitmodules +++ b/.gitmodules @@ -7,3 +7,6 @@ [submodule "DiscImageChef.CommonTypes"] path = DiscImageChef.CommonTypes url = git@github.com:discimagechef/DiscImageChef.CommonTypes.git +[submodule "DiscImageChef.Console"] + path = DiscImageChef.Console + url = git@github.com:discimagechef/DiscImageChef.Console.git diff --git a/.idea/.idea.DiscImageChef/.idea/contentModel.xml b/.idea/.idea.DiscImageChef/.idea/contentModel.xml index 23880ffaa..1ac296280 100644 --- a/.idea/.idea.DiscImageChef/.idea/contentModel.xml +++ b/.idea/.idea.DiscImageChef/.idea/contentModel.xml @@ -98,6 +98,7 @@ + @@ -188,22 +189,12 @@ + + - - - - - - - - - - - - - + diff --git a/DiscImageChef.Console b/DiscImageChef.Console new file mode 160000 index 000000000..9ba23c570 --- /dev/null +++ b/DiscImageChef.Console @@ -0,0 +1 @@ +Subproject commit 9ba23c57007124780b25a2e3de9e1ef84e152c5a diff --git a/DiscImageChef.Console/DicConsole.cs b/DiscImageChef.Console/DicConsole.cs deleted file mode 100644 index aac7dd13d..000000000 --- a/DiscImageChef.Console/DicConsole.cs +++ /dev/null @@ -1,171 +0,0 @@ -// /*************************************************************************** -// The Disc Image Chef -// ---------------------------------------------------------------------------- -// -// Filename : DicConsole.cs -// Author(s) : Natalia Portillo -// -// Component : Console. -// -// --[ Description ] ---------------------------------------------------------- -// -// Handlers for normal, verbose and debug consoles. -// -// --[ License ] -------------------------------------------------------------- -// -// This library is free software; you can redistribute it and/or modify -// it under the terms of the GNU Lesser General Public License as -// published by the Free Software Foundation; either version 2.1 of the -// License, or (at your option) any later version. -// -// This library is distributed in the hope that it will be useful, but -// WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU -// Lesser General Public License for more details. -// -// You should have received a copy of the GNU Lesser General Public -// License along with this library; if not, see . -// -// ---------------------------------------------------------------------------- -// Copyright © 2011-2019 Natalia Portillo -// ****************************************************************************/ - -namespace DiscImageChef.Console -{ - public delegate void WriteLineHandler(string format, params object[] arg); - - public delegate void ErrorWriteLineHandler(string format, params object[] arg); - - public delegate void VerboseWriteLineHandler(string format, params object[] arg); - - public delegate void DebugWriteLineHandler(string format, params object[] arg); - - public delegate void WriteHandler(string format, params object[] arg); - - public delegate void ErrorWriteHandler(string format, params object[] arg); - - public delegate void VerboseWriteHandler(string format, params object[] arg); - - public delegate void DebugWriteHandler(string format, params object[] arg); - - public delegate void DebugWithModuleWriteLineHandler(string module, string format, params object[] arg); - - /// - /// Implements a console abstraction that defines four level of messages that can be routed to different consoles: - /// standard, error, verbose and debug. - /// - public static class DicConsole - { - public static event WriteLineHandler WriteLineEvent; - public static event ErrorWriteLineHandler ErrorWriteLineEvent; - public static event VerboseWriteLineHandler VerboseWriteLineEvent; - public static event DebugWriteLineHandler DebugWriteLineEvent; - public static event DebugWithModuleWriteLineHandler DebugWithModuleWriteLineEvent; - - public static event WriteHandler WriteEvent; - public static event ErrorWriteHandler ErrorWriteEvent; - public static event VerboseWriteHandler VerboseWriteEvent; - public static event DebugWriteHandler DebugWriteEvent; - - public static void WriteLine(string format, params object[] arg) - { - WriteLineEvent?.Invoke(format, arg); - } - - public static void ErrorWriteLine(string format, params object[] arg) - { - ErrorWriteLineEvent?.Invoke(format, arg); - } - - public static void VerboseWriteLine(string format, params object[] arg) - { - VerboseWriteLineEvent?.Invoke(format, arg); - } - - public static void DebugWriteLine(string module, string format, params object[] arg) - { - DebugWriteLineEvent?.Invoke("DEBUG (" + module + "): " + format, arg); - DebugWithModuleWriteLineEvent?.Invoke(module, format, arg); - } - - public static void WriteLine() - { - WriteLineEvent?.Invoke("", null); - } - - public static void ErrorWriteLine() - { - ErrorWriteLineEvent?.Invoke("", null); - } - - public static void VerboseWriteLine() - { - VerboseWriteLineEvent?.Invoke("", null); - } - - public static void DebugWriteLine() - { - DebugWriteLineEvent?.Invoke("", null); - } - - public static void Write(string format, params object[] arg) - { - WriteEvent?.Invoke(format, arg); - } - - public static void ErrorWrite(string format, params object[] arg) - { - ErrorWriteEvent?.Invoke(format, arg); - } - - public static void VerboseWrite(string format, params object[] arg) - { - VerboseWriteEvent?.Invoke(format, arg); - } - - public static void DebugWrite(string module, string format, params object[] arg) - { - DebugWriteEvent?.Invoke("DEBUG (" + module + "): " + format, arg); - } - - public static void Write() - { - WriteEvent?.Invoke("", null); - } - - public static void ErrorWrite() - { - ErrorWriteEvent?.Invoke("", null); - } - - public static void VerboseWrite() - { - VerboseWriteEvent?.Invoke("", null); - } - - public static void DebugWrite() - { - DebugWriteEvent?.Invoke("", null); - } - - public static void WriteLine(string format) - { - WriteLineEvent?.Invoke("{0}", format); - } - - public static void ErrorWriteLine(string format) - { - ErrorWriteLineEvent?.Invoke("{0}", format); - } - - public static void VerboseWriteLine(string format) - { - VerboseWriteLineEvent?.Invoke("{0}", format); - } - - public static void DebugWriteLine(string module, string format) - { - DebugWriteLineEvent?.Invoke("{0}", "DEBUG (" + module + "): " + format); - } - } -} \ No newline at end of file diff --git a/DiscImageChef.Console/DiscImageChef.Console.csproj b/DiscImageChef.Console/DiscImageChef.Console.csproj deleted file mode 100644 index 03ad4ba60..000000000 --- a/DiscImageChef.Console/DiscImageChef.Console.csproj +++ /dev/null @@ -1,91 +0,0 @@ - - - - Debug - AnyCPU - 2.0 - {CCAA7AFE-C094-4D82-A66D-630DE8A3F545} - Library - DiscImageChef.Console - DiscImageChef.Console - $(Version) - false - true - 4.5.99.1693 - Claunia.com - Copyright © 2011-2019 Natalia Portillo - The Disc Image Chef - DiscImageChef.Console - $(Version) - net461;netstandard2.0;netcoreapp2.0 - - - $(Version)-{chash:8} built by {mname} in $(Configuration){!:, modified} - true - true - - - true - full - false - bin\Debug - DEBUG; - prompt - 4 - false - - - full - true - bin\Release - prompt - 4 - false - - - - - - - - - - LICENSE.LGPL - - - - - - - - - - - - - - - - - - - - - /Library/Frameworks/Mono.framework/Versions/Current/lib/mono - /usr/lib/mono - /usr/local/lib/mono - - $(BaseFrameworkPathOverrideForMono)/4.0-api - $(BaseFrameworkPathOverrideForMono)/4.5-api - $(BaseFrameworkPathOverrideForMono)/4.5.1-api - $(BaseFrameworkPathOverrideForMono)/4.5.2-api - $(BaseFrameworkPathOverrideForMono)/4.6-api - $(BaseFrameworkPathOverrideForMono)/4.6.1-api - $(BaseFrameworkPathOverrideForMono)/4.6.2-api - $(BaseFrameworkPathOverrideForMono)/4.7-api - $(BaseFrameworkPathOverrideForMono)/4.7.1-api - true - - $(FrameworkPathOverride)/Facades;$(AssemblySearchPaths) - - \ No newline at end of file