Files
2026-07-24 18:22:51 +00:00

510 lines
47 KiB
HTML

<!DOCTYPE HTML>
<html lang="en">
<head>
<!-- Google Analytics tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-DKHZS27PHP"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag("js", new Date());
gtag("config", "G-DKHZS27PHP");
</script>
<!-- Generated by javadoc (26) -->
<title>BaseTool (Google Agent Development Kit Maven Parent POM 1.7.0 API)</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="description" content="declaration: package: com.google.adk.tools, class: BaseTool">
<meta name="generator" content="javadoc/ClassWriter">
<link rel="stylesheet" type="text/css" href="../../../../resource-files/jquery-ui.min.css">
<link rel="stylesheet" type="text/css" href="../../../../resource-files/stylesheet.css">
<script type="text/javascript" src="../../../../script-files/script.js"></script>
<script type="text/javascript" src="../../../../script-files/jquery-3.7.1.min.js"></script>
<script type="text/javascript" src="../../../../script-files/jquery-ui.min.js"></script>
</head>
<body class="class-declaration-page">
<script type="text/javascript">const pathtoroot = "../../../../";
loadScripts();
initTheme();
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<header role="banner">
<nav role="navigation">
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="top-nav" id="navbar-top">
<div class="nav-content">
<div class="nav-menu-button"><button id="navbar-toggle-button" aria-controls="navbar-top" aria-expanded="false" aria-label="Toggle navigation links"><span class="nav-bar-toggle-icon">&nbsp;</span><span class="nav-bar-toggle-icon">&nbsp;</span><span class="nav-bar-toggle-icon">&nbsp;</span></button></div>
<div class="skip-nav"><a href="#skip-navbar-top" title="Skip navigation links">Skip navigation links</a></div>
<ul id="navbar-top-firstrow" class="nav-list" title="Navigation">
<li><a href="../../../../index.html">Overview</a></li>
<li class="nav-bar-cell1-rev">Class</li>
<li><a href="class-use/BaseTool.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../search.html">Search</a></li>
<li><button id="theme-button" aria-label="Select Theme" title="Select Theme"></button></li>
</ul>
<div id="theme-panel">
<div>Select Theme</div>
<div><label for="theme-light"><input type="radio" id="theme-light" disabled name="theme" value="theme-light"><span>Light</span></label><label for="theme-dark"><input type="radio" id="theme-dark" disabled name="theme" value="theme-dark"><span>Dark</span></label><label for="theme-os"><input type="radio" id="theme-os" disabled name="theme" value="theme-os"><span>System Setting</span></label></div>
</div>
</div>
</div>
<div class="sub-nav">
<div class="nav-content">
<ol class="sub-nav-list">
<li><a href="package-summary.html">com.google.adk.tools</a></li>
<li><a href="BaseTool.html" class="current-selection">BaseTool</a></li>
</ol>
<div class="nav-list-search"><input type="text" id="search-input" disabled placeholder="Search documentation (type /)" aria-label="Search in documentation" autocomplete="off" spellcheck="false"><input type="reset" id="reset-search" disabled value="Reset"></div>
</div>
</div>
<!-- ========= END OF TOP NAVBAR ========= -->
<span class="skip-nav" id="skip-navbar-top"></span></nav>
</header>
<div class="main-grid">
<nav role="navigation" class="toc" aria-label="Table of contents">
<div class="toc-header">Contents&nbsp;<input type="text" class="filter-input" disabled placeholder="Filter contents (type .)" aria-label="Filter table of contents" autocomplete="off" spellcheck="false"><input type="reset" class="reset-filter" disabled tabindex="-1" value="Reset">&nbsp;<button class="toc-sort-toggle" id="toc-lexical-order-toggle"><img src="../../../../resource-files/sort-a-z.svg" alt="Sort member details in lexicographical order"></button></div>
<ol class="toc-list" tabindex="-1">
<li><a href="#" tabindex="0">Description</a></li>
<li><a href="#nested-class-summary" tabindex="0">Nested Class Summary</a></li>
<li><a href="#constructor-summary" tabindex="0">Constructor Summary</a></li>
<li><a href="#method-summary" tabindex="0">Method Summary</a></li>
<li><a href="#constructor-detail" tabindex="0">Constructor Details</a>
<ol class="toc-list">
<li><a href="#%3Cinit%3E(java.lang.String,java.lang.String)" tabindex="0">BaseTool(String, String)</a></li>
<li><a href="#%3Cinit%3E(java.lang.String,java.lang.String,boolean)" tabindex="0">BaseTool(String, String, boolean)</a></li>
</ol>
</li>
<li><a href="#method-detail" tabindex="0">Method Details</a>
<ol class="toc-list">
<li><a href="#name()" tabindex="0">name()</a></li>
<li><a href="#description()" tabindex="0">description()</a></li>
<li><a href="#longRunning()" tabindex="0">longRunning()</a></li>
<li><a href="#declaration()" tabindex="0">declaration()</a></li>
<li><a href="#customMetadata()" tabindex="0">customMetadata()</a></li>
<li><a href="#setCustomMetadata(java.lang.String,java.lang.Object)" tabindex="0">setCustomMetadata(String, Object)</a></li>
<li><a href="#runAsync(java.util.Map,com.google.adk.tools.ToolContext)" tabindex="0">runAsync(Map, ToolContext)</a></li>
<li><a href="#runAsync(T,com.google.adk.tools.ToolContext)" tabindex="0">runAsync(T, ToolContext)</a></li>
<li><a href="#runAsync(T,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper)" tabindex="0">runAsync(T, ToolContext, ObjectMapper)</a></li>
<li><a href="#runAsync(I,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper,java.lang.Class)" tabindex="0">runAsync(I, ToolContext, ObjectMapper, Class)</a></li>
<li><a href="#runAsync(I,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper,com.fasterxml.jackson.core.type.TypeReference)" tabindex="0">runAsync(I, ToolContext, ObjectMapper, TypeReference)</a></li>
<li><a href="#runAsync(I,com.google.adk.tools.ToolContext,java.lang.Class)" tabindex="0">runAsync(I, ToolContext, Class)</a></li>
<li><a href="#runAsync(I,com.google.adk.tools.ToolContext,com.fasterxml.jackson.core.type.TypeReference)" tabindex="0">runAsync(I, ToolContext, TypeReference)</a></li>
<li><a href="#processLlmRequest(com.google.adk.models.LlmRequest.Builder,com.google.adk.tools.ToolContext)" tabindex="0">processLlmRequest(LlmRequest.Builder, ToolContext)</a></li>
<li><a href="#fromConfig(com.google.adk.tools.BaseTool.ToolConfig,java.lang.String)" tabindex="0">fromConfig(BaseTool.ToolConfig, String)</a></li>
</ol>
</li>
</ol>
<button class="hide-sidebar"><span>Hide sidebar&nbsp;</span><img src="../../../../resource-files/left.svg" alt="Hide sidebar"></button><button class="show-sidebar"><img src="../../../../resource-files/right.svg" alt="Show sidebar"><span>&nbsp;Show sidebar</span></button></nav>
<main role="main">
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<h1 title="Class BaseTool" class="title">Class BaseTool</h1>
</div>
<div class="inheritance" title="Inheritance Tree"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">java.lang.Object</a>
<div class="inheritance">com.google.adk.tools.BaseTool</div>
</div>
<section class="class-description" id="class-description">
<dl class="notes">
<dt>Direct Known Subclasses:</dt>
<dd><code><a href="mcp/AbstractMcpTool.html" title="class in com.google.adk.tools.mcp">AbstractMcpTool</a>, <a href="AgentTool.html" title="class in com.google.adk.tools">AgentTool</a>, <a href="retrieval/BaseRetrievalTool.html" title="class in com.google.adk.tools.retrieval">BaseRetrievalTool</a>, <a href="BuiltInCodeExecutionTool.html" title="class in com.google.adk.tools">BuiltInCodeExecutionTool</a>, <a href="ExampleTool.html" title="class in com.google.adk.tools">ExampleTool</a>, <a href="FunctionTool.html" title="class in com.google.adk.tools">FunctionTool</a>, <a href="GoogleMapsTool.html" title="class in com.google.adk.tools">GoogleMapsTool</a>, <a href="GoogleSearchTool.html" title="class in com.google.adk.tools">GoogleSearchTool</a>, <a href="applicationintegrationtoolset/IntegrationConnectorTool.html" title="class in com.google.adk.tools.applicationintegrationtoolset">IntegrationConnectorTool</a>, <a href="LoadArtifactsTool.html" title="class in com.google.adk.tools">LoadArtifactsTool</a>, <a href="SetModelResponseTool.html" title="class in com.google.adk.tools">SetModelResponseTool</a>, <a href="UrlContextTool.html" title="class in com.google.adk.tools">UrlContextTool</a>, <a href="VertexAiSearchTool.html" title="class in com.google.adk.tools">VertexAiSearchTool</a></code></dd>
</dl>
<hr>
<div class="horizontal-scroll">
<div class="type-signature"><span class="modifiers">public abstract class </span><span class="element-name type-name-label">BaseTool</span>
<span class="extends-implements">extends <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a></span></div>
<div class="block">The base class for all ADK tools.</div>
</div>
</section>
<section class="summary">
<ul class="summary-list">
<!-- ======== NESTED CLASS SUMMARY ======== -->
<li>
<section class="nested-class-summary" id="nested-class-summary">
<h2>Nested Class Summary</h2>
<div class="caption"><span>Nested Classes</span></div>
<div class="summary-table three-column-summary">
<div class="table-header col-first">Modifier and Type</div>
<div class="table-header col-second">Class</div>
<div class="table-header col-last">Description</div>
<div class="col-first even-row-color"><code>static class&nbsp;</code></div>
<div class="col-second even-row-color"><code><a href="BaseTool.ToolArgsConfig.html" class="type-name-link" title="class in com.google.adk.tools">BaseTool.ToolArgsConfig</a></code></div>
<div class="col-last even-row-color">
<div class="block">Configuration class for tool arguments that allows arbitrary key-value pairs.</div>
</div>
<div class="col-first odd-row-color"><code>static class&nbsp;</code></div>
<div class="col-second odd-row-color"><code><a href="BaseTool.ToolConfig.html" class="type-name-link" title="class in com.google.adk.tools">BaseTool.ToolConfig</a></code></div>
<div class="col-last odd-row-color">
<div class="block">Configuration class for a tool definition in YAML/JSON.</div>
</div>
</div>
</section>
</li>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<li>
<section class="constructor-summary" id="constructor-summary">
<h2>Constructor Summary</h2>
<div class="caption"><span>Constructors</span></div>
<div class="summary-table three-column-summary">
<div class="table-header col-first">Modifier</div>
<div class="table-header col-second">Constructor</div>
<div class="table-header col-last">Description</div>
<div class="col-first even-row-color"><code>protected </code></div>
<div class="col-constructor-name even-row-color"><code><a href="#%3Cinit%3E(java.lang.String,java.lang.String)" class="member-name-link">BaseTool</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;name,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;description)</code></div>
<div class="col-last even-row-color">&nbsp;</div>
<div class="col-first odd-row-color"><code>protected </code></div>
<div class="col-constructor-name odd-row-color"><code><a href="#%3Cinit%3E(java.lang.String,java.lang.String,boolean)" class="member-name-link">BaseTool</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;name,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;description,
boolean&nbsp;isLongRunning)</code></div>
<div class="col-last odd-row-color">&nbsp;</div>
</div>
</section>
</li>
<!-- ========== METHOD SUMMARY =========== -->
<li>
<section class="method-summary" id="method-summary">
<h2>Method Summary</h2>
<div id="method-summary-table">
<div class="table-tabs" role="tablist" aria-orientation="horizontal"><button id="method-summary-table-tab0" role="tab" aria-selected="true" aria-controls="method-summary-table.tabpanel" tabindex="0" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table', 3)" class="active-table-tab">All Methods</button><button id="method-summary-table-tab1" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab1', 3)" class="table-tab">Static Methods</button><button id="method-summary-table-tab2" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab2', 3)" class="table-tab">Instance Methods</button><button id="method-summary-table-tab4" role="tab" aria-selected="false" aria-controls="method-summary-table.tabpanel" tabindex="-1" onkeydown="switchTab(event)" onclick="show('method-summary-table', 'method-summary-table-tab4', 3)" class="table-tab">Concrete Methods</button></div>
<div id="method-summary-table.tabpanel" role="tabpanel" aria-labelledby="method-summary-table-tab0">
<div class="summary-table three-column-summary">
<div class="table-header col-first">Modifier and Type</div>
<div class="table-header col-second">Method</div>
<div class="table-header col-last">Description</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>com.google.common.collect.ImmutableMap<wbr>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#customMetadata()" class="member-name-link">customMetadata</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Returns a read-only view of the tool metadata.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Optional.html" title="class in java.util" class="external-link">Optional</a><wbr>&lt;com.google.genai.types.FunctionDeclaration&gt;</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#declaration()" class="member-name-link">declaration</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Gets the <code>FunctionDeclaration</code> representation of this tool.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a></code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#description()" class="member-name-link">description</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">&nbsp;</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code>static <a href="BaseTool.html" title="class in com.google.adk.tools">BaseTool</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4"><code><a href="#fromConfig(com.google.adk.tools.BaseTool.ToolConfig,java.lang.String)" class="member-name-link">fromConfig</a><wbr>(<a href="BaseTool.ToolConfig.html" title="class in com.google.adk.tools">BaseTool.ToolConfig</a>&nbsp;config,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;configAbsPath)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab1 method-summary-table-tab4">
<div class="block">Creates a tool instance from a config.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>boolean</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#longRunning()" class="member-name-link">longRunning</a>()</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">&nbsp;</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a></code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#name()" class="member-name-link">name</a>()</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">&nbsp;</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>io.reactivex.rxjava3.core.Completable</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#processLlmRequest(com.google.adk.models.LlmRequest.Builder,com.google.adk.tools.ToolContext)" class="member-name-link">processLlmRequest</a><wbr>(<a href="../models/LlmRequest.Builder.html" title="class in com.google.adk.models">LlmRequest.Builder</a>&nbsp;llmRequestBuilder,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Processes the outgoing <a href="../models/LlmRequest.Builder.html" title="class in com.google.adk.models"><code>LlmRequest.Builder</code></a>.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>final &lt;I,<wbr>O&gt;&nbsp;io.reactivex.rxjava3.core.Single<wbr>&lt;O&gt;</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#runAsync(I,com.google.adk.tools.ToolContext,com.fasterxml.jackson.core.type.TypeReference)" class="member-name-link">runAsync</a><wbr>(I&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
com.fasterxml.jackson.core.type.TypeReference&lt;? extends O&gt;&nbsp;typeReference)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Calls a tool with generic arguments, returning the results converted to a specified type
reference.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>final &lt;I,<wbr>O&gt;&nbsp;io.reactivex.rxjava3.core.Single<wbr>&lt;O&gt;</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#runAsync(I,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper,com.fasterxml.jackson.core.type.TypeReference)" class="member-name-link">runAsync</a><wbr>(I&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
com.fasterxml.jackson.databind.ObjectMapper&nbsp;objectMapper,
com.fasterxml.jackson.core.type.TypeReference&lt;? extends O&gt;&nbsp;typeReference)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Calls a tool with generic arguments and a custom <code>ObjectMapper</code>, returning the results
converted to a specified type reference.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>final &lt;I,<wbr>O&gt;&nbsp;io.reactivex.rxjava3.core.Single<wbr>&lt;O&gt;</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#runAsync(I,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper,java.lang.Class)" class="member-name-link">runAsync</a><wbr>(I&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
com.fasterxml.jackson.databind.ObjectMapper&nbsp;objectMapper,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Class.html" title="class in java.lang" class="external-link">Class</a>&lt;? extends O&gt;&nbsp;oClass)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Calls a tool with generic arguments and a custom <code>ObjectMapper</code>, returning the results
converted to a specified class.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>final &lt;I,<wbr>O&gt;&nbsp;io.reactivex.rxjava3.core.Single<wbr>&lt;O&gt;</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#runAsync(I,com.google.adk.tools.ToolContext,java.lang.Class)" class="member-name-link">runAsync</a><wbr>(I&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Class.html" title="class in java.lang" class="external-link">Class</a>&lt;? extends O&gt;&nbsp;oClass)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Calls a tool with generic arguments, returning the results converted to a specified class.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>io.reactivex.rxjava3.core.Single<wbr>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Map.html" title="interface in java.util" class="external-link">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;&gt;</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#runAsync(java.util.Map,com.google.adk.tools.ToolContext)" class="member-name-link">runAsync</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Map.html" title="interface in java.util" class="external-link">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Calls a tool.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>final &lt;T&gt;&nbsp;io.reactivex.rxjava3.core.Single<wbr>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Map.html" title="interface in java.util" class="external-link">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;&gt;</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#runAsync(T,com.google.adk.tools.ToolContext)" class="member-name-link">runAsync</a><wbr>(T&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Calls a tool with generic arguments and returns a map of results.</div>
</div>
<div class="col-first odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>final &lt;T&gt;&nbsp;io.reactivex.rxjava3.core.Single<wbr>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Map.html" title="interface in java.util" class="external-link">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;&gt;</code></div>
<div class="col-second odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#runAsync(T,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper)" class="member-name-link">runAsync</a><wbr>(T&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
com.fasterxml.jackson.databind.ObjectMapper&nbsp;objectMapper)</code></div>
<div class="col-last odd-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Calls a tool with generic arguments using a custom <code>ObjectMapper</code> and returns a map of
results.</div>
</div>
<div class="col-first even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code>void</code></div>
<div class="col-second even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4"><code><a href="#setCustomMetadata(java.lang.String,java.lang.Object)" class="member-name-link">setCustomMetadata</a><wbr>(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;key,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&nbsp;value)</code></div>
<div class="col-last even-row-color method-summary-table method-summary-table-tab2 method-summary-table-tab4">
<div class="block">Sets custom metadata to the tool associated with a key.</div>
</div>
</div>
</div>
</div>
<div class="inherited-list">
<h3 id="methods-inherited-from-class-java.lang.Object">Methods inherited from class&nbsp;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#method-summary" title="class in java.lang" class="external-link">Object</a></h3>
<code><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#clone()" title="clone()" class="external-link">clone</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#equals(java.lang.Object)" title="equals(Object)" class="external-link">equals</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#finalize()" title="finalize()" class="external-link">finalize</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#getClass()" title="getClass()" class="external-link">getClass</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#hashCode()" title="hashCode()" class="external-link">hashCode</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#notify()" title="notify()" class="external-link">notify</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#notifyAll()" title="notifyAll()" class="external-link">notifyAll</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#toString()" title="toString()" class="external-link">toString</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#wait()" title="wait()" class="external-link">wait</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#wait(long)" title="wait(long)" class="external-link">wait</a>, <a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html#wait(long,int)" title="wait(long, int)" class="external-link">wait</a></code></div>
</section>
</li>
</ul>
</section>
<section class="details">
<ul class="details-list">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<li>
<section class="constructor-details" id="constructor-detail">
<h2>Constructor Details</h2>
<ul class="member-list">
<li>
<section class="detail" id="&lt;init&gt;(java.lang.String,java.lang.String)">
<h3>BaseTool</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="element-name">BaseTool</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;name,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;description)</span></div>
</div>
</section>
</li>
<li>
<section class="detail" id="&lt;init&gt;(java.lang.String,java.lang.String,boolean)">
<h3>BaseTool</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">protected</span>&nbsp;<span class="element-name">BaseTool</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;name,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;description,
boolean&nbsp;isLongRunning)</span></div>
</div>
</section>
</li>
</ul>
</section>
</li>
<!-- ============ METHOD DETAIL ========== -->
<li>
<section class="method-details" id="method-detail">
<h2>Method Details</h2>
<ul class="member-list">
<li>
<section class="detail" id="name()">
<h3>name</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a></span>&nbsp;<span class="element-name">name</span>()</div>
</div>
</section>
</li>
<li>
<section class="detail" id="description()">
<h3>description</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a></span>&nbsp;<span class="element-name">description</span>()</div>
</div>
</section>
</li>
<li>
<section class="detail" id="longRunning()">
<h3>longRunning</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">boolean</span>&nbsp;<span class="element-name">longRunning</span>()</div>
</div>
</section>
</li>
<li>
<section class="detail" id="declaration()">
<h3>declaration</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type"><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Optional.html" title="class in java.util" class="external-link">Optional</a>&lt;com.google.genai.types.FunctionDeclaration&gt;</span>&nbsp;<span class="element-name">declaration</span>()</div>
<div class="block">Gets the <code>FunctionDeclaration</code> representation of this tool.</div>
</div>
</section>
</li>
<li>
<section class="detail" id="customMetadata()">
<h3>customMetadata</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">com.google.common.collect.ImmutableMap&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;</span>&nbsp;<span class="element-name">customMetadata</span>()</div>
<div class="block">Returns a read-only view of the tool metadata.</div>
</div>
</section>
</li>
<li>
<section class="detail" id="setCustomMetadata(java.lang.String,java.lang.Object)">
<h3>setCustomMetadata</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">void</span>&nbsp;<span class="element-name">setCustomMetadata</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;key,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&nbsp;value)</span></div>
<div class="block">Sets custom metadata to the tool associated with a key.</div>
</div>
</section>
</li>
<li>
<section class="detail" id="runAsync(java.util.Map,com.google.adk.tools.ToolContext)">
<h3>runAsync</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public</span>&nbsp;<span class="return-type">io.reactivex.rxjava3.core.Single&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Map.html" title="interface in java.util" class="external-link">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;&gt;</span>&nbsp;<span class="element-name">runAsync</span><wbr><span class="parameters">(<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Map.html" title="interface in java.util" class="external-link">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext)</span></div>
<div class="block">Calls a tool.</div>
</div>
</section>
</li>
<li>
<section class="detail" id="runAsync(T,com.google.adk.tools.ToolContext)">
<h3 id="runAsync(java.lang.Object,com.google.adk.tools.ToolContext)">runAsync</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public final</span>&nbsp;<span class="type-parameters">&lt;T&gt;</span>
<span class="return-type">io.reactivex.rxjava3.core.Single&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Map.html" title="interface in java.util" class="external-link">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;&gt;</span>&nbsp;<span class="element-name">runAsync</span><wbr><span class="parameters">(T&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext)</span></div>
<div class="block">Calls a tool with generic arguments and returns a map of results. The args type <code>T</code> need
to be serializable with <a href="../JsonBaseModel.html#getMapper()"><code>JsonBaseModel.getMapper()</code></a></div>
</div>
</section>
</li>
<li>
<section class="detail" id="runAsync(T,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper)">
<h3 id="runAsync(java.lang.Object,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper)">runAsync</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public final</span>&nbsp;<span class="type-parameters">&lt;T&gt;</span>
<span class="return-type">io.reactivex.rxjava3.core.Single&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/Map.html" title="interface in java.util" class="external-link">Map</a>&lt;<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>,<wbr><a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Object.html" title="class in java.lang" class="external-link">Object</a>&gt;&gt;</span>&nbsp;<span class="element-name">runAsync</span><wbr><span class="parameters">(T&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
com.fasterxml.jackson.databind.ObjectMapper&nbsp;objectMapper)</span></div>
<div class="block">Calls a tool with generic arguments using a custom <code>ObjectMapper</code> and returns a map of
results. The args type <code>T</code> needs to be serializable with the provided <code>ObjectMapper</code>.</div>
</div>
</section>
</li>
<li>
<section class="detail" id="runAsync(I,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper,java.lang.Class)">
<h3 id="runAsync(java.lang.Object,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper,java.lang.Class)">runAsync</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public final</span>&nbsp;<span class="type-parameters">&lt;I,<wbr>O&gt;</span>
<span class="return-type">io.reactivex.rxjava3.core.Single&lt;O&gt;</span>&nbsp;<span class="element-name">runAsync</span><wbr><span class="parameters">(I&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
com.fasterxml.jackson.databind.ObjectMapper&nbsp;objectMapper,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Class.html" title="class in java.lang" class="external-link">Class</a>&lt;? extends O&gt;&nbsp;oClass)</span></div>
<div class="block">Calls a tool with generic arguments and a custom <code>ObjectMapper</code>, returning the results
converted to a specified class. The input type <code>I</code> needs to be serializable and the
output type <code>O</code> needs to be deserializable with the provided <code>ObjectMapper</code>.</div>
</div>
</section>
</li>
<li>
<section class="detail" id="runAsync(I,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper,com.fasterxml.jackson.core.type.TypeReference)">
<h3 id="runAsync(java.lang.Object,com.google.adk.tools.ToolContext,com.fasterxml.jackson.databind.ObjectMapper,com.fasterxml.jackson.core.type.TypeReference)">runAsync</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public final</span>&nbsp;<span class="type-parameters">&lt;I,<wbr>O&gt;</span>
<span class="return-type">io.reactivex.rxjava3.core.Single&lt;O&gt;</span>&nbsp;<span class="element-name">runAsync</span><wbr><span class="parameters">(I&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
com.fasterxml.jackson.databind.ObjectMapper&nbsp;objectMapper,
com.fasterxml.jackson.core.type.TypeReference&lt;? extends O&gt;&nbsp;typeReference)</span></div>
<div class="block">Calls a tool with generic arguments and a custom <code>ObjectMapper</code>, returning the results
converted to a specified type reference. The input type <code>I</code> needs to be serializable and
the output type <code>O</code> needs to be deserializable with the provided <code>ObjectMapper</code>.</div>
</div>
</section>
</li>
<li>
<section class="detail" id="runAsync(I,com.google.adk.tools.ToolContext,java.lang.Class)">
<h3 id="runAsync(java.lang.Object,com.google.adk.tools.ToolContext,java.lang.Class)">runAsync</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public final</span>&nbsp;<span class="type-parameters">&lt;I,<wbr>O&gt;</span>
<span class="return-type">io.reactivex.rxjava3.core.Single&lt;O&gt;</span>&nbsp;<span class="element-name">runAsync</span><wbr><span class="parameters">(I&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Class.html" title="class in java.lang" class="external-link">Class</a>&lt;? extends O&gt;&nbsp;oClass)</span></div>
<div class="block">Calls a tool with generic arguments, returning the results converted to a specified class. The
input type <code>I</code> needs to be serializable and the output type <code>O</code> needs to be
deserializable with <a href="../JsonBaseModel.html#getMapper()"><code>JsonBaseModel.getMapper()</code></a></div>
</div>
</section>
</li>
<li>
<section class="detail" id="runAsync(I,com.google.adk.tools.ToolContext,com.fasterxml.jackson.core.type.TypeReference)">
<h3 id="runAsync(java.lang.Object,com.google.adk.tools.ToolContext,com.fasterxml.jackson.core.type.TypeReference)">runAsync</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public final</span>&nbsp;<span class="type-parameters">&lt;I,<wbr>O&gt;</span>
<span class="return-type">io.reactivex.rxjava3.core.Single&lt;O&gt;</span>&nbsp;<span class="element-name">runAsync</span><wbr><span class="parameters">(I&nbsp;args,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext,
com.fasterxml.jackson.core.type.TypeReference&lt;? extends O&gt;&nbsp;typeReference)</span></div>
<div class="block">Calls a tool with generic arguments, returning the results converted to a specified type
reference. The input type needs to be serializable and the output type needs to be
deserializable with <a href="../JsonBaseModel.html#getMapper()"><code>JsonBaseModel.getMapper()</code></a></div>
</div>
</section>
</li>
<li>
<section class="detail" id="processLlmRequest(com.google.adk.models.LlmRequest.Builder,com.google.adk.tools.ToolContext)">
<h3>processLlmRequest</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="annotations">@CanIgnoreReturnValue
</span><span class="modifiers">public</span>&nbsp;<span class="return-type">io.reactivex.rxjava3.core.Completable</span>&nbsp;<span class="element-name">processLlmRequest</span><wbr><span class="parameters">(<a href="../models/LlmRequest.Builder.html" title="class in com.google.adk.models">LlmRequest.Builder</a>&nbsp;llmRequestBuilder,
<a href="ToolContext.html" title="class in com.google.adk.tools">ToolContext</a>&nbsp;toolContext)</span></div>
<div class="block">Processes the outgoing <a href="../models/LlmRequest.Builder.html" title="class in com.google.adk.models"><code>LlmRequest.Builder</code></a>.
<p>This implementation adds the current tool's <a href="#declaration()"><code>declaration()</code></a> to the <code>GenerateContentConfig</code> within the builder. If a tool with function declarations already exists,
the current tool's declaration is merged into it. Otherwise, a new tool definition with the
current tool's declaration is created. The current tool itself is also added to the builder's
internal list of tools. Override this method for processing the outgoing request.</div>
</div>
</section>
</li>
<li>
<section class="detail" id="fromConfig(com.google.adk.tools.BaseTool.ToolConfig,java.lang.String)">
<h3>fromConfig</h3>
<div class="horizontal-scroll">
<div class="member-signature"><span class="modifiers">public static</span>&nbsp;<span class="return-type"><a href="BaseTool.html" title="class in com.google.adk.tools">BaseTool</a></span>&nbsp;<span class="element-name">fromConfig</span><wbr><span class="parameters">(<a href="BaseTool.ToolConfig.html" title="class in com.google.adk.tools">BaseTool.ToolConfig</a>&nbsp;config,
<a href="https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/String.html" title="class in java.lang" class="external-link">String</a>&nbsp;configAbsPath)</span>
throws <span class="exceptions"><a href="../agents/ConfigAgentUtils.ConfigurationException.html" title="class in com.google.adk.agents">ConfigAgentUtils.ConfigurationException</a></span></div>
<div class="block">Creates a tool instance from a config.
<p>Subclasses should override and implement this method to do custom initialization from a
config.</div>
<dl class="notes">
<dt>Parameters:</dt>
<dd><code>config</code> - The config for the tool.</dd>
<dd><code>configAbsPath</code> - The absolute path to the config file that contains the tool config.</dd>
<dt>Returns:</dt>
<dd>The tool instance.</dd>
<dt>Throws:</dt>
<dd><code><a href="../agents/ConfigAgentUtils.ConfigurationException.html" title="class in com.google.adk.agents">ConfigAgentUtils.ConfigurationException</a></code> - if the tool cannot be created from the config.</dd>
</dl>
</div>
</section>
</li>
</ul>
</section>
</li>
</ul>
</section>
<!-- ========= END OF CLASS DATA ========= -->
<footer>
<hr>
<p class="legal-copy"><small>Copyright &#169; 1980. All rights reserved.</small></p>
</footer>
</main>
</div>
</body>
</html>