2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2017 AT&T Intellectual Property. All rights
7 * ================================================================================
8 * Licensed under the Apache License, Version 2.0 (the "License");
9 * you may not use this file except in compliance with the License.
10 * You may obtain a copy of the License at
12 * http://www.apache.org/licenses/LICENSE-2.0
14 * Unless required by applicable law or agreed to in writing, software
15 * distributed under the License is distributed on an "AS IS" BASIS,
16 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * See the License for the specific language governing permissions and
18 * limitations under the License.
19 * ============LICENSE_END=========================================================
22 package org.openecomp.sdnc.sli.provider;
24 import java.util.HashMap;
25 import java.util.Properties;
27 import org.opendaylight.controller.md.sal.dom.api.DOMDataBroker;
28 import org.openecomp.sdnc.sli.SvcLogicContext;
29 import org.openecomp.sdnc.sli.SvcLogicException;
30 import org.openecomp.sdnc.sli.SvcLogicGraph;
35 public interface SvcLogicService {
37 public static final String NAME = "org.openecomp.sdnc.sli.provider.SvcLogicService";
39 // public SvcLogicContext execute(SvcLogicGraph graph, SvcLogicContext ctx) throws SvcLogicException;
41 * Check for existence of a directed graph
42 * @param module - module name
43 * @param rpc - rpc name
44 * @param version - version. If null, looks for active version
45 * @param mode - mode (sync/async)
46 * @return true if directed graph found, false otherwise
47 * @throws SvcLogicException
49 public boolean hasGraph(String module, String rpc, String version, String mode) throws SvcLogicException;
52 * Execute a directed graph
54 * @param module - module name
55 * @param rpc - rpc name
56 * @param version - version. If null, use active version
57 * @param mode - mode (sync/async)
58 * @param parms - parameters, used to set SvcLogicContext attributes
59 * @return final values of attributes from SvcLogicContext, as Properties
60 * @throws SvcLogicException
63 * @deprecated use execute(String module, String rpc, String version, String mode, DOMDataBroker dataBroker) instead
66 public Properties execute(String module, String rpc, String version, String mode, Properties parms) throws SvcLogicException;
69 * Execute a directed graph
71 * @param module - module name
72 * @param rpc - rpc name
73 * @param version - version. If null, use active version
74 * @param mode - mode (sync/async)
75 * @param parms - parameters, used to set SvcLogicContext attributes
76 * @param domDataBroker - DOMDataBroker object
77 * @return final values of attributes from SvcLogicContext, as Properties
78 * @throws SvcLogicException
80 public Properties execute(String module, String rpc, String version, String mode, Properties parms, DOMDataBroker domDataBroker) throws SvcLogicException;