IBM/scc-java-sdk

View on GitHub

Showing 183 of 183 total issues

Similar blocks of code found in 5 locations. Consider refactoring.
Open

/*
 * (C) Copyright IBM Corp. 2023.
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
 * the License. You may obtain a copy of the License at
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetProviderTypesInstancesOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetSettingsOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/PostTestEventOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/PropertyItem.java on lines 1..118

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 155.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

/*
 * (C) Copyright IBM Corp. 2023.
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
 * the License. You may obtain a copy of the License at
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetSettingsOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/ListProviderTypesOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/PostTestEventOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/PropertyItem.java on lines 1..118

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 155.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

/*
 * (C) Copyright IBM Corp. 2023.
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
 * the License. You may obtain a copy of the License at
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetProviderTypesInstancesOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/ListProviderTypesOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/PostTestEventOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/PropertyItem.java on lines 1..118

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 155.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

/*
 * (C) Copyright IBM Corp. 2023.
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
 * the License. You may obtain a copy of the License at
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetProviderTypesInstancesOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetSettingsOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/ListProviderTypesOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/PostTestEventOptions.java on lines 1..122

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 155.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 5 locations. Consider refactoring.
Open

/*
 * (C) Copyright IBM Corp. 2023.
 *
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
 * the License. You may obtain a copy of the License at
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetProviderTypesInstancesOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetSettingsOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/ListProviderTypesOptions.java on lines 1..122
modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/PropertyItem.java on lines 1..118

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 155.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Builder has 22 methods (exceeds 20 allowed). Consider refactoring.
Open

  public static class Builder {
    private String controlLibrariesId;
    private String id;
    private String accountId;
    private String controlLibraryName;

    ReplaceProfileAttachmentOptions has 21 methods (exceeds 20 allowed). Consider refactoring.
    Open

    public class ReplaceProfileAttachmentOptions extends GenericModel {
    
      /**
       * The status of an attachment evaluation.
       */

      Similar blocks of code found in 2 locations. Consider refactoring.
      Open

          try {
            System.out.println("listControlLibraries() result:");
            // begin-list_control_libraries
            ListControlLibrariesOptions listControlLibrariesOptions = new ListControlLibrariesOptions.Builder()
              .xCorrelationId("testString")
      examples/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/SecurityAndComplianceCenterApiExamples.java on lines 816..838

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 136.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 2 locations. Consider refactoring.
      Open

          try {
            System.out.println("listProfiles() result:");
            // begin-list_profiles
            ListProfilesOptions listProfilesOptions = new ListProfilesOptions.Builder()
              .xCorrelationId("testString")
      examples/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/SecurityAndComplianceCenterApiExamples.java on lines 683..705

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 136.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 2 locations. Consider refactoring.
      Open

      /*
       * (C) Copyright IBM Corp. 2023.
       *
       * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
       * the License. You may obtain a copy of the License at
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/ComplianceStats.java on lines 1..117

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 130.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 2 locations. Consider refactoring.
      Open

      /*
       * (C) Copyright IBM Corp. 2023.
       *
       * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
       * the License. You may obtain a copy of the License at
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/EvalStats.java on lines 1..117

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 130.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 2 locations. Consider refactoring.
      Open

      /*
       * (C) Copyright IBM Corp. 2023.
       *
       * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
       * the License. You may obtain a copy of the License at
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/UpdateProviderTypeInstanceRequestProviderTypeInstancePrototypeForPatchingAttributes.java on lines 1..91

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 129.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 2 locations. Consider refactoring.
      Open

      /*
       * (C) Copyright IBM Corp. 2023.
       *
       * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
       * the License. You may obtain a copy of the License at
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/UpdateProviderTypeInstanceRequestProviderTypeInstancePrototypeForPatchingName.java on lines 1..89

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 129.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 3 locations. Consider refactoring.
      Open

          private Builder(CreateCustomControlLibraryOptions createCustomControlLibraryOptions) {
            this.controlLibraryName = createCustomControlLibraryOptions.controlLibraryName;
            this.controlLibraryDescription = createCustomControlLibraryOptions.controlLibraryDescription;
            this.controlLibraryType = createCustomControlLibraryOptions.controlLibraryType;
            this.controls = createCustomControlLibraryOptions.controls;
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/ControlsInControlLib.java on lines 76..87
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/ReplaceRuleOptions.java on lines 56..67

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 126.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 3 locations. Consider refactoring.
      Open

          private Builder(ControlsInControlLib controlsInControlLib) {
            this.controlName = controlsInControlLib.controlName;
            this.controlId = controlsInControlLib.controlId;
            this.controlDescription = controlsInControlLib.controlDescription;
            this.controlCategory = controlsInControlLib.controlCategory;
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/CreateCustomControlLibraryOptions.java on lines 66..77
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/ReplaceRuleOptions.java on lines 56..67

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 126.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 3 locations. Consider refactoring.
      Open

          private Builder(ReplaceRuleOptions replaceRuleOptions) {
            this.ruleId = replaceRuleOptions.ruleId;
            this.ifMatch = replaceRuleOptions.ifMatch;
            this.description = replaceRuleOptions.description;
            this.target = replaceRuleOptions.target;
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/ControlsInControlLib.java on lines 76..87
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/CreateCustomControlLibraryOptions.java on lines 66..77

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 126.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 3 locations. Consider refactoring.
      Open

        public static class Builder {
          private String id;
          private String status;
          private Date time;
      
      
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/AdditionalTargetAttribute.java on lines 81..144
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetLatestReportsOptions.java on lines 29..92

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 124.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 3 locations. Consider refactoring.
      Open

        public static class Builder {
          private String name;
          private String operator;
          private String value;
      
      
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/GetLatestReportsOptions.java on lines 29..92
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/LastScan.java on lines 41..104

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 124.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Similar blocks of code found in 3 locations. Consider refactoring.
      Open

        public static class Builder {
          private String xCorrelationId;
          private String xRequestId;
          private String sort;
      
      
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/AdditionalTargetAttribute.java on lines 81..144
      modules/security-and-compliance-center-api/src/main/java/com/ibm/cloud/security_and_compliance_center_api/v3/model/LastScan.java on lines 41..104

      Duplicated Code

      Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

      Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

      When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

      Tuning

      This issue has a mass of 124.

      We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

      The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

      If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

      See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

      Refactorings

      Further Reading

      Method listReportEvaluations has 46 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

        public ServiceCall<EvaluationPage> listReportEvaluations(ListReportEvaluationsOptions listReportEvaluationsOptions) {
          com.ibm.cloud.sdk.core.util.Validator.notNull(listReportEvaluationsOptions,
            "listReportEvaluationsOptions cannot be null");
          Map<String, String> pathParamsMap = new HashMap<String, String>();
          pathParamsMap.put("report_id", listReportEvaluationsOptions.reportId());
        Severity
        Category
        Status
        Source
        Language