isNameUnique(String)   A
last analyzed

Complexity

Conditions 1

Size

Total Lines 2
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 2
c 1
b 0
f 0
dl 0
loc 2
rs 10
1
package io.github.ro4.spelvalidation;
2
3
import org.springframework.context.annotation.Bean;
4
import org.springframework.context.annotation.Configuration;
5
import org.springframework.stereotype.Service;
6
7
@Configuration
8
public class TestConfiguration {
9
    @Bean
10
    public SimpleService simpleService() {
11
        return new SimpleService();
12
    }
13
14
    @Bean
15
    public SpELValidator spELValidator() {
16
        return new SpELValidator();
17
    }
18
19
20
    @Service
21
    @SuppressWarnings("unused")
22
    public static class SimpleService {
23
        public boolean isNameUnique(String name) {
24
            return "hello".equals(name);
25
        }
26
    }
27
}
28