Showing 9,050 of 9,050 total issues
Method outArg
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
static <T> void outArg(final T condition, final Class<?> clazz, final String message) {
if (condition instanceof Boolean) {
// If boolean, condition = true, throw Error
final Boolean check = (Boolean) condition;
if (check) {
- Read upRead up
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 json
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public JsonObject json(final Object entity, final boolean overwrite) {
final JsonObject data = Ut.serializeJson(entity);
final JsonObject merged = this.converted.copy();
for (final String field : data.fieldNames()) {
if (overwrite) {
- Read upRead up
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 get
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
@SuppressWarnings("unchecked")
public static <T> KLexeme<T> get(final Class<T> interfaceCls) {
if (Objects.isNull(interfaceCls)) {
return null;
} else {
- Read upRead up
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 outAsync
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
@SuppressWarnings("all")
static <T> Future<T> outAsync(final Class<?> target, final Throwable error) {
final WebException failure;
if (Objects.isNull(error)) {
// 异常为 null
- Read upRead up
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 border
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public DyeCell border(final Short color, final BorderStyle... borders) {
// CSS Calculation
if (0 < borders.length) {
if (1 == borders.length) {
// length = 1, all border
- Read upRead up
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 itSheet
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public static void itSheet(final Sheet sheet,
final ExBound bound,
final Set<Integer> indexSet,
final Consumer<List<Row>> consumer) {
/* Start / End */
- Read upRead up
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 onRow
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public static void onRow(final Sheet sheet,
final int rowIndex,
final Consumer<Row> consumer,
final Predicate<Row> predicate) {
final Row row = sheet.getRow(rowIndex);
- Read upRead up
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 onCell
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public static void onCell(final Row row,
final int columnIndex,
final Consumer<Cell> consumer,
final Predicate<Cell> predicate) {
final Cell cell = row.getCell(columnIndex);
- Read upRead up
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 createCell
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
private static void createCell(final Row row, final Integer index, final Object value, final Class<?> typeDef) {
if (Objects.isNull(value)) {
/* Cell create */
final Cell cell = row.createCell(index);
/* null filling */
- Read upRead up
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 authorization
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
@Override
public AuthorizationHandler authorization(final Vertx vertx, final Aegis config) {
final Class<?> handlerCls = config.getHandler();
if (Objects.isNull(handlerCls)) {
// Default profile is no access ( 403 )
- Read upRead up
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 inGateway
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
static PassWay inGateway(final JsonObject requestJ) {
// toUser field extraction
final JsonObject requestData = Ut.valueJObject(requestJ);
final Object toUser = requestData.getValue(KName.Auditor.TO_USER);
if (toUser instanceof String) {
- Read upRead up
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 generate
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
public static void generate(final WTodo generated, final WTodo wTask,
final WTicket ticket) {
final TodoStatus todoStatus = Ut.toEnum(wTask.getStatus(), TodoStatus.class);
/*
* 状态计算,若没有目标状态则直接设置 PENDING
- Read upRead up
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 buildSerial
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
protected void buildSerial(final WTodo todo, final WTicket ticket, final Integer sequence) {
// Based On SerialFork
final String serialFork = todo.getSerialFork();
final StringBuilder serialBuf = new StringBuilder();
serialBuf.append(ticket.getSerial()).append(VString.DASH);
- Read upRead up
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 contract
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
protected <T> void contract(final T instance) {
if (Objects.nonNull(instance)) {
/*
* Here contract `Dict` will not be support under JtComponent here
*/
- Read upRead up
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 fetchNorm
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
@Override
public Future<JsonArray> fetchNorm(final String sourceKey, final String targetKey) {
if (Ut.isNil(sourceKey) && Ut.isNil(targetKey)) {
return Ux.futureA();
} else {
- Read upRead up
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 complete
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
static Handler<AsyncResult<Boolean>> complete(final String folder, final String prefix, final UxTimer timer) {
return handler -> {
if (handler.succeeded()) {
if (Objects.isNull(prefix)) {
LOG.Ke.info(LOGGER, "The data folder `{0}` has been imported successfully!", folder);
- Read upRead up
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 output
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
private void output(final String table, final List<DataRow> rows, final Record[] records) {
for (int idx = VValue.IDX; idx < rows.size(); idx++) { /* 两个数据集按索引合并 */
final DataRow row = rows.get(idx);
if (null != row) {
if (idx < records.length) {
- Read upRead up
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 synchron
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
@Override
public boolean synchron(final Schema schema) {
// 检查表是否存在
final String tableName = schema.getTable();
final boolean exist = this.getVerifier().verifyTable(tableName);
- Read upRead up
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 compare
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
@Override
public int compare(final MField fieldOne, final MField fieldTwo) {
final String colOne = fieldOne.getColumnName();
final String colTwo = fieldTwo.getColumnName();
if (colOne == null || colTwo == null) {
- Read upRead up
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 ensurePath
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
@SuppressWarnings("unused")
private void ensurePath(final String path) {
if (0 <= path.lastIndexOf('/')) {
final String parent = path.substring(0, path.lastIndexOf('/'));
try {
- Read upRead up
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"