Skip to content
Snippets Groups Projects
Commit 90ef5efd authored by Eike Cochu's avatar Eike Cochu
Browse files

replaced manual toString method with eclipse generated

parent 10140f3c
No related branches found
No related tags found
No related merge requests found
......@@ -60,4 +60,9 @@ public class Article implements Model<ObjectId>, Serializable {
return id.hashCode();
}
@Override
public String toString() {
return "Article [id=" + id + ", title=" + title + "]";
}
}
......@@ -6,6 +6,7 @@ import java.io.Serializable;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Date;
import java.util.List;
......@@ -217,12 +218,6 @@ public class ArticleFull extends FileModel<ObjectId> implements Serializable {
this.created = modified;
}
@Override
public String toString() {
return ArticleFull.class.getSimpleName() + "[id:" + id + ", title:" + title + ", url:" + url + ", date:" + date
+ ", created:" + created + ", modified:" + modified + "]";
}
@Override
public boolean equals(final Object o) {
if (o == null)
......@@ -242,4 +237,11 @@ public class ArticleFull extends FileModel<ObjectId> implements Serializable {
return id.hashCode();
}
@Override
public String toString() {
return "ArticleFull [id=" + id + ", title=" + title + ", text=" + text + ", processedText="
+ Arrays.toString(processedText) + ", url=" + url + ", date=" + date + ", topics=" + topics + ", stats="
+ stats + ", created=" + created + ", modified=" + modified + ", meta=" + meta + "]";
}
}
\ No newline at end of file
......@@ -48,8 +48,8 @@ public class ArticleStats implements Serializable {
@Override
public String toString() {
return ArticleStats.class.getSimpleName() + "[wordCount:" + wordCount + ", processedWordCount:"
+ processedWordCount + ", reductionRatio:" + reductionRatio + "]";
return "ArticleStats [wordCount=" + wordCount + ", uniqueWordCount=" + uniqueWordCount + ", processedWordCount="
+ processedWordCount + ", reductionRatio=" + reductionRatio + "]";
}
}
\ No newline at end of file
......@@ -46,4 +46,9 @@ public class Sequence implements Comparable<Sequence>, Serializable {
return this.number - o.getNumber();
}
@Override
public String toString() {
return "Sequence [date=" + date + ", number=" + number + ", words=" + words + "]";
}
}
......@@ -71,4 +71,9 @@ public class Topic implements Model<ObjectId>, Serializable {
return id.hashCode();
}
@Override
public String toString() {
return "Topic [id=" + id + ", name=" + name + "]";
}
}
......@@ -101,12 +101,6 @@ public class TopicFull implements Model<ObjectId>, Serializable {
this.modified = modified;
}
@Override
public String toString() {
return TopicFull.class.getSimpleName() + "[id:" + getId() + ", name:" + getName() + ", created:" + created
+ ", modified:" + modified + "]";
}
@PrePersist
public void prePersist() {
this.modified = new Date();
......@@ -146,4 +140,10 @@ public class TopicFull implements Model<ObjectId>, Serializable {
return id.hashCode();
}
@Override
public String toString() {
return "TopicFull [id=" + id + ", name=" + name + ", index=" + index + ", words=" + words + ", sequences="
+ sequences + ", created=" + created + ", modified=" + modified + "]";
}
}
......@@ -4,6 +4,7 @@ import java.io.Serializable;
import org.mongodb.morphia.annotations.Embedded;
import org.mongodb.morphia.annotations.Reference;
import org.mongodb.morphia.annotations.Transient;
@SuppressWarnings("serial")
@Embedded
......@@ -12,17 +13,10 @@ public class TopicRef implements Comparable<TopicRef>, Serializable {
@Reference(ignoreMissing = true)
private Topic topic;
private Integer count;
private Double share;
public Integer getCount() {
return count;
}
public void setCount(final Integer count) {
this.count = count;
}
@Transient
private Integer count;
public Topic getTopic() {
return topic;
......@@ -32,6 +26,14 @@ public class TopicRef implements Comparable<TopicRef>, Serializable {
this.topic = topic;
}
public Integer getCount() {
return count;
}
public void setCount(Integer count) {
this.count = count;
}
public Double getShare() {
return share;
}
......@@ -42,12 +44,12 @@ public class TopicRef implements Comparable<TopicRef>, Serializable {
@Override
public int compareTo(final TopicRef arg0) {
return count - arg0.getCount();
return (int) (share - arg0.getShare());
}
@Override
public String toString() {
return TopicRef.class.getSimpleName() + "[topic: " + topic + ", count:" + count + ", share:" + share + "]";
return "TopicRef [topic=" + topic + ", share=" + share + ", count=" + count + "]";
}
}
......@@ -64,7 +64,7 @@ public class TopicWord implements Comparable<TopicWord>, Serializable {
@Override
public String toString() {
return TopicWord.class.getSimpleName() + "[word:" + word + ", likeliness:" + likeliness + "]";
return "TopicWord [word=" + word + ", likeliness=" + likeliness + "]";
}
}
......@@ -99,4 +99,9 @@ public class Word implements Model<String>, Serializable {
return id.hashCode();
}
@Override
public String toString() {
return "Word [id=" + id + ", created=" + created + ", isCreated=" + isCreated + "]";
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment