Skip to content

Commit 41f5af0

Browse files
google-genai-botcopybara-github
authored andcommitted
fix: Removing deprecated InvocationContext methods
PiperOrigin-RevId: 882608653
1 parent 9ce78d7 commit 41f5af0

1 file changed

Lines changed: 0 additions & 57 deletions

File tree

core/src/main/java/com/google/adk/agents/InvocationContext.java

Lines changed: 0 additions & 57 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
import com.google.adk.sessions.Session;
2828
import com.google.adk.summarizer.EventsCompactionConfig;
2929
import com.google.errorprone.annotations.CanIgnoreReturnValue;
30-
import com.google.errorprone.annotations.InlineMe;
3130
import com.google.genai.types.Content;
3231
import java.util.Map;
3332
import java.util.Objects;
@@ -81,62 +80,6 @@ protected InvocationContext(Builder builder) {
8180
this.callbackContextData = builder.callbackContextData;
8281
}
8382

84-
/**
85-
* @deprecated Use {@link #builder()} instead.
86-
*/
87-
@InlineMe(
88-
replacement =
89-
"InvocationContext.builder()"
90-
+ ".sessionService(sessionService)"
91-
+ ".artifactService(artifactService)"
92-
+ ".invocationId(invocationId)"
93-
+ ".agent(agent)"
94-
+ ".session(session)"
95-
+ ".userContent(userContent)"
96-
+ ".runConfig(runConfig)"
97-
+ ".build()",
98-
imports = {"com.google.adk.agents.InvocationContext"})
99-
@Deprecated(forRemoval = true)
100-
public static InvocationContext create(
101-
BaseSessionService sessionService,
102-
BaseArtifactService artifactService,
103-
String invocationId,
104-
BaseAgent agent,
105-
Session session,
106-
Content userContent,
107-
RunConfig runConfig) {
108-
return builder()
109-
.sessionService(sessionService)
110-
.artifactService(artifactService)
111-
.invocationId(invocationId)
112-
.agent(agent)
113-
.session(session)
114-
.userContent(userContent)
115-
.runConfig(runConfig)
116-
.build();
117-
}
118-
119-
/**
120-
* @deprecated Use {@link #builder()} instead.
121-
*/
122-
@Deprecated(forRemoval = true)
123-
public static InvocationContext create(
124-
BaseSessionService sessionService,
125-
BaseArtifactService artifactService,
126-
BaseAgent agent,
127-
Session session,
128-
LiveRequestQueue liveRequestQueue,
129-
RunConfig runConfig) {
130-
return builder()
131-
.sessionService(sessionService)
132-
.artifactService(artifactService)
133-
.agent(agent)
134-
.session(session)
135-
.liveRequestQueue(liveRequestQueue)
136-
.runConfig(runConfig)
137-
.build();
138-
}
139-
14083
/** Returns a new {@link Builder} for creating {@link InvocationContext} instances. */
14184
public static Builder builder() {
14285
return new Builder();

0 commit comments

Comments
 (0)