Bug 4202: Migrate also toaster to use mdsal project
[controller.git] / opendaylight / commons / concepts / src / main / java / org / opendaylight / controller / concepts / transform / RuleBasedTransformer.java
1 /*
2  * Copyright (c) 2013 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
9 package org.opendaylight.controller.concepts.transform;
10
11 import java.util.Set;
12
13 /**
14  * Transformer with set of acceptance rules
15  *
16  * The transformer provides a set of {@link Acceptor}s, which could be used to
17  * verify if the input will produce result using the transformer.
18  *
19  * The transormer is able to produce result if ANY of associated
20  * {@link Acceptor}s accepted result.
21  *
22  * @author Tony Tkacik
23  *
24  * @param <I>
25  *            Input class for transformation
26  * @param <P>
27  *            Product of transformation
28  */
29 public interface RuleBasedTransformer<I, P> extends Transformer<I, P> {
30
31     /**
32      * Set of {@link Acceptor}, which could be used to verify if the input is
33      * usable by transformer.
34      *
35      * The transformer is able to produce result if ANY of associated
36      * {@link Acceptor}s accepted result.
37      *
38      * @return Set of input acceptance rules associated to this transformer.
39      */
40     Set<Acceptor<I>> getRules();
41
42 }