You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/checks/number-methods.md
+3-10Lines changed: 3 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,29 +1,22 @@
1
-
# code pal for ABAP
2
-
3
1
[code pal for ABAP](../../README.md) > [Documentation](../check_documentation.md) > [Number of Methods Check](number-methods.md)
4
2
5
3
## Number of Methods Check
6
4
7
5
### What is the Intent of the Check?
8
6
9
-
The "Number of Methods" Check counts the number of methods up to a maximum. If there are too many methods in a class, it is probable that the [single responsibility principle](https://en.wikipedia.org/wiki/Single_responsibility_principle) is violated.
7
+
This check counts the number of methods up to a maximum. If there are too many methods in a class, it is an indicator that the [single responsibility principle](https://en.wikipedia.org/wiki/Single_responsibility_principle) is violated.
10
8
11
9
### How does the check work?
12
10
13
-
This check counts `METHODS` and `CLASS-METHODS` within a global or local, `CLASS DEFINITION` or `INTERFACE`. Inherited methods aren't counted, however `REDEFINED METHODS` increment the counter.
14
-
15
-
### Which attributes can be maintained?
16
-
17
-

11
+
This check counts `METHODS` and `CLASS-METHODS` within a global or local, `CLASS DEFINITION` or `INTERFACE`. Inherited methods are not counted, however `REDEFINED METHODS` increment the counter.
18
12
19
13
### How to solve the issue?
20
14
21
15
The solution is to split the class or interface into multiple classes or interfaces which then contain less methods.
22
16
23
17
### What to do in case of exception?
24
18
25
-
You can suppress Code Inspector findings generated by this check using the pseudo comment `"#EC NUMBER_METHODS`.
26
-
The pseudo comment must be placed right after the class definition header.
19
+
In exceptional cases, you can suppress this finding by using the pseudo comment `"#EC NUMBER_METHODS` which should be placed right after the class definition header:
0 commit comments