2 * Copyright (c) 2021 PANTHEON.tech, s.r.o. and others. All rights reserved.
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
8 package org.opendaylight.mdsal.binding.runtime.api;
10 import java.util.List;
11 import org.eclipse.jdt.annotation.NonNull;
12 import org.eclipse.jdt.annotation.Nullable;
13 import org.opendaylight.mdsal.binding.model.api.JavaTypeName;
14 import org.opendaylight.yangtools.yang.binding.Augmentable;
15 import org.opendaylight.yangtools.yang.model.api.stmt.ChoiceEffectiveStatement;
18 * A {@link RuntimeType} associated with a {@code choice} statement. Note that unlike YANG semantics, in Binding Spec
19 * semantics a type generated for a 'choice' statement is <b>does not</b> implement {@link Augmentable}.
21 public interface ChoiceRuntimeType extends CompositeRuntimeType, DataRuntimeType {
23 ChoiceEffectiveStatement statement();
26 * Returns resolved {@link CaseRuntimeType} for specified binding class name.
28 * @param typeName Binding class name
29 * @return {@link CaseRuntimeType}, or null if absent
30 * @throws NullPointerException if {@code typeName} is null
32 @Nullable CaseRuntimeType bindingCaseChild(JavaTypeName typeName);
35 * Return all {@link CaseRuntimeType} valid at this type's statement.
37 * @return Valid {@link CaseRuntimeType}s
39 @NonNull List<CaseRuntimeType> validCaseChildren();