Skip to content

Commit bcfc0f9

Browse files
committed
Merge branch 'master' into BAEL-8421
2 parents 3c24156 + 510dc41 commit bcfc0f9

File tree

759 files changed

+8074
-2098
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

759 files changed

+8074
-2098
lines changed

algorithms-modules/algorithms-miscellaneous-1/README.md

Lines changed: 6 additions & 5 deletions

algorithms-modules/algorithms-miscellaneous-1/pom.xml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,16 @@
3535
<artifactId>combinatoricslib3</artifactId>
3636
<version>${combinatoricslib3.version}</version>
3737
</dependency>
38+
<dependency>
39+
<groupId>jakarta.xml.bind</groupId>
40+
<artifactId>jakarta.xml.bind-api</artifactId>
41+
<version>${xml-bind-api.version}</version>
42+
</dependency>
43+
<dependency>
44+
<groupId>com.google.guava</groupId>
45+
<artifactId>guava</artifactId>
46+
<version>${guava.version}</version>
47+
</dependency>
3848
</dependencies>
3949

4050
<reporting>
@@ -59,6 +69,7 @@
5969

6070
<properties>
6171
<combinatoricslib3.version>3.3.0</combinatoricslib3.version>
72+
<xml-bind-api.version>4.0.0</xml-bind-api.version>
6273
</properties>
6374

6475
</project>
Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,14 @@
11
package com.baeldung.algorithms.conversion;
22

3-
import com.google.common.io.BaseEncoding;
4-
import jakarta.xml.bind.DatatypeConverter;
3+
import java.math.BigInteger;
4+
import java.util.HexFormat;
5+
56
import org.apache.commons.codec.DecoderException;
67
import org.apache.commons.codec.binary.Hex;
78

8-
import java.math.BigInteger;
9-
import java.util.HexFormat;
9+
import com.google.common.io.BaseEncoding;
10+
11+
import jakarta.xml.bind.DatatypeConverter;
1012

1113
public class HexStringConverter {
1214

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package com.baeldung.algorithms.ga.dijkstra;
1+
package com.baeldung.algorithms.dijkstra;
22

33
import java.util.HashSet;
44
import java.util.LinkedList;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package com.baeldung.algorithms.ga.dijkstra;
1+
package com.baeldung.algorithms.dijkstra;
22

33
import java.util.HashSet;
44
import java.util.Set;
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package com.baeldung.algorithms.ga.dijkstra;
1+
package com.baeldung.algorithms.dijkstra;
22

33
import java.util.HashMap;
44
import java.util.LinkedList;
Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
package com.baeldung.algorithms.enumstatemachine;
2+
3+
public enum LeaveRequestState {
4+
5+
Submitted {
6+
@Override
7+
public LeaveRequestState nextState() {
8+
System.out.println("Starting the Leave Request and sending to Team Leader for approval.");
9+
return Escalated;
10+
}
11+
12+
@Override
13+
public String responsiblePerson() {
14+
return "Employee";
15+
}
16+
},
17+
Escalated {
18+
@Override
19+
public LeaveRequestState nextState() {
20+
System.out.println("Reviewing the Leave Request and escalating to Department Manager.");
21+
return Approved;
22+
}
23+
24+
@Override
25+
public String responsiblePerson() {
26+
return "Team Leader";
27+
}
28+
},
29+
Approved {
30+
@Override
31+
public LeaveRequestState nextState() {
32+
System.out.println("Approving the Leave Request.");
33+
return this;
34+
}
35+
36+
@Override
37+
public String responsiblePerson() {
38+
return "Department Manager";
39+
}
40+
};
41+
42+
public abstract String responsiblePerson();
43+
44+
public abstract LeaveRequestState nextState();
45+
46+
}
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)