Class Session.Builder
java.lang.Object
com.google.adk.sessions.Session.Builder
- Enclosing class:
Session
-
Constructor Summary
ConstructorsConstructorDescriptionBuilder(SessionKey sessionKey) Creates a newSession.Builderwith the given session key. -
Method Summary
Modifier and TypeMethodDescriptionbuild()eventsView(List<Event> events) Deprecated.lastUpdateTime(Instant lastUpdateTime) lastUpdateTimeSeconds(double seconds) sessionKey(SessionKey sessionKey) Sets the session key.
-
Constructor Details
-
Builder
-
Builder
Creates a newSession.Builderwith the given session key.
-
-
Method Details
-
id
-
sessionKey
Sets the session key. -
state
-
state
-
appName
-
userId
-
events
-
eventsView
Deprecated.Not a real deprecation - a warn-off for application code from a seam meant for ADK's own framework and interop adapters; useevents(List)instead.BacksSession.events()with the given list directly, without copying, so the session reflects a caller-owned live or converting view whose events grow as the owner appends. The caller keeps ownership and the list's own semantics - thread-safety, and a read-only view throwing onadd- so ordinary code should useevents(List), which defensively copies. -
lastUpdateTime
-
lastUpdateTimeSeconds
-
build
-
events(List)instead.