Rome hackathon work integrated onto boron.
[unimgr.git] / impl / src / main / java / org / mef / nrp / impl / ActivationDriverRepoService.java
1 /*
2  * Copyright (c) 2016 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.mef.nrp.impl;
10
11 import org.opendaylight.yang.gen.v1.uri.onf.coremodel.corenetworkmodule.objectclasses.rev160413.GFcPort;
12
13 /**
14  * This interface is used to request an ActivationDriver for a given MEF service fragment.
15  */
16 public interface ActivationDriverRepoService {
17
18     void bindBuilder(ActivationDriverBuilder builder);
19
20     void unbindBuilder(ActivationDriverBuilder builder);
21
22     /**
23      * Get driver for a port.
24      * @param port to
25      * @param context blackboard for recording state during driver selection
26      * @return activation driver
27      * @throws ActivationDriverAmbiguousException when multiple drivers declare they can configure port
28      * @throws ActivationDriverNotFoundException when no driver found for port
29      */
30     ActivationDriver getDriver(GFcPort port, ActivationDriverBuilder.BuilderContext context);
31
32     /**
33      * Get driver for two ports on a single device.
34      * @param aPort from port
35      * @param zPort to port
36      * @param context blackboard for recording state during driver selection
37      * @return activation driver
38      * @throws ActivationDriverAmbiguousException when multiple drivers declare they can configure ports
39      * @throws ActivationDriverNotFoundException when no driver found for ports
40      */
41     ActivationDriver getDriver(GFcPort aPort, GFcPort zPort, ActivationDriverBuilder.BuilderContext context);
42 }