@@ -30,26 +30,23 @@ object Pattern {
30
30
31
31
case class Specification (patternId : Pattern .Id ,
32
32
level : Result .Level ,
33
- category : Specification . Category ,
34
- subcategory : Option [Specification . Subcategory ],
33
+ category : Category ,
34
+ subcategory : Option [Subcategory ],
35
35
parameters : Option [Set [Parameter .Specification ]],
36
36
languages : Option [Set [Language ]] = None ) {
37
- require(subcategory.isEmpty || category == Specification .Category .Security ,
38
- " Security is the only category having subcategories" )
37
+ require(subcategory.isEmpty || category == Category .Security , " Security is the only category having subcategories" )
39
38
}
40
- object Specification {
41
- type Category = Category .Value
42
- object Category extends Enumeration {
43
- val Security, CodeStyle, ErrorProne, Performance, Compatibility, UnusedCode, Complexity, BestPractice ,
44
- Comprehensibility , Duplication , Documentation = Value
45
- }
46
-
47
- type Subcategory = Subcategory .Value
48
-
49
- object Subcategory extends Enumeration {
50
- val XSS, InputValidation, FileAccess, HTTP, Cookies, UnexpectedBehaviour, MassAssignment, InsecureStorage ,
51
- InsecureModulesLibraries , Visibility , CSRF , Android , MaliciousCode , Cryptography , CommandInjection , FirefoxOS ,
52
- Auth , DoS , SQLInjection , Routes , Regex , SSL , Other = Value
53
- }
39
+
40
+ type Category = Category .Value
41
+ object Category extends Enumeration {
42
+ val Security, CodeStyle, ErrorProne, Performance, Compatibility, UnusedCode, Complexity, BestPractice ,
43
+ Comprehensibility , Duplication , Documentation = Value
44
+ }
45
+
46
+ type Subcategory = Subcategory .Value
47
+ object Subcategory extends Enumeration {
48
+ val XSS, InputValidation, FileAccess, HTTP, Cookies, UnexpectedBehaviour, MassAssignment, InsecureStorage ,
49
+ InsecureModulesLibraries , Visibility , CSRF , Android , MaliciousCode , Cryptography , CommandInjection , FirefoxOS , Auth ,
50
+ DoS , SQLInjection , Routes , Regex , SSL , Other = Value
54
51
}
55
52
}
0 commit comments