Bug 6859 #3 Binding generator v1 refactoring
[mdsal.git] / binding / mdsal-binding-dom-codec / src / main / java / org / opendaylight / mdsal / binding / dom / codec / api / BindingCodecTreeFactory.java
1 /*
2  * Copyright (c) 2015 Cisco Systems, Inc. and others.  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.dom.codec.api;
9
10 import com.google.common.annotations.Beta;
11 import org.opendaylight.mdsal.binding.generator.util.BindingRuntimeContext;
12 import org.opendaylight.yangtools.yang.model.api.SchemaContext;
13
14 public interface BindingCodecTreeFactory extends
15         org.opendaylight.yangtools.binding.data.codec.api.BindingCodecTreeFactory {
16
17     /**
18      *
19      * Creates Binding Codec Tree for specified Binding runtime context.
20      *
21      * @param context
22      *            Binding Runtime Context for which Binding codecs should be
23      *            instantiated.
24      * @return Binding Codec Tree for specified Binding runtime context.
25      */
26     @Override
27     BindingCodecTree create(BindingRuntimeContext context);
28
29     /**
30      *
31      * Creates Binding Codec Tree for specified Binding runtime context.
32      *
33      * @param context
34      *            Binding Runtime Context for which Binding codecs should be
35      *            instantiated.
36      * @param bindingClasses
37      *            Binding Runtime Context will be constructed using bindings
38      *            which contains specified classes, in order to support
39      *            deserialization in multi-classloader environment.
40      * @return Binding Codec Tree for specified Binding runtime context.
41      */
42     @Override
43     @Beta
44    BindingCodecTree create(SchemaContext context, Class<?>... bindingClasses);
45
46 }