2 * Copyright (c) 2013 Cisco Systems, Inc. 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.model.api;
10 import com.google.common.collect.ImmutableList;
11 import java.util.Collection;
12 import java.util.List;
13 import javax.annotation.Nonnull;
14 import org.opendaylight.yangtools.yang.common.QName;
17 * Interface describing YANG 'list' statement.
19 * The 'list' statement is used to define an interior data node in the schema
20 * tree. A list entry is uniquely identified by the values of the list's keys,
24 public interface ListSchemaNode extends DataNodeContainer, AugmentationTarget, DataSchemaNode,
25 NotificationNodeContainer, ActionNodeContainer {
27 * Returns the list of leaf identifiers.
29 * @return List of QNames of leaf identifiers of this list
31 List<QName> getKeyDefinition();
34 * YANG 'ordered-by' statement. It defines whether the order of entries
35 * within a list are determined by the user or the system. If not present,
38 * @return true if ordered-by argument is "user", false otherwise
40 boolean isUserOrdered();
43 * Returns unique constraints.
45 * @return Collection of unique constraints of this list schema node
48 default Collection<UniqueConstraint> getUniqueConstraints() {
49 return ImmutableList.of();