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.restconf.nb.rfc8040.databind;
10 import com.google.common.annotations.Beta;
11 import java.io.IOException;
12 import org.eclipse.jdt.annotation.NonNullByDefault;
13 import org.opendaylight.yangtools.yang.data.api.schema.stream.NormalizedNodeStreamWriter;
14 import org.opendaylight.yangtools.yang.model.util.SchemaInferenceStack.Inference;
17 * Access to an {code rpc}'s or an {@code action}'s input.
22 public interface StreamableOperationInput {
24 * Stream the {@code input} into a {@link NormalizedNodeStreamWriter}.
26 * @param inference An {@link Inference} of parent {@code rpc} or {@code action} statement
27 * @param writer Target writer
28 * @throws IOException when an I/O error occurs
30 // TODO: pass down DatabindContext corresponding to inference
31 void streamTo(Inference inference, NormalizedNodeStreamWriter writer) throws IOException;