1 package com.atlassian.selenium.visualcomparison.v2.settings;
2
3 import com.atlassian.annotations.ExperimentalApi;
4
5 import javax.annotation.concurrent.Immutable;
6
7 import static com.google.common.base.Preconditions.checkArgument;
8
9
10
11
12
13
14 @Immutable
15 @ExperimentalApi
16 public final class SimplePagePart implements PagePart
17 {
18 private final int left;
19 private final int top;
20 private final int right;
21 private final int bottom;
22
23 public SimplePagePart(int left, int top, int right, int bottom)
24 {
25 checkArgument(left >= 0, "left must be >= 0");
26 checkArgument(top >= 0, "top must be >= 0");
27 checkArgument(right >= 0, "right must be >= 0");
28 checkArgument(bottom >= 0, "bottom must be >= 0");
29 this.left = left;
30 this.top = top;
31 this.right = right;
32 this.bottom = bottom;
33 }
34
35 public int getLeft()
36 {
37 return left;
38 }
39
40 public int getTop()
41 {
42 return top;
43 }
44
45 public int getRight()
46 {
47 return right;
48 }
49
50 public int getBottom()
51 {
52 return bottom;
53 }
54 }