Showing 33 of 33 total issues
Method InitializeComponent
has 252 lines of code (exceeds 25 allowed). Consider refactoring. Open
private void InitializeComponent()
{
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ImpRecGUI));
this.txtInput = new System.Windows.Forms.TextBox();
this.btnImpact = new System.Windows.Forms.Button();
Similar blocks of code found in 2 locations. Consider refactoring. Open
{
if (relevant)
{
tmpString = tmpString.Insert(tmpString.Length, "<RelevantTC");
tmpString = tmpString.Insert(tmpString.Length, " timeStamp=\"" + timeStamp + "\"");
- Read upRead up
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 311.
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
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
{
if (relevant)
{
tmpString = tmpString.Insert(tmpString.Length, "<RelevantII");
tmpString = tmpString.Insert(tmpString.Length, " timeStamp=\"" + timeStamp + "\"");
- Read upRead up
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 311.
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
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
File KnowlParser.cs
has 348 lines of code (exceeds 250 allowed). Consider refactoring. Open
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text;
Method txtImpact_Click
has 102 lines of code (exceeds 25 allowed). Consider refactoring. Open
private void txtImpact_Click(object sender, EventArgs e)
{
// Remove help text
lstRelated.Visible = true;
lstImpacted.Visible = true;
File SessionInfo.cs
has 328 lines of code (exceeds 250 allowed). Consider refactoring. Open
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
Method StartTextElement
has 96 lines of code (exceeds 25 allowed). Consider refactoring. Open
private void StartTextElement(string strText)
{
if (nodeMode == 1) // Tracker case
{
if (currentTrackerCase == null)
File ImpRecGUI.cs
has 310 lines of code (exceeds 250 allowed). Consider refactoring. Open
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
Similar blocks of code found in 2 locations. Consider refactoring. Open
public void GetObjectData(SerializationInfo info, StreamingContext ctxt)
{
info.AddValue("TextWriter", this.textWriter);
info.AddValue("XmlWriter", this.xmlWriter);
info.AddValue("GraphMLWriter", this.graphMLWriter);
- Read upRead up
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 222.
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
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
public override void GetObjectData(SerializationInfo info, StreamingContext ctxt)
{
info.AddValue("Title", this.title);
info.AddValue("Description", this.description);
info.AddValue("IAReport", this.IAReport);
- Read upRead up
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 222.
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
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
File ImpRecGUI.Designer.cs
has 299 lines of code (exceeds 250 allowed). Consider refactoring. Open
namespace ImpRec
{
partial class ImpRecGUI
{
/// <summary>
Method StartElement
has 56 lines of code (exceeds 25 allowed). Consider refactoring. Open
private void StartElement(string strURI, string strName, string strName_2, Hashtable attributes)
{
if (strName == "TrackerCase")
{
nodeMode = 1;
Method ToString
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
public override String ToString()
{
StringBuilder tmpString = new StringBuilder();
if (feedbackType == 1)
{
Method FindImpact
has 44 lines of code (exceeds 25 allowed). Consider refactoring. Open
public LinkedList<ImpactItem> FindImpact(LinkedList<ImpactItem> impactList, double level, double startSimilarity)
{
if (Visited)
{
return impactList;
Method ParseImpactAnalyses
has 41 lines of code (exceeds 25 allowed). Consider refactoring. Open
public void ParseImpactAnalyses()
{
string line;
// Read the file line by line
Method ParseSemNet
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
public void ParseSemNet()
{
try
{
XDocument doc = XDocument.Parse(ImpRec.Properties.Resources.semanticNetwork);
Method ParseIssueText
has 40 lines of code (exceeds 25 allowed). Consider refactoring. Open
public void ParseIssueText()
{
int lineType = 1; // 1 = id, 2 = title, 3 = desc, 4 = blank
string line;
TrackerCase tmpCase = null;
Method GetAllLinks
has 39 lines of code (exceeds 25 allowed). Consider refactoring. Open
public LinkedList<ImpactItem> GetAllLinks()
{
LinkedList<ImpactItem> mergedList = new LinkedList<ImpactItem>();
foreach (ImpactItem ii in needsUpdateLinks)
Similar blocks of code found in 2 locations. Consider refactoring. Open
public void IISelected(string artifactID, int pos, double sim)
{
TextWriter writer;
if (!File.Exists(FILENAME))
{
- Read upRead up
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 116.
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
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76
Similar blocks of code found in 2 locations. Consider refactoring. Open
public void TCSelected(string artifactID, int pos, double sim)
{
TextWriter writer;
if (!File.Exists(FILENAME))
{
- Read upRead up
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 116.
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
- Extract Method
- Extract Class
- Form Template Method
- Introduce Null Object
- Pull Up Method
- Pull Up Field
- Substitute Algorithm
Further Reading
- Don't Repeat Yourself on the C2 Wiki
- Duplicated Code on SourceMaking
- Refactoring: Improving the Design of Existing Code by Martin Fowler. Duplicated Code, p76