Debug.Unindent 메서드

정의

현재 IndentLevel 을 1씩 줄입니다.

public:
 static void Unindent();
[System.Diagnostics.Conditional("DEBUG")]
public static void Unindent ();
[<System.Diagnostics.Conditional("DEBUG")>]
static member Unindent : unit -> unit
Public Shared Sub Unindent ()
특성

예제

다음 예제에서는 들여쓰기 수준을 설정하고 디버깅 메시지를 내보낸다.

#if defined(DEBUG)
Debug::WriteLine( "List of errors:" );
Debug::Indent();
Debug::WriteLine( "Error 1: File not found" );
Debug::WriteLine( "Error 2: Directory not found" );
Debug::Unindent();
Debug::WriteLine( "End of list of errors" );
#endif
Debug.WriteLine("List of errors:");
Debug.Indent();
Debug.WriteLine("Error 1: File not found");
Debug.WriteLine("Error 2: Directory not found");
Debug.Unindent();
Debug.WriteLine("End of list of errors");
Debug.WriteLine("List of errors:")
Debug.Indent()
Debug.WriteLine("Error 1: File not found")
Debug.WriteLine("Error 2: Directory not found")
Debug.Unindent()
Debug.WriteLine("End of list of errors")

이 예제는 다음과 같은 출력을 생성합니다.

List of errors:
     Error 1: File not found
     Error 2: Directory not found
End of list of errors

적용 대상

추가 정보