Skip to content

Commit 4ed9e54

Browse files
Ajit GeorgeAjit George
authored andcommitted
Additional Test cases for Git issue 222
1 parent 7b98a64 commit 4ed9e54

File tree

2 files changed

+132
-0
lines changed

2 files changed

+132
-0
lines changed
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
package com.marklogic.client.functionaltest;
2+
3+
import java.util.Calendar;
4+
5+
import com.marklogic.client.pojo.annotation.Id;
6+
import com.marklogic.client.pojo.annotation.PathIndexProperty;
7+
import com.marklogic.client.pojo.annotation.PathIndexProperty.ScalarType;
8+
9+
/*
10+
* This class is similar to the Artifact class. It is used to test path range index using the Float type.
11+
* Property name been annotated with @Id.
12+
*/
13+
public class ArtifactIndexedOnFloat {
14+
@Id
15+
public String name;
16+
public long id;
17+
private Company manufacturer;
18+
private int inventory;
19+
@PathIndexProperty(scalarType = ScalarType.FLOAT)
20+
private Float price;
21+
22+
public Float getPrice() {
23+
return price;
24+
}
25+
26+
public void setPrice(Float price) {
27+
this.price = price;
28+
}
29+
30+
private Calendar expiryDate;
31+
32+
public long getId() {
33+
return id;
34+
}
35+
36+
public ArtifactIndexedOnFloat setId(long id) {
37+
this.id = id;
38+
return this;
39+
}
40+
41+
public String getName() {
42+
return name;
43+
}
44+
45+
public ArtifactIndexedOnFloat setName(String name) {
46+
this.name = name;
47+
return this;
48+
}
49+
50+
public Company getManufacturer() {
51+
return manufacturer;
52+
}
53+
54+
public ArtifactIndexedOnFloat setManufacturer(Company manufacturer) {
55+
this.manufacturer = manufacturer;
56+
return this;
57+
}
58+
59+
public int getInventory() {
60+
return inventory;
61+
}
62+
63+
public ArtifactIndexedOnFloat setInventory(int inventory) {
64+
this.inventory = inventory;
65+
return this;
66+
}
67+
68+
public Calendar getExpiryDate() {
69+
return expiryDate;
70+
}
71+
72+
public ArtifactIndexedOnFloat setExpiryDate(Calendar expiryDate) {
73+
this.expiryDate = expiryDate;
74+
return this;
75+
}
76+
}
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
package com.marklogic.client.functionaltest;
2+
3+
import com.marklogic.client.pojo.annotation.Id;
4+
import com.marklogic.client.pojo.annotation.PathIndexProperty;
5+
import com.marklogic.client.pojo.annotation.PathIndexProperty.ScalarType;
6+
7+
/*
8+
* This class is similar to the Artifact class. It is used to test path range index
9+
* using the inventory field with Integer type.
10+
* Property name been annotated with @Id.
11+
*/
12+
public class ArtifactIndexedOnInteger {
13+
@Id
14+
public String name;
15+
public long id;
16+
private Company manufacturer;
17+
18+
@PathIndexProperty(scalarType = ScalarType.INT)
19+
private Integer inventory;
20+
21+
public long getId() {
22+
return id;
23+
}
24+
25+
public ArtifactIndexedOnInteger setId(long id) {
26+
this.id = id;
27+
return this;
28+
}
29+
30+
public String getName() {
31+
return name;
32+
}
33+
34+
public ArtifactIndexedOnInteger setName(String name) {
35+
this.name = name;
36+
return this;
37+
}
38+
39+
public Company getManufacturer() {
40+
return manufacturer;
41+
}
42+
43+
public ArtifactIndexedOnInteger setManufacturer(Company manufacturer) {
44+
this.manufacturer = manufacturer;
45+
return this;
46+
}
47+
48+
public Integer getInventory() {
49+
return inventory;
50+
}
51+
52+
public ArtifactIndexedOnInteger setInventory(Integer inventory) {
53+
this.inventory = inventory;
54+
return this;
55+
}
56+
}

0 commit comments

Comments
 (0)