Package org.intermine.web.logic.profile
Class ProfileMergeIssues
- java.lang.Object
-
- org.intermine.web.logic.profile.ProfileMergeIssues
-
public class ProfileMergeIssues extends java.lang.Object
The problems that arose when merging two profiles.- Author:
- Alex Kalderimis
-
-
Constructor Summary
Constructors Constructor Description ProfileMergeIssues()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addFailedTemplate(java.lang.String oldName, java.lang.String newName)
Record that a template failed.void
addRenamedBag(java.lang.String oldName, java.lang.String newName)
Record that a bag was renamed.ProfileMergeIssues
combineWith(ProfileMergeIssues that)
Combine this set of merge issues with another set.java.util.Map<java.lang.String,java.lang.String>
getRenamedBags()
Get the mapping from old to new names.java.util.Map<java.lang.String,java.lang.String>
getRenamedTemplates()
Get the names of all the templates that failed.boolean
hasIssues()
-
-
-
Method Detail
-
addFailedTemplate
public void addFailedTemplate(java.lang.String oldName, java.lang.String newName)
Record that a template failed.- Parameters:
oldName
- the old (invalid) namenewName
- the new (valid) name.
-
getRenamedTemplates
public java.util.Map<java.lang.String,java.lang.String> getRenamedTemplates()
Get the names of all the templates that failed.- Returns:
- The names of the failed templates (unmodifiable, never null, might be empty).
-
addRenamedBag
public void addRenamedBag(java.lang.String oldName, java.lang.String newName)
Record that a bag was renamed.- Parameters:
oldName
- The old name for this bag.newName
- The name it now has.
-
getRenamedBags
public java.util.Map<java.lang.String,java.lang.String> getRenamedBags()
Get the mapping from old to new names.- Returns:
- The mapping (unmodifiable, never null, might be empty).
-
combineWith
public ProfileMergeIssues combineWith(ProfileMergeIssues that)
Combine this set of merge issues with another set.- Parameters:
that
- The other merge issues- Returns:
- A combined set of merge issues.
-
hasIssues
public boolean hasIssues()
- Returns:
- whether there are any issues.
-
-