Option Strict On

Imports System.IO

Namespace Mbark.Debugging

    Public Module MbarkDebug
        Public Sub Break(ByVal ex As Exception)
#If DEBUG Then
            Debugger.Break()
#Else
            Rethrow ex
#End If
        End Sub

        Public Sub Break()
#If DEBUG Then
            Debugger.Break()
#End If
        End Sub



        Public Sub WriteLine(ByVal message As String)
#If DEBUG Then
            Console.WriteLine(message)
#End If
        End Sub

        Public Sub Write(ByVal message As String)
#If DEBUG Then
            Console.Write(message)
#End If
        End Sub

        Public Sub WriteLine(ByVal ex As Exception)
#If DEBUG Then
            Console.WriteLine(Mbark.UnwindAllMessages(ex))
#End If
        End Sub

    End Module
End Namespace

