Showing 6,856 of 14,752 total issues
Method createCategory
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
private Category createCategory(Map<Integer, UnitsFromDB> units, String categoryName) {
DJep parser = MathUtilities.createParser();
Map<String, Node> fromFormulas = new LinkedHashMap<>();
Map<String, Node> toFormulas = new LinkedHashMap<>();
Map<String, String> fromFormulaStrings = new LinkedHashMap<>();
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method release
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
public synchronized void release() throws RException {
if (!m_available) {
// Either m_pendingDestructionTask is null, which means
// this resource is being held, or the resource is available
// and has destruction pending.
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method getMiscUnits
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
public static Map<String, String> getMiscUnits(List<KnimeTuple> tuples) {
Map<String, Map<String, Integer>> occurences = new LinkedHashMap<>();
Map<String, String> map = new LinkedHashMap<>();
for (KnimeTuple tuple : tuples) {
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method getColor
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
private Color getColor(String param, Color lastBG, String lastParam) {
Color bg = Color.WHITE;
@SuppressWarnings("unused")
Color fg = Color.BLACK;
if (JCheckboxWithObject.isTemperature(param)) {
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function createForm
has a Cognitive Complexity of 16 (exceeds 5 allowed). Consider refactoring. Open
var createForm = (prop, value, port) => {
let isMandatory = prop.required ? prop.required : false;
if (prop.type === "text" || prop.type === "number" || prop.type === "url" ||
prop.type === "date" || prop.type === "email" || prop.type === "year_date")
- Read upRead up
- Create a ticketCreate a ticket
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Method convertParameter
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
static Parameter convertParameter(JsonNode node) {
Parameter parameter = new Parameter();
if (node.has("parameterID")) {
- Create a ticketCreate a ticket
Method eSet
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
case MetadataPackage.POPULATION_GROUP__POPULATION_NAME:
- Create a ticketCreate a ticket
Method loadSettingsFrom
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
@Override
protected void loadSettingsFrom(final NodeSettingsRO settings, final DataTableSpec[] specs)
throws NotConfigurableException {
set = new SettingsHelper();
set.loadSettings(settings);
- Create a ticketCreate a ticket
Method checkForeignWindow2Open
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
private void checkForeignWindow2Open(final int row, final int col) {
MyTable[] myTs = actualTable.getForeignFields();
//System.out.println(lastClickedRow + "\t" + lastClickedCol + "\t" + myTs.length);
if (col > 0 && col <= myTs.length && myTs[col-1] != null &&
!myTs[col-1].getTablename().equals("DoubleKennzahlen")) {
- Create a ticketCreate a ticket
Method dbBackup
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
private static void dbBackup(final JFrame frame, final File backupFile, final boolean silent) {
if (backupFile != null && backupFile.getParentFile().exists() && DBKernel.DBFilesDa(DBKernel.HSHDB_PATH, DBKernel.dbKennung)) {
try {
if (backupFile.exists()) {
backupFile.delete();
- Create a ticketCreate a ticket
Method execute
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
@Override
protected PortObject[] execute(final PortObject[] inData, final ExecutionContext exec)
throws Exception {
try {
FskPortObject portObj = new FskPortObject();
- Create a ticketCreate a ticket
Method getPoints
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
public double[][] getPoints(String paramX, String paramY, String unitX,
String unitY, String transformX, String transformY,
Map<String, Integer> choice) throws ConvertException {
List<Double> xList = valueLists.get(paramX);
List<Double> yList = valueLists.get(paramY);
- Create a ticketCreate a ticket
Method createPcData
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
private void createPcData(PCMLDocument pcmlDoc, final PortObject[] inObjects) {
PCML pcml = pcmlDoc.getPCML();
ProcessChain pChain = pcml.addNewProcessChain();
// Fetches model metadata from the 1st table (metadata table)
- Create a ticketCreate a ticket
Function formatStringFactory
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
function formatStringFactory(delimiter, tokenOuter) {
while ("rubf".indexOf(delimiter.charAt(0).toLowerCase()) >= 0)
delimiter = delimiter.substr(1);
var singleline = delimiter.length == 1;
- Create a ticketCreate a ticket
Function Display
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
function Display(place, doc, input, options) {
var d = this;
this.input = input;
// Covers bottom-right square when both scrollbars are present.
- Create a ticketCreate a ticket
Function findPosH
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
function findPosH(doc, pos, dir, unit, visually) {
var oldPos = pos;
var origDir = dir;
var lineObj = getLine(doc, pos.line);
function findNextLine() {
- Create a ticketCreate a ticket
Function onDrop
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
function onDrop(e) {
var cm = this;
clearDragCursor(cm);
if (signalDOMEvent(cm, e) || eventInWidget(cm.display, e))
{ return }
- Create a ticketCreate a ticket
Function _positionDropdown
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
AttachBody.prototype._positionDropdown = function () {
var $window = $(window);
var isCurrentlyAbove = this.$dropdown.hasClass('select2-dropdown--above');
var isCurrentlyBelow = this.$dropdown.hasClass('select2-dropdown--below');
- Create a ticketCreate a ticket
Function event
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
brush.event = function(g) {
g.each(function() {
var event_ = event.of(this, arguments), extent1 = {
x: xExtent,
y: yExtent,
- Create a ticketCreate a ticket
Function _refreshValue
has 52 lines of code (exceeds 25 allowed). Consider refactoring. Open
_refreshValue: function() {
var lastValPercent, valPercent, value, valueMin, valueMax,
oRange = this.options.range,
o = this.options,
that = this,
- Create a ticketCreate a ticket