Commit Graph

34 Commits

Author SHA1 Message Date
Atgeirr Flø Rasmussen
0283536ac4 Finish revision of logging. 2016-10-19 15:08:46 +02:00
Atgeirr Flø Rasmussen
35514c0aa0 Improve MessageLimiter class. 2016-10-19 13:11:13 +02:00
Liu Ming
9020c7cb36 Support category limits setting. 2016-10-18 19:26:06 +08:00
Liu Ming
8de9921890 file name and line number are in a new line. 2016-06-15 11:20:34 +08:00
Liu Ming
eb654771d9 fix test issue. 2016-06-13 14:28:27 +08:00
Liu Ming
af9b0977f6 add two new constructors. 2016-06-08 15:30:52 +02:00
Liu Ming
46b7b2a114 fix test issues with prefix. 2016-06-08 13:52:40 +02:00
Liu Ming
e89bef777a fix prefix testing. 2016-06-08 13:40:19 +02:00
Liu Ming
b4c9f82585 Let Note has its own prefix. 2016-06-08 10:55:38 +02:00
Liu Ming
aa51ea67bc change Prtinfo to Note. 2016-06-08 09:00:24 +02:00
Liu Ming
314a3ffec7 Add a new message type that allows messages only go into print file. 2016-06-07 14:08:33 +02:00
Liu Ming
199324363b fix color test. 2016-06-06 15:29:09 +02:00
Atgeirr Flø Rasmussen
c4eb8936a8 No longer emit default Ansi color code for black.
Using no code for black makes it easier to read output with color in editors etc.
2016-05-25 13:56:33 +02:00
Liu Ming
9aba3ac6b3 fix type error. 2016-05-23 15:04:41 +08:00
Liu Ming
a5afe90659 add simple test for OpmLog::setupSimpleDefaultLog. 2016-05-23 15:01:50 +08:00
Atgeirr Flø Rasmussen
c4c1fe2b30 Rename methods according to code review. 2016-05-18 22:22:10 +02:00
Atgeirr Flø Rasmussen
d2564ff838 Support tagged messages.
This changes the design of the LogBackend class and its subclasses,
now the main virtual method is addTaggedMessage(). The former virtual
method addMessage() is now a regular non-virtual method forwarding to
addTaggedMessage().

You can configure message limiting based on tags by passing a MessageLimiter
to the configureMessageLimiter() method, which will then be used by the
includeMessage() method. That method now takes an additional tag argument.

The most user-visible part of this is that there are new overloads of the
static methods OpmLog::warning(), OpmLog::error() etc, that take message
tags. To tie things together the OpmLog and Logger classes have also gotten
new addTaggedMessage() methods, but they should mostly be used through the
convenience methods such as OpmLog::warning().
2016-05-18 13:27:12 +02:00
Atgeirr Flø Rasmussen
9c84967734 Add MessageLimiter class and test. 2016-05-18 12:11:26 +02:00
Atgeirr Flø Rasmussen
6be41d2fcf Added MessageFormatter. 2016-05-12 10:54:19 +02:00
Atgeirr Flø Rasmussen
474bc50519 Change clearBackends() -> removeAllBackends(). 2016-05-12 10:29:48 +02:00
Atgeirr Flø Rasmussen
2c10045195 Use constants for terminal codes. 2016-05-12 10:28:44 +02:00
Atgeirr Flø Rasmussen
492d31f6cc Added tests for helper functions. 2016-05-09 15:11:34 +02:00
Atgeirr Flø Rasmussen
a6c379db05 Add test exercising coloring feature. 2016-05-09 11:34:08 +02:00
Atgeirr Flø Rasmussen
de87c5a5b5 Make LogBackend pure virtual, also clean and document. 2016-05-09 10:42:28 +02:00
chflo
73ad043006 Moved in logfunctionality from opm-parser 2016-03-17 15:23:18 +01:00
Joakim Hove
84a827e847 Added method to query for number of components. 2016-02-29 11:13:06 +01:00
Atgeirr Flø Rasmussen
af24ed82d3 Merge pull request #77 from joakim-hove/template-cmp
Implemented float comparison with templates
2016-02-19 11:41:00 +01:00
Joakim Hove
25746bb500 Added SimulationDataContainer::setCellDataComponent() 2016-02-19 08:31:13 +01:00
Joakim Hove
48f0513ca1 Implemented float comparison with templates 2016-02-17 21:59:08 +01:00
Joakim Hove
ee6836bd39 Added equal() method to SimulationDataContainer 2016-02-09 15:34:39 +01:00
Joakim Hove
d2ab19f318 Added util/numeric/cmp.cpp 2016-02-09 15:31:40 +01:00
Joakim Hove
c5acc7561d Added methods to register cell and face data. 2016-02-04 14:30:26 +01:00
Joakim Hove
e486194996 Renamed DataContainer -> SimulationDataContainer. 2016-02-04 12:54:23 +01:00
Joakim Hove
c8e8be6db9 Added library opm-common with DataContainer. 2016-02-01 10:33:34 +01:00