package org.opendaylight.yangtools.yang.data.api.schema.xpath;
import com.google.common.annotations.Beta;
-import com.google.common.base.Optional;
-import com.google.common.util.concurrent.CheckedFuture;
+import com.google.common.util.concurrent.ListenableFuture;
+import java.util.Optional;
import java.util.concurrent.Future;
import javax.annotation.Nonnull;
import javax.xml.xpath.XPathExpressionException;
* APPLICATIONS WILLING TO USE THIS API PLEASE CONTACT
* <a href="mailto:yangtools-dev@lists.opendaylight.org">yangtools-dev</a>.
*/
-@Beta
@Deprecated
+@Beta
public interface LazyXPathExpression {
/**
* Evaluate this expression at the specified path in a document. If evaluation succeeds, it will return an
* {@link XPathResult} at some point it the future. If it fails to match anything, it {@link Future#get()} will
- * return {@link Optional#absent()}.
+ * return {@link Optional#empty()}.
*
* <p>
* FIXME: The amount of overhead an implementation can incur on the user as data from the resulting
* @throws NullPointerException if any of the arguments are null
* @throws IllegalArgumentException if the path does not match the path at which this expression was compiled
*/
- CheckedFuture<Optional<? extends XPathResult<?>>, XPathExpressionException> evaluateLazily(
- @Nonnull XPathDocument document, @Nonnull YangInstanceIdentifier path);
+ ListenableFuture<Optional<? extends XPathResult<?>>> evaluateLazily(@Nonnull XPathDocument document,
+ @Nonnull YangInstanceIdentifier path);
}