projects
/
Sone.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove unused classes
[Sone.git]
/
src
/
main
/
java
/
net
/
pterodactylus
/
sone
/
data
/
impl
/
SoneImpl.java
diff --git
a/src/main/java/net/pterodactylus/sone/data/impl/SoneImpl.java
b/src/main/java/net/pterodactylus/sone/data/impl/SoneImpl.java
index
0494607
..
ce0f5c1
100644
(file)
--- a/
src/main/java/net/pterodactylus/sone/data/impl/SoneImpl.java
+++ b/
src/main/java/net/pterodactylus/sone/data/impl/SoneImpl.java
@@
-1,5
+1,5
@@
/*
/*
- * Sone - SoneImpl.java - Copyright © 2010–201
6
David Roden
+ * Sone - SoneImpl.java - Copyright © 2010–201
9
David Roden
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@@
-56,8
+56,6
@@
import com.google.common.hash.Hashing;
* {@link Sone} implementation.
* <p/>
* Operations that modify the Sone need to synchronize on the Sone in question.
* {@link Sone} implementation.
* <p/>
* Operations that modify the Sone need to synchronize on the Sone in question.
- *
- * @author <a href="mailto:bombe@pterodactylus.net">David ‘Bombe’ Roden</a>
*/
public class SoneImpl implements Sone {
*/
public class SoneImpl implements Sone {
@@
-95,16
+93,16
@@
public class SoneImpl implements Sone {
private volatile boolean known;
/** All posts. */
private volatile boolean known;
/** All posts. */
- private final Set<Post> posts = new CopyOnWriteArraySet<
Post
>();
+ private final Set<Post> posts = new CopyOnWriteArraySet<>();
/** All replies. */
/** All replies. */
- private final Set<PostReply> replies = new CopyOnWriteArraySet<
PostReply
>();
+ private final Set<PostReply> replies = new CopyOnWriteArraySet<>();
/** The IDs of all liked posts. */
/** The IDs of all liked posts. */
- private final Set<String> likedPostIds = new CopyOnWriteArraySet<
String
>();
+ private final Set<String> likedPostIds = new CopyOnWriteArraySet<>();
/** The IDs of all liked replies. */
/** The IDs of all liked replies. */
- private final Set<String> likedReplyIds = new CopyOnWriteArraySet<
String
>();
+ private final Set<String> likedReplyIds = new CopyOnWriteArraySet<>();
/** The root album containing all albums. */
private final Album rootAlbum = new AlbumImpl(this);
/** The root album containing all albums. */
private final Album rootAlbum = new AlbumImpl(this);
@@
-383,7
+381,7
@@
public class SoneImpl implements Sone {
public List<Post> getPosts() {
List<Post> sortedPosts;
synchronized (this) {
public List<Post> getPosts() {
List<Post> sortedPosts;
synchronized (this) {
- sortedPosts = new ArrayList<
Post
>(posts);
+ sortedPosts = new ArrayList<>(posts);
}
Collections.sort(sortedPosts, Post.NEWEST_FIRST);
return sortedPosts;
}
Collections.sort(sortedPosts, Post.NEWEST_FIRST);
return sortedPosts;
@@
-644,7
+642,7
@@
public class SoneImpl implements Sone {
}
hash.putString(")");
}
hash.putString(")");
- List<PostReply> replies = new ArrayList<
PostReply
>(getReplies());
+ List<PostReply> replies = new ArrayList<>(getReplies());
Collections.sort(replies, Reply.TIME_COMPARATOR);
hash.putString("Replies(");
for (PostReply reply : replies) {
Collections.sort(replies, Reply.TIME_COMPARATOR);
hash.putString("Replies(");
for (PostReply reply : replies) {
@@
-652,7
+650,7
@@
public class SoneImpl implements Sone {
}
hash.putString(")");
}
hash.putString(")");
- List<String> likedPostIds = new ArrayList<
String
>(getLikedPostIds());
+ List<String> likedPostIds = new ArrayList<>(getLikedPostIds());
Collections.sort(likedPostIds);
hash.putString("LikedPosts(");
for (String likedPostId : likedPostIds) {
Collections.sort(likedPostIds);
hash.putString("LikedPosts(");
for (String likedPostId : likedPostIds) {
@@
-660,7
+658,7
@@
public class SoneImpl implements Sone {
}
hash.putString(")");
}
hash.putString(")");
- List<String> likedReplyIds = new ArrayList<
String
>(getLikedReplyIds());
+ List<String> likedReplyIds = new ArrayList<>(getLikedReplyIds());
Collections.sort(likedReplyIds);
hash.putString("LikedReplies(");
for (String likedReplyId : likedReplyIds) {
Collections.sort(likedReplyIds);
hash.putString("LikedReplies(");
for (String likedReplyId : likedReplyIds) {