-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Created the ImpactTree class, that contains the impact tree itself and metadata about it.
- Loading branch information
Showing
4 changed files
with
48 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
37 changes: 37 additions & 0 deletions
37
src/main/java/com/jfrog/ide/common/nodes/subentities/ImpactTree.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
package com.jfrog.ide.common.nodes.subentities; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
|
||
public class ImpactTree { | ||
@JsonProperty | ||
private ImpactTreeNode root; | ||
@JsonProperty | ||
private int impactPathsCount = 0; | ||
|
||
// Empty constructor for deserialization | ||
@SuppressWarnings("unused") | ||
public ImpactTree() { | ||
} | ||
|
||
public ImpactTree(ImpactTreeNode root) { | ||
this.root = root; | ||
} | ||
|
||
public boolean contains(String name) { | ||
return root.contains(name); | ||
} | ||
|
||
public ImpactTreeNode getRoot() { | ||
return root; | ||
} | ||
|
||
@SuppressWarnings("unused") | ||
public int getImpactPathsCount() { | ||
return impactPathsCount; | ||
} | ||
|
||
@SuppressWarnings("unused") | ||
public void incImpactPathsCount() { | ||
this.impactPathsCount++; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters