File tree Expand file tree Collapse file tree 3 files changed +40
-43
lines changed
src/main/java/com/arangodb/entity Expand file tree Collapse file tree 3 files changed +40
-43
lines changed Original file line number Diff line number Diff line change @@ -74,7 +74,7 @@ public abstract class BaseEntity implements Serializable {
7474 * @return boolean
7575 */
7676 public boolean isNotModified () {
77- return statusCode == 304 ; // HttpStatus.SC_NOT_MODIFIED;
77+ return statusCode == 304 ;
7878 }
7979
8080 /**
@@ -86,15 +86,6 @@ public boolean isUnauthorized() {
8686 return statusCode == 401 ;
8787 }
8888
89- // /**
90- // * If the requested resource has not been modified it returns true
91- // *
92- // * @return boolean
93- // */
94- // public boolean isNotFound() {
95- // return statusCode == 404;
96- // }
97-
9889 /**
9990 * If this is the response of a batch request it returns true
10091 *
Original file line number Diff line number Diff line change 2323 *
2424 */
2525public enum CollectionType {
26- /**
27- * Document collection type
28- */
29- DOCUMENT (2 ),
30-
31- /**
32- * Edge collection type, used for graphs
33- */
34- EDGE (3 );
35- private final int type ;
36- private CollectionType (int type ) {
37- this .type = type ;
38- }
39- public int getType () {
40- return type ;
41- }
42- public static CollectionType valueOf (int type ) {
43- switch (type ) {
44- case 2 :
45- return DOCUMENT ;
46- case 3 :
47- return EDGE ;
48- }
49- return null ;
50- }
26+ /**
27+ * Document collection type
28+ */
29+ DOCUMENT (2 ),
30+
31+ /**
32+ * Edge collection type, used for graphs
33+ */
34+ EDGE (3 );
35+
36+ private final int type ;
37+
38+ private CollectionType (int type ) {
39+ this .type = type ;
40+ }
41+
42+ public int getType () {
43+ return type ;
44+ }
45+
46+ public static CollectionType valueOf (int type ) {
47+ CollectionType result = null ;
48+
49+ if (type == 2 ) {
50+ result = DOCUMENT ;
51+ }
52+ else if (type == 3 ) {
53+ result = EDGE ;
54+ }
55+
56+ return result ;
57+ }
5158}
Original file line number Diff line number Diff line change @@ -30,9 +30,8 @@ public class JobsEntity extends BaseEntity {
3030 /**
3131 * The enumeration containing the job state
3232 */
33- public static enum JobState {
34- DONE ,
35- PENDING ;
33+ public enum JobState {
34+ DONE , PENDING ;
3635 public java .lang .String getName () {
3736 if (this == DONE ) {
3837 return "done" ;
@@ -44,7 +43,11 @@ public java.lang.String getName() {
4443 }
4544 }
4645
47- List <String > jobs ;
46+ private List <String > jobs ;
47+
48+ public JobsEntity (List <String > jobs ) {
49+ this .jobs = jobs ;
50+ }
4851
4952 public List <String > getJobs () {
5053 return jobs ;
@@ -53,8 +56,4 @@ public List<String> getJobs() {
5356 public void setJobs (List <String > jobs ) {
5457 this .jobs = jobs ;
5558 }
56-
57- public JobsEntity (List <String > jobs ) {
58- this .jobs = jobs ;
59- }
6059}
You can’t perform that action at this time.
0 commit comments