• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

PolyMathOrg / PolyMath / 4385132063

pending completion
4385132063

push

github

GitHub
Merge pull request #316 from jecisc/divers-cleanings

2977 of 2977 new or added lines in 214 files covered. (100.0%)

19725 of 24212 relevant lines covered (81.47%)

2.44 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/Math-ODE/PMExplicitSolverSubscriber.class.st
1
"
2
An ExplicitSolverSubscriber implements the minimal behavior to attach to an ODESolver and receive ExplicitSolverAnnouncements. Subclasses should override block to determine appropriate behavior.
3

4
"
5
Class {
6
        #name : #PMExplicitSolverSubscriber,
7
        #superclass : #Object,
8
        #instVars : [
9
                'announcers',
10
                'block'
11
        ],
12
        #category : #'Math-ODE'
13
}
14

15
{ #category : #'instance creation' }
16
PMExplicitSolverSubscriber class >> forAnnouncer: anAnnouncer [
×
17
        ^ self new forAnnouncer: anAnnouncer
×
18
]
×
19

20
{ #category : #'instance creation' }
21
PMExplicitSolverSubscriber class >> forSolver: anODESolver [
×
22
        ^ self forAnnouncer: anODESolver announcer
×
23
]
×
24

25
{ #category : #accessing }
26
PMExplicitSolverSubscriber >> announcers [
×
27

×
28
        ^ announcers
×
29
]
×
30

31
{ #category : #accessing }
32
PMExplicitSolverSubscriber >> block [
×
33
        ^ block
×
34
]
×
35

36
{ #category : #accessing }
37
PMExplicitSolverSubscriber >> block: aFormatBlock [
×
38
        block := aFormatBlock
×
39
]
×
40

41
{ #category : #accessing }
42
PMExplicitSolverSubscriber >> defaultBlock [
43
        ^ self subclassResponsibility
44
]
45

46
{ #category : #subscription }
47
PMExplicitSolverSubscriber >> forAnnouncer: anAnnouncer [
×
48
        anAnnouncer when: PMExplicitSolverAnnouncement do: self block.
×
49
        announcers add: anAnnouncer
×
50
]
×
51

52
{ #category : #initialization }
53
PMExplicitSolverSubscriber >> initialize [
×
54
        super initialize.
×
55
        announcers := IdentitySet new.
×
56
        block := self defaultBlock.
×
57
        ^ self
×
58
]
×
59

60
{ #category : #initialization }
61
PMExplicitSolverSubscriber >> release [
×
62
        "stop announcers from sending messages"
×
63
        self unsubscribe.
×
64
        super release
×
65
]
×
66

67
{ #category : #subscription }
68
PMExplicitSolverSubscriber >> unsubscribe [
×
69
        announcers do: [:ea | self unsubscribe: ea]
×
70
]
×
71

72
{ #category : #subscription }
73
PMExplicitSolverSubscriber >> unsubscribe: anAnnouncer [
×
74
        anAnnouncer unsubscribe: self.
×
75
        announcers remove: anAnnouncer ifAbsent: []
×
76
]
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc