/**
* Subtree codec specific to model subtree between Java Binding and
* NormalizedNode.
- *
*/
@Beta
-public interface BindingCodecTreeNode<T extends DataObject> extends BindingNormalizedNodeCodec<T>,
- org.opendaylight.yangtools.binding.data.codec.api.BindingCodecTreeNode<T> {
+public interface BindingCodecTreeNode<T extends DataObject> extends BindingNormalizedNodeCodec<T> {
/**
- *
* Returns binding class of interface which represents API of current
* schema node.
*
*
* @return interface which defines API of binding representation of data.
*/
- @Override
@Nonnull
Class<T> getBindingClass();
/**
- *
* Returns child context as if it was walked by
* {@link BindingStreamEventWriter}. This means that to enter case, one must
* issue getChild(ChoiceClass).getChild(CaseClass).
* @throws IllegalArgumentException
* If supplied child class is not valid in specified context.
*/
- @Override
@Nonnull
<E extends DataObject> BindingCodecTreeNode<E> streamChild(@Nonnull Class<E> childClass);
/**
- *
* Returns child context as if it was walked by
* {@link BindingStreamEventWriter}. This means that to enter case, one must
* issue getChild(ChoiceClass).getChild(CaseClass).
* @return Context of child or Optional absent is supplied class is not
* applicable in context.
*/
- @Override
<E extends DataObject> Optional<? extends BindingCodecTreeNode<E>> possibleStreamChild(@Nonnull Class<E> childClass);
/**
* @throws IllegalArgumentException
* If supplied argument does not represent valid child.
*/
- @Override
@Nonnull
BindingCodecTreeNode<?> yangPathArgumentChild(@Nonnull YangInstanceIdentifier.PathArgument child);
* @throws IllegalArgumentException
* If supplied argument does not represent valid child.
*/
- @Override
@Nonnull
BindingCodecTreeNode<?> bindingPathArgumentChild(@Nonnull InstanceIdentifier.PathArgument arg,
@Nullable List<YangInstanceIdentifier.PathArgument> builder);
/**
- *
* Returns codec which uses caches serialization / deserialization results
*
* Caching may introduce performance penalty to serialization / deserialization
* @param cacheSpecifier Set of objects, for which cache may be in place
* @return Codec whihc uses cache for serialization / deserialization.
*/
- @Override
@Nonnull
BindingNormalizedNodeCachingCodec<T> createCachingCodec(@Nonnull
ImmutableCollection<Class<? extends DataObject>> cacheSpecifier);
- @Override
@Beta
void writeAsNormalizedNode(T data, NormalizedNodeStreamWriter writer);
* representation for current node (e.g. case).
* @throws IllegalArgumentException If supplied {@code arg} is not valid.
*/
- @Override
@Beta
@Nullable YangInstanceIdentifier.PathArgument serializePathArgument(@Nullable InstanceIdentifier.PathArgument arg);
* representation for current node (e.g. choice or case).
* @throws IllegalArgumentException If supplied {@code arg} is not valid.
*/
- @Override
@Beta
@Nullable InstanceIdentifier.PathArgument deserializePathArgument(@Nullable YangInstanceIdentifier.PathArgument arg);
- @Override
Object getSchema();
}