bump version to 1.8.7 in pom.xml and add rewindTurn method to Conversation class
This commit is contained in:
2
pom.xml
2
pom.xml
@@ -4,7 +4,7 @@
|
|||||||
<artifactId>lm-lib</artifactId>
|
<artifactId>lm-lib</artifactId>
|
||||||
<groupId>de.extio</groupId>
|
<groupId>de.extio</groupId>
|
||||||
<name>lm-lib</name>
|
<name>lm-lib</name>
|
||||||
<version>1.8.6</version>
|
<version>1.8.7</version>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<java.version>21</java.version>
|
<java.version>21</java.version>
|
||||||
|
|||||||
@@ -54,6 +54,15 @@ public final class Conversation {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void rewindTurn() {
|
||||||
|
synchronized (this.conversation) {
|
||||||
|
if (this.conversation.size() > 1) {
|
||||||
|
this.conversation.removeLast();
|
||||||
|
this.conversation.removeLast();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public List<Turn> getConversation() {
|
public List<Turn> getConversation() {
|
||||||
return Collections.unmodifiableList(this.conversation);
|
return Collections.unmodifiableList(this.conversation);
|
||||||
|
|||||||
Reference in New Issue
Block a user