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

LearnLib / learnlib / 12755372168

13 Jan 2025 08:13PM UTC coverage: 94.2% (-0.002%) from 94.202%
12755372168

push

github

mtf90
cleanup some ADT code

83 of 86 new or added lines in 10 files covered. (96.51%)

1 existing line in 1 file now uncovered.

11776 of 12501 relevant lines covered (94.2%)

1.71 hits per line

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

61.54
/algorithms/active/adt/src/main/java/de/learnlib/algorithm/adt/adt/ADTResetNode.java
1
/* Copyright (C) 2013-2025 TU Dortmund University
2
 * This file is part of LearnLib <https://learnlib.de>.
3
 *
4
 * Licensed under the Apache License, Version 2.0 (the "License");
5
 * you may not use this file except in compliance with the License.
6
 * You may obtain a copy of the License at
7
 *
8
 *     http://www.apache.org/licenses/LICENSE-2.0
9
 *
10
 * Unless required by applicable law or agreed to in writing, software
11
 * distributed under the License is distributed on an "AS IS" BASIS,
12
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
 * See the License for the specific language governing permissions and
14
 * limitations under the License.
15
 */
16
package de.learnlib.algorithm.adt.adt;
17

18
import java.util.Collections;
19
import java.util.Map;
20

21
/**
22
 * Reset node implementation.
23
 *
24
 * @param <S>
25
 *         (hypothesis) state type
26
 * @param <I>
27
 *         input alphabet type
28
 * @param <O>
29
 *         output alphabet type
30
 */
31
public class ADTResetNode<S, I, O> implements ADTNode<S, I, O> {
32

33
    private final ADTNode<S, I, O> successor;
34
    private ADTNode<S, I, O> parent;
35

36
    public ADTResetNode(ADTNode<S, I, O> successor) {
2✔
37
        this.successor = successor;
2✔
38
    }
2✔
39

40
    @Override
41
    public I getSymbol() {
NEW
42
        throw new UnsupportedOperationException("Reset nodes do not have a symbol");
×
43
    }
44

45
    @Override
46
    public void setSymbol(I symbol) {
47
        throw new UnsupportedOperationException("Reset nodes do not have a symbol");
×
48
    }
49

50
    @Override
51
    public ADTNode<S, I, O> getParent() {
52
        return this.parent;
2✔
53
    }
54

55
    @Override
56
    public void setParent(ADTNode<S, I, O> parent) {
57
        this.parent = parent;
2✔
58
    }
2✔
59

60
    @Override
61
    public Map<O, ADTNode<S, I, O>> getChildren() {
62
        return Collections.singletonMap(null, this.successor);
2✔
63
    }
64

65
    @Override
66
    public S getState() {
NEW
67
        throw new UnsupportedOperationException("Reset nodes cannot reference a hypothesis state");
×
68
    }
69

70
    @Override
71
    public void setState(S state) {
72
        throw new UnsupportedOperationException("Reset nodes cannot reference a hypothesis state");
×
73
    }
74

75
    @Override
76
    public NodeType getNodeType() {
77
        return NodeType.RESET_NODE;
2✔
78
    }
79

80
    @Override
81
    public String toString() {
82
        return "reset";
×
83
    }
84
}
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

© 2026 Coveralls, Inc