hrntsm/STBDotNet

View on GitHub

Showing 8 of 8 total issues

Method Serialize has 36 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        public static bool Serialize(object stBridge, string outPath, Version stbVersion)
        {
            var namespaces = new XmlSerializerNamespaces();
            var serializer = new XmlSerializer(typeof(v140.ST_BRIDGE));
            try
Severity: Minor
Found in STBDotNet/Serialization/Serializer.cs - About 1 hr to fix

Method Serialize has 29 lines of code (exceeds 25 allowed). Consider refactoring.
Open

        public static bool Serialize(object stBridge, string outPath)
        {
            var namespaces = new XmlSerializerNamespaces();
            var serializer = new XmlSerializer(typeof(v140.ST_BRIDGE));
            switch (stBridge)
Severity: Minor
Found in STBDotNet/Serialization/Serializer.cs - About 1 hr to fix

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

            public class RcStandard
            {
                [XmlAttribute("pos")] public string Position { get; set; }
                [XmlAttribute("strength")] public string Strength { get; set; }
                [XmlAttribute("D")] public string D { get; set; }
Severity: Major
Found in STBDotNet/v140/StbSlab.cs and 3 other locations - About 40 mins to fix
STBDotNet/v140/StbColumnS.cs on lines 22..28
STBDotNet/v140/StbSecBeamRc.cs on lines 81..87
STBDotNet/v140/StbSlab.cs on lines 119..125

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

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

        public class StbSecTaper
        {
            [XmlAttribute("width_start")] public double WidthStart { get; set; }
            [XmlAttribute("depth_start")] public double DepthStart { get; set; }
            [XmlAttribute("width_end")] public double WidthEnd { get; set; }
Severity: Major
Found in STBDotNet/v140/StbSecBeamRc.cs and 3 other locations - About 40 mins to fix
STBDotNet/v140/StbColumnS.cs on lines 22..28
STBDotNet/v140/StbSlab.cs on lines 56..62
STBDotNet/v140/StbSlab.cs on lines 119..125

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

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

    public class SecSteel
    {
        [XmlAttribute("pos")] public string Position { get; set; }
        [XmlAttribute("shape")] public string Shape { get; set; }
        [XmlAttribute("strength_main")] public string StrengthMain { get; set; }
Severity: Major
Found in STBDotNet/v140/StbColumnS.cs and 3 other locations - About 40 mins to fix
STBDotNet/v140/StbSecBeamRc.cs on lines 81..87
STBDotNet/v140/StbSlab.cs on lines 56..62
STBDotNet/v140/StbSlab.cs on lines 119..125

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

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

        public class SlabPrecastProduct
        {
            [XmlAttribute("product_company")] public string ProductCompany { get; set; }
            [XmlAttribute("product_name")] public string ProductName { get; set; }
            [XmlAttribute("product_code")] public string ProductCode { get; set; }
Severity: Major
Found in STBDotNet/v140/StbSlab.cs and 3 other locations - About 40 mins to fix
STBDotNet/v140/StbColumnS.cs on lines 22..28
STBDotNet/v140/StbSecBeamRc.cs on lines 81..87
STBDotNet/v140/StbSlab.cs on lines 56..62

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

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

    public class StbBrace : FrameBase, IFrameIdNode
    {
        [XmlAttribute("idNode_start")] public int IdNodeStart { get; set; }
        [XmlAttribute("idNode_end")] public int IdNodeEnd { get; set; }
        [XmlAttribute("future_brace")] public string FutureBrace { get; set; }
Severity: Minor
Found in STBDotNet/v140/StbMembers.cs and 1 other location - About 30 mins to fix
STBDotNet/v140/StbSection.cs on lines 11..16

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

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

    public class StbSecBeamSrc : StbSectionBase, ISecBeam
    {
        [XmlAttribute("kind_beam")] public string KindBeam { get; set; }
        [XmlAttribute("isCanti")] public string IsCanti { get; set; }
        [XmlAttribute("isOutIn")] public string IsOutIn { get; set; }
Severity: Minor
Found in STBDotNet/v140/StbSection.cs and 1 other location - About 30 mins to fix
STBDotNet/v140/StbMembers.cs on lines 117..122

Duplicated Code

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

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

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

Tuning

This issue has a mass of 61.

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

Severity
Category
Status
Source
Language