Class PointerDoc
java.lang.Object
com.google.genkit.ai.agent.internal.PointerDoc
Tiny POJO representing the contents of a per-session pointer file.
The pointer file lives at <dir>/<prefix>/.pointers/<sessionId>.json and contains a
reference to the current latest-leaf snapshot for that session, allowing fast lookup without
scanning all snapshot files.
-
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor (required for Jackson deserialization).PointerDoc(String currentSnapshotId, String currentCreatedAt, String updatedAt) Creates a newPointerDoc. -
Method Summary
Modifier and TypeMethodDescriptionReturns the current snapshot's createdAt timestamp.Returns the current snapshot ID.Returns the timestamp when this pointer was last updated.voidsetCurrentCreatedAt(String currentCreatedAt) Sets the current snapshot's createdAt timestamp.voidsetCurrentSnapshotId(String currentSnapshotId) Sets the current snapshot ID.voidsetUpdatedAt(String updatedAt) Sets the timestamp when this pointer was last updated.
-
Constructor Details
-
PointerDoc
public PointerDoc()Default constructor (required for Jackson deserialization). -
PointerDoc
Creates a newPointerDoc.- Parameters:
currentSnapshotId- the snapshot IDcurrentCreatedAt- the snapshot's createdAt timestampupdatedAt- when this pointer was written
-
-
Method Details
-
getCurrentSnapshotId
Returns the current snapshot ID.- Returns:
- the snapshot ID
-
setCurrentSnapshotId
Sets the current snapshot ID.- Parameters:
currentSnapshotId- the snapshot ID
-
getCurrentCreatedAt
Returns the current snapshot's createdAt timestamp.- Returns:
- the createdAt timestamp (RFC-3339)
-
setCurrentCreatedAt
Sets the current snapshot's createdAt timestamp.- Parameters:
currentCreatedAt- the createdAt timestamp (RFC-3339)
-
getUpdatedAt
Returns the timestamp when this pointer was last updated.- Returns:
- the updatedAt timestamp (RFC-3339)
-
setUpdatedAt
Sets the timestamp when this pointer was last updated.- Parameters:
updatedAt- the updatedAt timestamp (RFC-3339)
-