X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=blueprints-processor%2Fadaptors%2Fdata-adaptor-provider%2Fsrc%2Fmain%2Fjava%2Forg%2Fonap%2Fccsdk%2Fconfig%2Fdata%2Fadaptor%2Fservice%2FConfigResourceServiceImpl.java;h=c8803092a3b633d17e7ab851de74621928a4beb5;hb=d2cc0336c4dd9875e717e096d8f9bf815cb783b7;hp=77fbbe1ab998e45af1ef721c5e4049af8140ed08;hpb=a43f31d01e92202e9bbb72ab0556c88790b3ce94;p=ccsdk%2Ffeatures.git diff --git a/blueprints-processor/adaptors/data-adaptor-provider/src/main/java/org/onap/ccsdk/config/data/adaptor/service/ConfigResourceServiceImpl.java b/blueprints-processor/adaptors/data-adaptor-provider/src/main/java/org/onap/ccsdk/config/data/adaptor/service/ConfigResourceServiceImpl.java index 77fbbe1ab..c8803092a 100644 --- a/blueprints-processor/adaptors/data-adaptor-provider/src/main/java/org/onap/ccsdk/config/data/adaptor/service/ConfigResourceServiceImpl.java +++ b/blueprints-processor/adaptors/data-adaptor-provider/src/main/java/org/onap/ccsdk/config/data/adaptor/service/ConfigResourceServiceImpl.java @@ -1,15 +1,18 @@ /* * Copyright © 2017-2018 AT&T Intellectual Property. + * Modifications Copyright © 2018 IBM. * - * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except - * in compliance with the License. You may obtain a copy of the License at + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * - * Unless required by applicable law or agreed to in writing, software distributed under the License - * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express - * or implied. See the License for the specific language governing permissions and limitations under - * the License. + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. */ package org.onap.ccsdk.config.data.adaptor.service; @@ -31,18 +34,18 @@ import com.att.eelf.configuration.EELFManager; public class ConfigResourceServiceImpl implements ConfigResourceService { private static EELFLogger logger = EELFManager.getInstance().getLogger(ConfigResourceServiceImpl.class); private static final String CLASS_NAME = "ConfigResourceServiceImpl"; - + private TransactionLogDao transactionLogDao; private ConfigResourceDao configResourceDao; private QueryExecutorDao queryExecutorDao; private NamedQueryExecutorDao namedQueryExecutorDao; private ConfigPropertyMapDao configPropertyMapDao; - + @SuppressWarnings("squid:S00107") public ConfigResourceServiceImpl(TransactionLogDao transactionLogDao, ConfigResourceDao configResourceDao, QueryExecutorDao queryExecutorDao, NamedQueryExecutorDao namedQueryExecutorDao, ConfigPropertyMapDao configPropertyMapDao) { - + logger.info("{} Constuctor Initated...", CLASS_NAME); this.transactionLogDao = transactionLogDao; this.configResourceDao = configResourceDao; @@ -50,61 +53,61 @@ public class ConfigResourceServiceImpl implements ConfigResourceService { this.namedQueryExecutorDao = namedQueryExecutorDao; this.configPropertyMapDao = configPropertyMapDao; } - + @Override public NamedParameterJdbcTemplate getNamedParameterJdbcTemplate() throws SvcLogicException { return namedQueryExecutorDao.getNamedParameterJdbcTemplate(); } - + @Override public List> query(String sql, Map parameters) throws SvcLogicException { return namedQueryExecutorDao.query(sql, parameters); } - + @Override public int update(String sql, Map parameters) throws SvcLogicException { return namedQueryExecutorDao.update(sql, parameters); } - + @Override public List> query(String sql, Object[] data) throws SvcLogicException { return queryExecutorDao.query(sql, data); } - + @Override public int update(String sql, Object[] data) throws SvcLogicException { return queryExecutorDao.update(sql, data); } - + @Override public void save(TransactionLog transactionLog) throws SvcLogicException { transactionLogDao.save(transactionLog); } - + @Override public List getTransactionsByRequestId(String requestId) throws SvcLogicException { return transactionLogDao.getTransactionsByRequestId(requestId); } - + @Override public List getTransactionsByRequestId(String requestId, String messageType) throws SvcLogicException { return transactionLogDao.getTransactionsByRequestId(requestId, messageType); } - + @Override public List getConfigResource(ConfigResource configResource) throws SvcLogicException { return configResourceDao.findByConfigResource(configResource); } - + @Override public ConfigResource saveConfigResource(ConfigResource configResource) throws SvcLogicException { return configResourceDao.save(configResource); } - + @Override public String getConfigPropertyByKey(String key) throws SvcLogicException { return configPropertyMapDao.getConfigPropertyByKey(key); } - + }