*
* 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
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.logging.Level;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.logging.Level;
import net.pterodactylus.sone.data.Post;
import net.pterodactylus.sone.data.PostReply;
import net.pterodactylus.sone.data.Profile;
import net.pterodactylus.sone.data.Post;
import net.pterodactylus.sone.data.PostReply;
import net.pterodactylus.sone.data.Profile;
import net.pterodactylus.sone.data.Sone.ShowCustomAvatars;
import net.pterodactylus.sone.data.Sone.SoneStatus;
import net.pterodactylus.sone.data.Sone.ShowCustomAvatars;
import net.pterodactylus.sone.data.Sone.SoneStatus;
import net.pterodactylus.sone.fcp.FcpInterface;
import net.pterodactylus.sone.fcp.FcpInterface.FullAccessRequired;
import net.pterodactylus.sone.freenet.wot.Identity;
import net.pterodactylus.sone.fcp.FcpInterface;
import net.pterodactylus.sone.fcp.FcpInterface.FullAccessRequired;
import net.pterodactylus.sone.freenet.wot.Identity;
- private Map<OwnIdentity, Set<Identity>> trustedIdentities = Collections.synchronizedMap(new HashMap<OwnIdentity, Set<Identity>>());
+ private final Map<OwnIdentity, Set<Identity>> trustedIdentities = Collections.synchronizedMap(new HashMap<OwnIdentity, Set<Identity>>());
List<Post> storedPosts = storedSone.getPosts();
synchronized (knownPosts) {
for (Post post : sone.getPosts()) {
List<Post> storedPosts = storedSone.getPosts();
synchronized (knownPosts) {
for (Post post : sone.getPosts()) {
Set<PostReply> storedReplies = storedSone.getReplies();
synchronized (knownReplies) {
for (PostReply reply : sone.getReplies()) {
Set<PostReply> storedReplies = storedSone.getReplies();
synchronized (knownReplies) {
for (PostReply reply : sone.getReplies()) {
- * Marks the given Sone as known. If the Sone was {@link #isNewPost(String)
- * new} before, a {@link CoreListener#markSoneKnown(Sone)} event is fired.
+ * Marks the given Sone as known. If the Sone was not {@link Post#isKnown()
+ * known} before, a {@link CoreListener#markSoneKnown(Sone)} event is fired.
- * Marks the given post as known, if it is currently a new post (according
- * to {@link #isNewPost(String)}).
+ * Marks the given post as known, if it is currently not a known post
+ * (according to {@link Post#isKnown()}).
- * Marks the given reply as known, if it is currently a new reply (according
- * to {@link #isNewReply(String)}).
+ * Marks the given reply as known, if it is currently not a known reply
+ * (according to {@link Reply#isKnown()}).