-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add
AsyncFutureCompositeLogger
[feenkcom/gtoolkit#3778]
- Loading branch information
1 parent
23a47d3
commit afde602
Showing
3 changed files
with
69 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
Class { | ||
#name : #AsyncFutureCompositeLogger, | ||
#superclass : #Object, | ||
#traits : 'TAsyncFutureLogger', | ||
#classTraits : 'TAsyncFutureLogger classTrait', | ||
#instVars : [ | ||
'loggers' | ||
], | ||
#category : #'Futures-Executor - Logger' | ||
} | ||
|
||
{ #category : #converting } | ||
AsyncFutureCompositeLogger >> composeWith: aLogger [ | ||
self logger: aLogger. | ||
^ self | ||
] | ||
|
||
{ #category : #testing } | ||
AsyncFutureCompositeLogger >> includesLogger: aLogger [ | ||
^ self loggers anySatisfy: [ :eachLogger | eachLogger includesLogger: aLogger ] | ||
] | ||
|
||
{ #category : #accessing } | ||
AsyncFutureCompositeLogger >> logger: aLogger [ | ||
self loggers: (self loggers copyWith: aLogger) | ||
] | ||
|
||
{ #category : #accessing } | ||
AsyncFutureCompositeLogger >> loggers [ | ||
^ loggers ifNil: [ #() ] | ||
] | ||
|
||
{ #category : #accessing } | ||
AsyncFutureCompositeLogger >> loggers: aCollection [ | ||
loggers := aCollection | ||
] | ||
|
||
{ #category : #logging } | ||
AsyncFutureCompositeLogger >> pendingTask: aPendingTask [ | ||
self loggers do: [ :eachLogger | eachLogger pendingTask: aPendingTask ] | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters