<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
<channel>
<title>Clojure Q&amp;A - Recent questions tagged realized?</title>
<link>https://ask.clojure.org/index.php/tag/realized%3F</link>
<description></description>
<item>
<title>Could realized? support Java futures?</title>
<link>https://ask.clojure.org/index.php/11913/could-realized-support-java-futures</link>
<description>&lt;p&gt;I'm running into a situation where I would need to mix CompletableFutures in with Clojure futures/delays/etc. Unfortunately, IPending is an interface, which can't be extended to Java core classes.&lt;/p&gt;
&lt;p&gt;For IDeref and IBlockingDeref, it's not a problem working with Java Futures, because the &lt;code&gt;deref&lt;/code&gt; fn supports them.&lt;/p&gt;
&lt;p&gt;Couldn't the same be done with the &lt;code&gt;realized?&lt;/code&gt; fn? Currently, it only works with IPending. It would be ideal if it matched the &lt;code&gt;deref&lt;/code&gt; behavior and called &lt;code&gt;.isDone()&lt;/code&gt; when given a java.util.concurrent.Future.&lt;/p&gt;
</description>
<category>Java Interop</category>
<guid isPermaLink="true">https://ask.clojure.org/index.php/11913/could-realized-support-java-futures</guid>
<pubDate>Sat, 28 May 2022 07:16:15 +0000</pubDate>
</item>
</channel>
</rss>