All Downloads are FREE. Search and download functionalities are using the official Maven repository.

src.samples.java.ex.CNC_Sample Maven / Gradle / Ivy

Go to download

An auxiliary findbugs.sourceforge.net plugin for java bug detectors that fall outside the narrow scope of detectors to be packaged with the product itself.

There is a newer version: 7.6.8
Show newest version
package ex;

import java.util.Collections;
import java.util.HashSet;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.Set;

public class CNC_Sample {
    // tag CNC_COLLECTION_NAMING_CONFUSION
    Map argList;
    // tag CNC_COLLECTION_NAMING_CONFUSION
    Set targetMap;
    // tag CNC_COLLECTION_NAMING_CONFUSION
    List bernoulliSet;

    LinkedList mLinkedList = new LinkedList<>();

    // tag 3xCNC_COLLECTION_NAMING_CONFUSION
    public void testCNC(Map argSet, Set nameList, List nameMap) {

        nameList.addAll(transferData(nameMap));
    }

    private Set transferData(List oldList) {
        if (oldList.isEmpty()) {
            return Collections.emptySet();
        }
        // tag CNC_COLLECTION_NAMING_CONFUSION
        Set newList = new HashSet<>();
        for (String s : oldList) {
            newList.add(s);
        }
        return newList;

    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy