1 -- Created on: 2001-01-06
2 -- Created by: OCC Team
3 -- Copyright (c) 2001-2014 OPEN CASCADE SAS
5 -- This file is part of Open CASCADE Technology software library.
7 -- This library is free software; you can redistribute it and/or modify it under
8 -- the terms of the GNU Lesser General Public License version 2.1 as published
9 -- by the Free Software Foundation, with special exception defined in the file
10 -- OCCT_LGPL_EXCEPTION.txt. Consult the file LICENSE_LGPL_21.txt included in OCCT
11 -- distribution for complete text of the license and disclaimer of any warranty.
13 -- Alternatively, this file may be used under the terms of Open CASCADE
14 -- commercial license or contractual agreement.
16 deferred class Printer from Message inherits TShared from MMgt
18 ---Purpose: Abstract interface class defining printer as output context for text messages
20 -- The message, besides being text string, has associated gravity
21 -- level, which can be used by printer to decide either to process a message or ignore it.
26 AsciiString from TCollection,
27 ExtendedString from TCollection
31 Initialize returns Printer from Message;
32 ---Purpose: Empty constructor with Message_Info trace level
34 GetTraceLevel (me) returns Gravity from Message;
36 ---Purpose: Return trace level used for filtering messages;
37 -- messages with lover gravity will be ignored.
39 SetTraceLevel (me : mutable;
40 theTraceLevel : Gravity from Message);
42 ---Purpose: Set trace level used for filtering messages.
43 -- By default, trace level is Message_Info, so that all messages are output
46 theString : ExtendedString from TCollection;
47 theGravity : Gravity from Message;
48 theToPutEol : Boolean) is deferred;
49 ---Purpose: Send a string message with specified trace level.
50 -- The parameter theToPutEol specified whether end-of-line should be added to the end of the message.
51 -- This method must be redefined in descentant.
55 theGravity : Gravity from Message;
56 theToPutEol : Boolean) is virtual;
57 ---Purpose: Send a string message with specified trace level.
58 -- The parameter theToPutEol specified whether end-of-line should be added to the end of the message.
59 -- Default implementation calls first method Send().
62 theString : AsciiString from TCollection;
63 theGravity : Gravity from Message;
64 theToPutEol : Boolean) is virtual;
65 ---Purpose: Send a string message with specified trace level.
66 -- The parameter theToPutEol specified whether end-of-line should be added to the end of the message.
67 -- Default implementation calls first method Send().
71 myTraceLevel : Gravity from Message is protected;