added tags to plugin informations

This commit is contained in:
Sebastian Sdorra
2014-10-10 20:43:21 +02:00
parent f9fab87480
commit 8b0fa62ceb
4 changed files with 47 additions and 1 deletions

View File

@@ -83,6 +83,7 @@ public class PluginInformation implements Validateable, Cloneable, Serializable
clone.setArtifactId(artifactId);
clone.setAuthor(author);
clone.setCategory(category);
clone.setTags(tags);
if (condition != null)
{
@@ -133,6 +134,7 @@ public class PluginInformation implements Validateable, Cloneable, Serializable
return Objects.equal(artifactId, other.artifactId)
&& Objects.equal(author, other.author)
&& Objects.equal(category, other.category)
&& Objects.equal(tags, other.tags)
&& Objects.equal(condition, other.condition)
&& Objects.equal(description, other.description)
&& Objects.equal(groupId, other.groupId)
@@ -154,7 +156,7 @@ public class PluginInformation implements Validateable, Cloneable, Serializable
@Override
public int hashCode()
{
return Objects.hashCode(artifactId, author, category, condition,
return Objects.hashCode(artifactId, author, category, tags, condition,
description, groupId, name, screenshots, state, url, version, wiki);
}
@@ -172,6 +174,7 @@ public class PluginInformation implements Validateable, Cloneable, Serializable
.add("artifactId", artifactId)
.add("author", author)
.add("category", category)
.add("tags", tags)
.add("condition", condition)
.add("description", description)
.add("groupId", groupId)
@@ -320,6 +323,17 @@ public class PluginInformation implements Validateable, Cloneable, Serializable
return state;
}
/**
* Method description
*
*
* @return
*/
public List<String> getTags()
{
return tags;
}
/**
* Method description
*
@@ -467,6 +481,17 @@ public class PluginInformation implements Validateable, Cloneable, Serializable
this.state = state;
}
/**
* Method description
*
*
* @param tags
*/
public void setTags(List<String> tags)
{
this.tags = tags;
}
/**
* Method description
*
@@ -531,6 +556,11 @@ public class PluginInformation implements Validateable, Cloneable, Serializable
/** Field description */
private PluginState state;
/** Field description */
@XmlElement(name = "tag")
@XmlElementWrapper(name = "tags")
private List<String> tags;
/** Field description */
private String url;

View File

@@ -47,6 +47,11 @@
<information>
<author>Sebastian Sdorra</author>
<category>Git</category>
<tags>
<tag>git</tag>
<tag>scm</tag>
<tag>dvcs</tag>
</tags>
</information>
<conditions>

View File

@@ -47,6 +47,12 @@
<information>
<author>Sebastian Sdorra</author>
<category>Mercurial</category>
<tags>
<tag>mercurial</tag>
<tag>hg</tag>
<tag>scm</tag>
<tag>dvcs</tag>
</tags>
</information>
<conditions>

View File

@@ -47,6 +47,11 @@
<information>
<author>Sebastian Sdorra</author>
<category>Subversion</category>
<tags>
<tag>subversion</tag>
<tag>scm</tag>
<tag>svn</tag>
</tags>
</information>
<conditions>