a44af58f0d4b3da5aaf7e8753e8312b6b8d811bf
[mdsal.git] / binding / mdsal-binding-runtime-api / src / main / java / org / opendaylight / mdsal / binding / runtime / api / BindingRuntimeGenerator.java
1 /*
2  * Copyright (c) 2018 Pantheon Technologies, s.r.o.  All rights reserved.
3  *
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
7  */
8 package org.opendaylight.mdsal.binding.runtime.api;
9
10 import com.google.common.annotations.Beta;
11 import org.eclipse.jdt.annotation.NonNullByDefault;
12 import org.opendaylight.yangtools.yang.model.api.EffectiveModelContext;
13
14 /**
15  * Runtime binding type generator. Generated types contain metadata required for integrating compile-time generated
16  * code with YANG-modeled schema.
17  */
18 @Beta
19 @NonNullByDefault
20 public interface BindingRuntimeGenerator {
21     /**
22      * Generate Type mapping from specified {@link EffectiveModelContext} for the specified subset of modules.
23      * The EffectiveModelContext MUST contain all of the sub modules otherwise the there is no guarantee that result
24      * List of Generated Types will contain correct Generated Types.
25      *
26      * @param context Schema Context
27      * @return Generated type mapping.
28      */
29     BindingRuntimeTypes generateTypeMapping(EffectiveModelContext context);
30 }