FrenchYeti/dexcalibur

View on GitHub
src/AndroidAppComponents.js

Summary

Maintainability
F
1 mo
Test Coverage

File AndroidAppComponents.js has 1529 lines of code (exceeds 250 allowed). Consider refactoring.
Open

const Logger = require('./Logger.js')();
const _md5_ = require('md5');

const ANDROID_PREFIX = "android:";
const ANDROID_PREFIX_LEN = 8;
Severity: Major
Found in src/AndroidAppComponents.js - About 4 days to fix

    Function fromXml has a Cognitive Complexity of 25 (exceeds 5 allowed). Consider refactoring.
    Open

        static fromXml(xmlobj){
            let app = new AndroidApplication();
    
            for(let i in xmlobj.$){
                if(i.startsWith('android:')){
    Severity: Minor
    Found in src/AndroidAppComponents.js - About 3 hrs to fix

    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 toXml has 88 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

        toXml(){
            let o = new Object();
    
            o.$ = {};
            for(let i in this.attributes){
    Severity: Major
    Found in src/AndroidAppComponents.js - About 3 hrs to fix

      Function fromXml has 87 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

          static fromXml(config, context){
              let self = new AndroidManifest();
              // init manifest attributes 
              for(let i in config){
                  switch(i){
      Severity: Major
      Found in src/AndroidAppComponents.js - About 3 hrs to fix

        Function fromXml has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring.
        Open

            static fromXml(config, context){
                let self = new AndroidManifest();
                // init manifest attributes 
                for(let i in config){
                    switch(i){
        Severity: Minor
        Found in src/AndroidAppComponents.js - About 2 hrs to fix

        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

        AndroidActivity has 23 functions (exceeds 20 allowed). Consider refactoring.
        Open

        class AndroidActivity
        {
            static MODEL = {
                allowEmbedded:["true" , "false"],
                allowTaskReparenting:["true" , "false"],
        Severity: Minor
        Found in src/AndroidAppComponents.js - About 2 hrs to fix

          Function toXml has a Cognitive Complexity of 17 (exceeds 5 allowed). Consider refactoring.
          Open

              toXml(){
                  let o = new Object();
          
                  o.$ = {};
                  for(let i in this.attributes){
          Severity: Minor
          Found in src/AndroidAppComponents.js - About 2 hrs to fix

          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 fromXml has 43 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

              static fromXml(xmlobj){
                  let app = new AndroidApplication();
          
                  for(let i in xmlobj.$){
                      if(i.startsWith('android:')){
          Severity: Minor
          Found in src/AndroidAppComponents.js - About 1 hr to fix

            Function fromXml has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let intf = new IntentFilter();
            
                    if(xmlobj.action != null && xmlobj.action instanceof Array){
                        for(let i=0; i<xmlobj.action.length; i++){
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 1 hr to fix

            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 constructor has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
            Open

                constructor(config=null){
                    this.description = null;
                    this.label = null;
                    this.name = null;
            
            
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 55 mins to fix

            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 fromXml has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let act = new AndroidReceiver();
            
                    for(let j in xmlobj){
                        switch(j){
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 55 mins to fix

            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 fromXml has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let act = new AndroidActivity();
            
                    for(let j in xmlobj){
                        switch(j){
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 55 mins to fix

            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 fromXml has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let act = new AndroidProvider();
            
                    for(let j in xmlobj){
                        switch(j){
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 55 mins to fix

            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 fromXml has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let act = new AndroidService();
            
                    for(let j in xmlobj){
                        switch(j){
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 55 mins to fix

            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 constructor has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
            Open

                constructor(config=null){
                    // the manifest data are stored here
            
                    this.attr = {};
            
            
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 45 mins to fix

            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 constructor has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
            Open

                constructor(config=null){
                    // the manifest data are stored here
            
                    this.attr = {};
            
            
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 45 mins to fix

            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 constructor has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
            Open

                constructor(config=null){
                    // the manifest data are stored here
            
                    this.attr = {};
            
            
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 45 mins to fix

            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 constructor has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring.
            Open

                constructor(config=null){
                    // the manifest data are stored here
            
                    this.attr = {};
            
            
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 45 mins to fix

            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 setAttributes has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
            Open

                setAttributes(attr){
                    let n="";
                    for(let i in attr){
                        if(i.startsWith(ANDROID_PREFIX)){
                            n = i.substr(ANDROID_PREFIX_LEN);
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 35 mins to fix

            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 toJsonObject has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
            Open

                toJsonObject(){
                    let o = new Object();
            
                    o.name = this.name;
                    o.label = this.label;
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 35 mins to fix

            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 setAttributes has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
            Open

                setAttributes(attr){
                    let n="";
                    for(let i in attr){
                        if(i.startsWith(ANDROID_PREFIX)){
                            n = i.substr(ANDROID_PREFIX_LEN);
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 35 mins to fix

            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 setAttributes has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring.
            Open

                setAttributes(attr){
                    let n="";
                    for(let i in attr){
                        if(i.startsWith(ANDROID_PREFIX)){
                            n = i.substr(ANDROID_PREFIX_LEN);
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 35 mins to fix

            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 constructor has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
            Open

                constructor(config=null){
            
                    this.attr = {};
            
            
            
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 25 mins to fix

            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 constructor has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
            Open

                constructor(config=null){
                    this.icon = null;
                    this.label = null;
                    this.name = null;
            
            
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 25 mins to fix

            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 constructor has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring.
            Open

                constructor(config=null){
                    this.enabled=null;
                    this.exported=null;
                    this.icon=null;
                    this.label=null;
            Severity: Minor
            Found in src/AndroidAppComponents.js - About 25 mins to fix

            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

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

            class AndroidReceiver
            {
                
                constructor(config=null){
                    // the manifest data are stored here
            Severity: Major
            Found in src/AndroidAppComponents.js and 1 other location - About 6 days to fix
            src/AndroidAppComponents.js on lines 1014..1189

            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 1143.

            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

            class AndroidService
            {
                
                constructor(config=null){
                    // the manifest data are stored here
            Severity: Major
            Found in src/AndroidAppComponents.js and 1 other location - About 6 days to fix
            src/AndroidAppComponents.js on lines 1191..1362

            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 1143.

            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

                setAttributes(attr){
                    let n="";
                    for(let i in attr){
                        if(i.startsWith(ANDROID_PREFIX)){
                            n = i.substr(ANDROID_PREFIX_LEN);
            Severity: Major
            Found in src/AndroidAppComponents.js and 2 other locations - About 4 hrs to fix
            src/AndroidAppComponents.js on lines 23..35
            src/AndroidAppComponents.js on lines 860..872

            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 138.

            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

                setAttributes(attr){
                    let n="";
                    for(let i in attr){
                        if(i.startsWith(ANDROID_PREFIX)){
                            n = i.substr(ANDROID_PREFIX_LEN);
            Severity: Major
            Found in src/AndroidAppComponents.js and 2 other locations - About 4 hrs to fix
            src/AndroidAppComponents.js on lines 23..35
            src/AndroidAppComponents.js on lines 92..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 138.

            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

                setAttributes(attr){
                    let n="";
                    for(let i in attr){
                        if(i.startsWith(ANDROID_PREFIX)){
                            n = i.substr(ANDROID_PREFIX_LEN);
            Severity: Major
            Found in src/AndroidAppComponents.js and 2 other locations - About 4 hrs to fix
            src/AndroidAppComponents.js on lines 92..104
            src/AndroidAppComponents.js on lines 860..872

            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 138.

            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

                toXmlObject(){
                    let o = {};
            
                    o.$ = {};
                    for(let i in this.attr){
            Severity: Major
            Found in src/AndroidAppComponents.js and 1 other location - About 3 hrs to fix
            src/AndroidAppComponents.js on lines 123..135

            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 121.

            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

                toXmlObject(){
                    let o = {};
            
                    o.$ = {};
                    for(let i in this.attr){
            Severity: Major
            Found in src/AndroidAppComponents.js and 1 other location - About 3 hrs to fix
            src/AndroidAppComponents.js on lines 54..66

            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 121.

            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

                    if(xmlobj.action != null && xmlobj.action instanceof Array){
                        for(let i=0; i<xmlobj.action.length; i++){
                            intf.action.push(IntentActionCriteria.fromXml(xmlobj.action[i].$));
                        }
                    }
            Severity: Major
            Found in src/AndroidAppComponents.js and 2 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 264..268
            src/AndroidAppComponents.js on lines 271..275

            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 93.

            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

                    if(xmlobj.category != null && xmlobj.category instanceof Array){
                        for(let i=0; i<xmlobj.category.length; i++){
                            intf.category.push(IntentCategoryCriteria.fromXml(xmlobj.category[i].$));
                        }
                    }
            Severity: Major
            Found in src/AndroidAppComponents.js and 2 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 257..261
            src/AndroidAppComponents.js on lines 271..275

            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 93.

            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

                    if(xmlobj.data != null && xmlobj.data instanceof Array){
                        for(let i=0; i<xmlobj.data.length; i++){
                            intf.data.push(IntentDataCriteria.fromXml(xmlobj.data[i].$));
                        }
                    }
            Severity: Major
            Found in src/AndroidAppComponents.js and 2 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 257..261
            src/AndroidAppComponents.js on lines 264..268

            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 93.

            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 7 locations. Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let p = new AndroidSupportedScreen();
            
                    for(let i in xmlobj){
                        if(i.startsWith('android:')){
            Severity: Major
            Found in src/AndroidAppComponents.js and 6 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 174..186
            src/AndroidAppComponents.js on lines 319..331
            src/AndroidAppComponents.js on lines 355..367
            src/AndroidAppComponents.js on lines 438..450
            src/AndroidAppComponents.js on lines 503..515
            src/AndroidAppComponents.js on lines 539..551

            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 92.

            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 7 locations. Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let o = new IntentDataCriteria();
            
                    for(let i in xmlobj){
                        if(i.startsWith('android:')){
            Severity: Major
            Found in src/AndroidAppComponents.js and 6 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 319..331
            src/AndroidAppComponents.js on lines 355..367
            src/AndroidAppComponents.js on lines 438..450
            src/AndroidAppComponents.js on lines 479..491
            src/AndroidAppComponents.js on lines 503..515
            src/AndroidAppComponents.js on lines 539..551

            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 92.

            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 7 locations. Consider refactoring.
            Open

                  static fromXml(xmlobj){
                      let p = new AndroidConfiguration();
              
                      for(let i in xmlobj){
                          if(i.startsWith('android:')){
            Severity: Major
            Found in src/AndroidAppComponents.js and 6 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 174..186
            src/AndroidAppComponents.js on lines 319..331
            src/AndroidAppComponents.js on lines 355..367
            src/AndroidAppComponents.js on lines 438..450
            src/AndroidAppComponents.js on lines 479..491
            src/AndroidAppComponents.js on lines 503..515

            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 92.

            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 7 locations. Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let p = new AndroidScreen();
            
                    for(let i in xmlobj){
                        if(i.startsWith('android:')){
            Severity: Major
            Found in src/AndroidAppComponents.js and 6 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 174..186
            src/AndroidAppComponents.js on lines 319..331
            src/AndroidAppComponents.js on lines 355..367
            src/AndroidAppComponents.js on lines 438..450
            src/AndroidAppComponents.js on lines 479..491
            src/AndroidAppComponents.js on lines 539..551

            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 92.

            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 7 locations. Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let p = new AndroidFeature();
                    
                    for(let i in xmlobj){
                        if(i.startsWith('android:')){
            Severity: Major
            Found in src/AndroidAppComponents.js and 6 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 174..186
            src/AndroidAppComponents.js on lines 319..331
            src/AndroidAppComponents.js on lines 438..450
            src/AndroidAppComponents.js on lines 479..491
            src/AndroidAppComponents.js on lines 503..515
            src/AndroidAppComponents.js on lines 539..551

            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 92.

            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 7 locations. Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let p = new AndroidInstrumentation();
            
                    for(let i in xmlobj){
                        if(i.startsWith('android:')){
            Severity: Major
            Found in src/AndroidAppComponents.js and 6 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 174..186
            src/AndroidAppComponents.js on lines 319..331
            src/AndroidAppComponents.js on lines 355..367
            src/AndroidAppComponents.js on lines 479..491
            src/AndroidAppComponents.js on lines 503..515
            src/AndroidAppComponents.js on lines 539..551

            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 92.

            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 7 locations. Consider refactoring.
            Open

                static fromXml(xmlobj){
                    let o = new AndroidPermissionSdk23(); 
                    
                    for(let i in xmlobj){
                        if(i.startsWith('android:')){
            Severity: Major
            Found in src/AndroidAppComponents.js and 6 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 174..186
            src/AndroidAppComponents.js on lines 355..367
            src/AndroidAppComponents.js on lines 438..450
            src/AndroidAppComponents.js on lines 479..491
            src/AndroidAppComponents.js on lines 503..515
            src/AndroidAppComponents.js on lines 539..551

            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 92.

            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 8 locations. Consider refactoring.
            Open

                    if(this.instrumentation != null && this.instrumentation.length > 0){
                        o['instrumentation'] = [];
                        this.instrumentation.map(perm => {
                            o['instrumentation'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 7 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1824..1829
            src/AndroidAppComponents.js on lines 1831..1836
            src/AndroidAppComponents.js on lines 1838..1843
            src/AndroidAppComponents.js on lines 1850..1855
            src/AndroidAppComponents.js on lines 1856..1861
            src/AndroidAppComponents.js on lines 1862..1867
            src/AndroidAppComponents.js on lines 1868..1873

            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 86.

            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 8 locations. Consider refactoring.
            Open

                    if(this.usesPermissionsSdk23 != null && this.usesPermissionsSdk23.length > 0){
                        o['uses-permission-sdk-23'] = [];
                        this.usesPermissionsSdk23.map(perm => {
                            o['uses-permission-sdk-23'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 7 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1817..1822
            src/AndroidAppComponents.js on lines 1831..1836
            src/AndroidAppComponents.js on lines 1838..1843
            src/AndroidAppComponents.js on lines 1850..1855
            src/AndroidAppComponents.js on lines 1856..1861
            src/AndroidAppComponents.js on lines 1862..1867
            src/AndroidAppComponents.js on lines 1868..1873

            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 86.

            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 8 locations. Consider refactoring.
            Open

                    if(this.usesConfiguration != null && this.usesConfiguration.length > 0){
                        o['uses-configuration'] = [];
                        this.usesConfiguration.map(perm => {
                            o['uses-configuration'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 7 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1817..1822
            src/AndroidAppComponents.js on lines 1824..1829
            src/AndroidAppComponents.js on lines 1838..1843
            src/AndroidAppComponents.js on lines 1850..1855
            src/AndroidAppComponents.js on lines 1856..1861
            src/AndroidAppComponents.js on lines 1862..1867
            src/AndroidAppComponents.js on lines 1868..1873

            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 86.

            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 8 locations. Consider refactoring.
            Open

                    if(this.usesFeatures != null && this.usesFeatures.length > 0){
                        o['uses-feature'] = [];
                        this.usesFeatures.map(perm => {
                            o['uses-feature'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 7 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1817..1822
            src/AndroidAppComponents.js on lines 1824..1829
            src/AndroidAppComponents.js on lines 1831..1836
            src/AndroidAppComponents.js on lines 1838..1843
            src/AndroidAppComponents.js on lines 1850..1855
            src/AndroidAppComponents.js on lines 1856..1861
            src/AndroidAppComponents.js on lines 1862..1867

            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 86.

            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 8 locations. Consider refactoring.
            Open

                    if(this.supportsGlTextures != null && this.supportsGlTextures.length > 0){
                        o['supports-gl-texture'] = [];
                        this.supportsGlTextures.map(perm => {
                            o['supports-gl-texture'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 7 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1817..1822
            src/AndroidAppComponents.js on lines 1824..1829
            src/AndroidAppComponents.js on lines 1831..1836
            src/AndroidAppComponents.js on lines 1838..1843
            src/AndroidAppComponents.js on lines 1850..1855
            src/AndroidAppComponents.js on lines 1856..1861
            src/AndroidAppComponents.js on lines 1868..1873

            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 86.

            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 8 locations. Consider refactoring.
            Open

                    if(this.usesFeatures != null && this.usesFeatures.length > 0){
                        o['uses-feature'] = [];
                        this.usesFeatures.map(perm => {
                            o['uses-feature'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 7 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1817..1822
            src/AndroidAppComponents.js on lines 1824..1829
            src/AndroidAppComponents.js on lines 1831..1836
            src/AndroidAppComponents.js on lines 1850..1855
            src/AndroidAppComponents.js on lines 1856..1861
            src/AndroidAppComponents.js on lines 1862..1867
            src/AndroidAppComponents.js on lines 1868..1873

            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 86.

            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 8 locations. Consider refactoring.
            Open

                    if(this.compatibleScreens != null && this.compatibleScreens.length > 0){
                        o['compatible-screens'] = [];
                        this.compatibleScreens.map(perm => {
                            o['compatible-screens'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 7 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1817..1822
            src/AndroidAppComponents.js on lines 1824..1829
            src/AndroidAppComponents.js on lines 1831..1836
            src/AndroidAppComponents.js on lines 1838..1843
            src/AndroidAppComponents.js on lines 1850..1855
            src/AndroidAppComponents.js on lines 1862..1867
            src/AndroidAppComponents.js on lines 1868..1873

            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 86.

            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 8 locations. Consider refactoring.
            Open

                    if(this.supportsScreens != null && this.supportsScreens.length > 0){
                        o['supports-screens'] = [];
                        this.supportsScreens.map(perm => {
                            o['supports-screens'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 7 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1817..1822
            src/AndroidAppComponents.js on lines 1824..1829
            src/AndroidAppComponents.js on lines 1831..1836
            src/AndroidAppComponents.js on lines 1838..1843
            src/AndroidAppComponents.js on lines 1856..1861
            src/AndroidAppComponents.js on lines 1862..1867
            src/AndroidAppComponents.js on lines 1868..1873

            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 86.

            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

                static fromXml(xmlobj){
                    let p = new PermissionTree();
                    for(let i in xmlobj){
                        if(i.startsWith('android:'))
                            p[i.substr(8)] = xmlobj[i];
            Severity: Major
            Found in src/AndroidAppComponents.js and 1 other location - About 1 hr to fix
            src/AndroidAppComponents.js on lines 694..703

            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 86.

            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

                static fromXml(xmlobj){
                    let p = new PermissionGroup();
                    for(let i in xmlobj){
                        if(i.startsWith('android:'))
                            p[i.substr(8)] = xmlobj[i];
            Severity: Major
            Found in src/AndroidAppComponents.js and 1 other location - About 1 hr to fix
            src/AndroidAppComponents.js on lines 723..732

            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 86.

            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

                constructor(config=null){
                    this.functionalTest=null;
                    this.handleProfiling=null;
                    this.icon=null;
                    this.label=null;
            Severity: Major
            Found in src/AndroidAppComponents.js and 1 other location - About 1 hr to fix
            src/AndroidAppComponents.js on lines 163..171

            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 81.

            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

                constructor(){
                    this.scheme=null;
                    this.host=null;
                    this.port=null;
                    this.path=null;
            Severity: Major
            Found in src/AndroidAppComponents.js and 1 other location - About 1 hr to fix
            src/AndroidAppComponents.js on lines 428..436

            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 81.

            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 4 locations. Consider refactoring.
            Open

                            case 'instrumentation':
                                if(self.instrumentation===null) self.instrumentation = [];
            
                                config['instrumentation'].map(function(k){
                                    self.instrumentation.push(AndroidInstrumentation.fromXml(k.$));
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1731..1736
            src/AndroidAppComponents.js on lines 1737..1743
            src/AndroidAppComponents.js on lines 1744..1750

            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 77.

            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 4 locations. Consider refactoring.
            Open

                            case 'uses-configuration':
                                if(self.usesConfiguration===null) self.usesConfiguration = [];
            
                                config['uses-configuration'].map(function(k){
                                    self.usesConfiguration.push(AndroidConfiguration.fromXml(k.$));
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1731..1736
            src/AndroidAppComponents.js on lines 1744..1750
            src/AndroidAppComponents.js on lines 1751..1757

            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 77.

            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 4 locations. Consider refactoring.
            Open

                            case 'uses-permission-sdk-23':
                                if(self.usesPermissionsSdk23===null) self.usesPermissionsSdk23 = [];
            
                                config['uses-permission-sdk-23'].map(function(k){
                                    self.usesPermissionsSdk23.push(AndroidPermissionSdk23.fromXml(k.$));
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1731..1736
            src/AndroidAppComponents.js on lines 1737..1743
            src/AndroidAppComponents.js on lines 1751..1757

            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 77.

            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 4 locations. Consider refactoring.
            Open

                            case 'supports-screens':
                            if(self.supportsScreens===null) self.supportsScreens = [];
                                config['supports-screens'].map(function(k){
                                    self.supportsScreens.push(AndroidSupportedScreen.fromXml(k.$));
                                });
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 1 hr to fix
            src/AndroidAppComponents.js on lines 1737..1743
            src/AndroidAppComponents.js on lines 1744..1750
            src/AndroidAppComponents.js on lines 1751..1757

            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 77.

            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 4 locations. Consider refactoring.
            Open

                    if(this.permissionGroups.length > 0){
                        o['permission-group'] = [];
                        this.permissionGroups.map(perm => {
                            o['permission-group'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 55 mins to fix
            src/AndroidAppComponents.js on lines 1789..1794
            src/AndroidAppComponents.js on lines 1796..1801
            src/AndroidAppComponents.js on lines 1810..1815

            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 74.

            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 4 locations. Consider refactoring.
            Open

                    if(this.usesPermissions.length > 0){
                        o['uses-permission'] = [];
                        this.usesPermissions.map(perm => {
                            o['uses-permission'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 55 mins to fix
            src/AndroidAppComponents.js on lines 1796..1801
            src/AndroidAppComponents.js on lines 1803..1808
            src/AndroidAppComponents.js on lines 1810..1815

            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 74.

            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 4 locations. Consider refactoring.
            Open

                    if(this.permissions.length > 0){
                        o['permission'] = [];
                        this.permissions.map(perm => {
                            o['permission'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 55 mins to fix
            src/AndroidAppComponents.js on lines 1789..1794
            src/AndroidAppComponents.js on lines 1803..1808
            src/AndroidAppComponents.js on lines 1810..1815

            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 74.

            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 4 locations. Consider refactoring.
            Open

                    if(this.permissionTrees.length > 0){
                        o['permission-tree'] = [];
                        this.permissionTrees.map(perm => {
                            o['permission-tree'].push(perm.toXml());
                        });
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 55 mins to fix
            src/AndroidAppComponents.js on lines 1789..1794
            src/AndroidAppComponents.js on lines 1796..1801
            src/AndroidAppComponents.js on lines 1803..1808

            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 74.

            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 4 locations. Consider refactoring.
            Open

                            case 'activity':
                                for(let i=0; i<xmlobj.activity.length; i++){
                                    app.activities.push(AndroidActivity.fromXml(xmlobj.activity[i]));
                                }
                                break;
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 35 mins to fix
            src/AndroidAppComponents.js on lines 1619..1623
            src/AndroidAppComponents.js on lines 1624..1628
            src/AndroidAppComponents.js on lines 1629..1633

            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 67.

            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 4 locations. Consider refactoring.
            Open

                            case 'provider':
                                for(let i=0; i<xmlobj.provider.length; i++){
                                    app.providers.push(AndroidProvider.fromXml(xmlobj.provider[i]));
                                }
                                break;
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 35 mins to fix
            src/AndroidAppComponents.js on lines 1614..1618
            src/AndroidAppComponents.js on lines 1619..1623
            src/AndroidAppComponents.js on lines 1624..1628

            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 67.

            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 4 locations. Consider refactoring.
            Open

                            case 'receiver':
                                for(let i=0; i<xmlobj.receiver.length; i++){
                                    app.receivers.push(AndroidReceiver.fromXml(xmlobj.receiver[i]));
                                }
                                break;
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 35 mins to fix
            src/AndroidAppComponents.js on lines 1614..1618
            src/AndroidAppComponents.js on lines 1619..1623
            src/AndroidAppComponents.js on lines 1629..1633

            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 67.

            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 4 locations. Consider refactoring.
            Open

                            case 'service':
                                for(let i=0; i<xmlobj.service.length; i++){
                                    app.services.push(AndroidService.fromXml(xmlobj.service[i]));
                                }
                                break;
            Severity: Major
            Found in src/AndroidAppComponents.js and 3 other locations - About 35 mins to fix
            src/AndroidAppComponents.js on lines 1614..1618
            src/AndroidAppComponents.js on lines 1624..1628
            src/AndroidAppComponents.js on lines 1629..1633

            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 67.

            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

            There are no issues that match your filters.

            Category
            Status