*/
package org.opendaylight.yangtools.yang.data.api.schema;
-import java.util.Collection;
+import org.eclipse.jdt.annotation.NonNull;
import org.opendaylight.yangtools.yang.data.api.YangInstanceIdentifier.NodeIdentifier;
/**
- * Normalized Node container which preserves user supplied ordering
- * and allows addressing of child elements by position.
+ * A {@link NormalizedNodeContainer} which preserves user supplied ordering and allows addressing of child elements by
+ * position. All implementations of this interface must also implement {@link OrderingAware.User}.
*
* @param <V> child type
*/
-public interface OrderedNodeContainer<V extends NormalizedNode<?, ?>> extends MixinNode,
- NormalizedNode<NodeIdentifier, Collection<V>> {
+public interface OrderedNodeContainer<V extends NormalizedNode>
+ extends NormalizedNodeContainer<NodeIdentifier, V>, MixinNode, OrderingAware.User {
/**
* Returns child node by position.
*
* @return Child Node
* @throws IndexOutOfBoundsException Out of bound Exception
*/
- V getChild(int position);
+ // FIXME: 7.0.0: rename to 'childAt(int)'
+ @NonNull V getChild(int position);
- /**
- * Returns count of child nodes.
- *
- * @return count of child nodes.
- */
- int getSize();
+ // FIXME: 7.0.0: do we really mean 'List' for body?
+ // @Override
+ // List<V> body();
+
+ @Override
+ int hashCode();
+
+ @Override
+ boolean equals(Object obj);
}