X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=sdnr%2Fwireless-transport%2Fcode-Carbon-SR1%2Fapps%2Froute%2Fimpl%2Fsrc%2Fmain%2Fjava%2Fcom%2Fhighstreet%2Ftechnologies%2Fodl%2Fapp%2Fimpl%2FPathHolder.java;fp=sdnr%2Fwireless-transport%2Fcode-Carbon-SR1%2Fapps%2Froute%2Fimpl%2Fsrc%2Fmain%2Fjava%2Fcom%2Fhighstreet%2Ftechnologies%2Fodl%2Fapp%2Fimpl%2FPathHolder.java;h=0000000000000000000000000000000000000000;hb=1c1e7f98416875f3ee78af9103865c32f95a82a0;hp=3365d591aaea7195a48f3fce11e2e1f96cdc4516;hpb=6a893bb0ae984d15076394d9225d4873ad953791;p=ccsdk%2Fapps.git diff --git a/sdnr/wireless-transport/code-Carbon-SR1/apps/route/impl/src/main/java/com/highstreet/technologies/odl/app/impl/PathHolder.java b/sdnr/wireless-transport/code-Carbon-SR1/apps/route/impl/src/main/java/com/highstreet/technologies/odl/app/impl/PathHolder.java deleted file mode 100644 index 3365d591..00000000 --- a/sdnr/wireless-transport/code-Carbon-SR1/apps/route/impl/src/main/java/com/highstreet/technologies/odl/app/impl/PathHolder.java +++ /dev/null @@ -1,54 +0,0 @@ -/* - * Copyright © 2015 ZTE and others. All rights reserved. - * - * This program and the accompanying materials are made available under the - * terms of the Eclipse Public License v1.0 which accompanies this distribution, - * and is available at http://www.eclipse.org/legal/epl-v10.html - */ -package com.highstreet.technologies.odl.app.impl; - -import com.highstreet.technologies.odl.app.impl.delegates.LtpInOdlCreator; -import com.highstreet.technologies.odl.app.impl.delegates.PathDelegate; -import com.highstreet.technologies.odl.app.impl.tools.NeExecutor; -import org.opendaylight.controller.md.sal.binding.api.DataBroker; -import org.opendaylight.controller.md.sal.common.api.data.TransactionCommitFailedException; - -import java.util.ArrayList; - -/** - * Created by odl on 17-6-2. - */ -public class PathHolder -{ - public PathHolder(DataBroker dataBroker, Integer vlanId) - { - this.pathDelegate = new PathDelegate(dataBroker, vlanId); - } - - private final PathDelegate pathDelegate; - private ArrayList list = new ArrayList<>(); - private LtpInOdlCreator ltpCreator = new LtpInOdlCreator(); - - public void add(NeExecutor to) - { - list.add(to); - pathDelegate.add(to.getLtp()); - } - - public void commit() throws TransactionCommitFailedException - { - list.forEach(NeExecutor::commit); - pathDelegate.commit(); - } - - public void clear(int vlanId) throws TransactionCommitFailedException - { - list.forEach(neExecutor -> neExecutor.clear(vlanId)); - pathDelegate.clear(); - } - - public LtpInOdlCreator getLtpCreator() - { - return ltpCreator; - } -}