Add a simple Binding query language
[mdsal.git] / binding / mdsal-binding-api / src / main / java / org / opendaylight / mdsal / binding / api / query / ValueMatch.java
1 /*
2  * Copyright (c) 2020 PANTHEON.tech, s.r.o. and others.  All rights reserved.
3  *
4  * This program and the accompanying materials are made available under the
5  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6  * and is available at http://www.eclipse.org/legal/epl-v10.html
7  */
8 package org.opendaylight.mdsal.binding.api.query;
9
10 import com.google.common.annotations.Beta;
11 import org.eclipse.jdt.annotation.NonNull;
12 import org.opendaylight.yangtools.yang.binding.DataObject;
13
14 /**
15  * A value-based match executed from some point in the data tree.
16  *
17  * @param <T> query result type
18  */
19 @Beta
20 public interface ValueMatch<T extends DataObject> extends StructuralBuilder<QueryExpression<T>> {
21     /**
22      * Start chaining an additional match for the query. Query results are guaranteed both this match and that
23      * additional match at the same time.
24      *
25      * @return A {@link MatchBuilderPath}
26      */
27     @NonNull MatchBuilderPath<T, T> and();
28 }