Showing 6,856 of 14,752 total issues
Function d3_time_scale
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function d3_time_scale(linear, methods, format) {
function scale(x) {
return linear(x);
}
scale.invert = function(x) {
- Create a ticketCreate a ticket
Function stretchSpansOverChange
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function stretchSpansOverChange(doc, change) {
if (change.full) { return null }
var oldFirst = isLine(doc, change.from.line) && getLine(doc, change.from.line).markedSpans
var oldLast = isLine(doc, change.to.line) && getLine(doc, change.to.line).markedSpans
if (!oldFirst && !oldLast) { return null }
- Create a ticketCreate a ticket
Function updateDisplayIfNeeded
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function updateDisplayIfNeeded(cm, update) {
var display = cm.display, doc = cm.doc
if (update.editorIsHidden) {
resetView(cm)
- Create a ticketCreate a ticket
Function _mouseCapture
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
_mouseCapture: function( event ) {
var position, normValue, distance, closestHandle, index, allowed, offset, mouseOverHandle,
that = this,
o = this.options;
- Create a ticketCreate a ticket
Function _determineDate
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
_determineDate: function(inst, date, defaultDate) {
var offsetNumeric = function(offset) {
var date = new Date();
date.setDate(date.getDate() + offset);
return date;
- Create a ticketCreate a ticket
Function drawForLine
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function drawForLine(line, fromArg, toArg) {
var lineObj = getLine(doc, line)
var lineLen = lineObj.text.length
var start, end
function coords(ch, bias) {
- Create a ticketCreate a ticket
Function locateNodeInLineView
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function locateNodeInLineView(lineView, node, offset) {
var wrapper = lineView.text.firstChild, bad = false
if (!node || !contains(wrapper, node)) { return badPos(Pos(lineNo(lineView.line), 0), true) }
if (node == wrapper) {
bad = true
- Create a ticketCreate a ticket
Function indentLine
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function indentLine(cm, n, how, aggressive) {
var doc = cm.doc, state
if (how == null) { how = "add" }
if (how == "smart") {
// Fall back to "prev" when the mode doesn't have an indentation
- Create a ticketCreate a ticket
Function initUI
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function initUI() {
function createMetadataList(parameter) {
const formatProperty = (name, value) => value ? `<li><b>${name}</b>: ${value}</li>` : '';
- Create a ticketCreate a ticket
Function updateDisplayIfNeeded
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function updateDisplayIfNeeded(cm, update) {
var display = cm.display, doc = cm.doc
if (update.editorIsHidden) {
resetView(cm)
- Create a ticketCreate a ticket
Function init
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
view.init = function (representation, value) {
_rep = representation;
_val = value;
- Create a ticketCreate a ticket
Function stretchSpansOverChange
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function stretchSpansOverChange(doc, change) {
if (change.full) { return null }
var oldFirst = isLine(doc, change.from.line) && getLine(doc, change.from.line).markedSpans
var oldLast = isLine(doc, change.to.line) && getLine(doc, change.to.line).markedSpans
if (!oldFirst && !oldLast) { return null }
- Create a ticketCreate a ticket
Function indentLine
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function indentLine(cm, n, how, aggressive) {
var doc = cm.doc, state
if (how == null) { how = "add" }
if (how == "smart") {
// Fall back to "prev" when the mode doesn't have an indentation
- Create a ticketCreate a ticket
Function drawForLine
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function drawForLine(line, fromArg, toArg) {
var lineObj = getLine(doc, line)
var lineLen = lineObj.text.length
var start, end
function coords(ch, bias) {
- Create a ticketCreate a ticket
Function locateNodeInLineView
has 48 lines of code (exceeds 25 allowed). Consider refactoring. Open
function locateNodeInLineView(lineView, node, offset) {
var wrapper = lineView.text.firstChild, bad = false
if (!node || !contains(wrapper, node)) { return badPos(Pos(lineNo(lineView.line), 0), true) }
if (node == wrapper) {
bad = true
- Create a ticketCreate a ticket
Method saveWF
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
private void saveWF() throws Exception {
for (NodeContainer nc : WorkflowManager.ROOT.getNodeContainers()) {
if (nc instanceof WorkflowManager) {
WorkflowManager wfm = (WorkflowManager) nc;
for (WriterNodeModel m : wfm.findNodes(WriterNodeModel.class, true).values()) {
- 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 createDataset
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
private XYDataset createDataset(final Double mini, final Double maxi, final double step) {
series2.clear();
newStrDataSet = "";
for (int i=0;i<table1.getModel().getRowCount();i++) {
Object o1 = table1.getModel().getValueAt(i, 0);
- 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 convertProduct
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
static Product convertProduct(JsonNode node) {
Product product = new Product();
if (node.has("productName")) {
- 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 equals
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null || getClass() != obj.getClass())
- 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 equals
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
- 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"