Clover icon

sunshower-base

  1. Project Clover database Mon May 7 2018 22:12:38 UTC
  2. Package io.sunshower.persistence.core

File Address.java

 

Coverage histogram

../../../../img/srcFileCovDistChart0.png
49% of files have more coverage

Code metrics

6
12
7
1
40
30
10
0.83
1.71
7
1.43

Classes

Class Line # Actions
Address 5 12 10
0.00%
 

Contributing tests

No tests hitting this source file were found.

Source view

1    package io.sunshower.persistence.core;
2   
3    import java.util.Objects;
4   
 
5    public abstract class Address {
6   
7    protected String value;
8   
 
9  0 toggle protected Address() {}
10   
 
11  0 toggle protected Address(char[] value) {
12  0 Objects.requireNonNull(value);
13  0 this.value = new String(value);
14    }
15   
 
16  0 toggle protected Address(String value) {
17  0 this.value = value;
18    }
19   
 
20  0 toggle public String toString() {
21  0 return value;
22    }
23   
 
24  0 toggle @Override
25    public boolean equals(Object o) {
26  0 if (this == o) return true;
27  0 if (!(o instanceof Address)) return false;
28  0 Address that = (Address) o;
29  0 return Objects.equals(value, that.value);
30    }
31   
 
32  0 toggle @Override
33    public int hashCode() {
34  0 return value == null ? 0 : value.hashCode();
35    }
36   
 
37  0 toggle public String getValue() {
38  0 return value;
39    }
40    }