2 * Copyright (c) 2023 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.yangtools.yang.data.api.schema;
10 import com.google.common.annotations.Beta;
11 import org.eclipse.jdt.annotation.NonNull;
12 import org.eclipse.jdt.annotation.Nullable;
13 import org.opendaylight.yangtools.concepts.Immutable;
16 * A tuple of normalized {@link #data()}, with corresponding {@link #metadata()} and {@link #mountPoints()}. The three
17 * views are expected to be consistent in their addressing -- i.e. when traversing {@link #data()} tree,
18 * the corresponding metadata should be available through {@link NormalizedMetadata#getChildren()} and mount point
19 * attachments should be available through {@link NormalizedMountpoints#getChildren()}.
21 // FIXME: this interface could use a traversal utility which binds together the 'NormalizedNodeContainer' part and
22 // the corresponding metadata and/or mount points. Most notably mount points are only defined for ContainerNode
25 public interface NormalizedTuple<T extends NormalizedNode> extends Immutable {
27 * Return the data portion of this tree.
29 * @return Data portion of this tree.
34 * Return the metadata portion of this tree. This portion is optional.
36 * @return Metadata portion of this tree.
38 @Nullable NormalizedMetadata metadata();
41 * Return the mount point portion of this tree. This portion is optional.
43 * @return mount point portion of this tree.
45 @Nullable NormalizedMountpoints mountPoints();