Java AtomicInteger decrementVxlanGpeRefCnt(final String vxlanGpePortKey, final String vppNode)

Here you can find the source of decrementVxlanGpeRefCnt(final String vxlanGpePortKey, final String vppNode)

Description

decrement Vxlan Gpe Ref Cnt

License

Open Source License

Declaration

private static int decrementVxlanGpeRefCnt(final String vxlanGpePortKey, final String vppNode) 

Method Source Code

//package com.java2s;
/*/*from  w  w  w  .j  av  a  2  s. co m*/
 * Copyright (c) 2016, 2017 Cisco Systems, Inc. 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
 */

import java.util.HashMap;

import java.util.concurrent.atomic.AtomicInteger;

public class Main {
    private static final HashMap<String, HashMap<String, AtomicInteger>> VXLAN_GPER_PORT_REF_CNT = new HashMap<>();

    private static int decrementVxlanGpeRefCnt(final String vxlanGpePortKey, final String vppNode) {
        if (VXLAN_GPER_PORT_REF_CNT.get(vppNode) == null) {
            return 0;
        }
        if (VXLAN_GPER_PORT_REF_CNT.get(vppNode).get(vxlanGpePortKey) == null) {
            return 0;
        }
        return VXLAN_GPER_PORT_REF_CNT.get(vppNode).get(vxlanGpePortKey).decrementAndGet();
    }
}

Related

  1. create()
  2. createIdentifier(Class clazz)
  3. createNewTestNamespace( Map environmentProperties)
  4. createThreadFactory(final String prefix)
  5. decrementStoredNoOfParts()
  6. decrementWheelsCount()
  7. deleteIndexedFields(Set fieldsToDelete, List fields, Map fieldIndexLookupMap)
  8. encodeMap(Map map)
  9. generateUniqueId()