import static net.pterodactylus.sone.data.Album.IMAGES;
import java.util.Collection;
+import java.util.Collections;
import java.util.Comparator;
import java.util.List;
import java.util.Set;
}
};
+ public static final Function<Sone, List<Post>> TO_POSTS = new Function<Sone, List<Post>>() {
+ @Override
+ public List<Post> apply(Sone sone) {
+ return (sone == null) ? Collections.<Post>emptyList() : sone.getPosts();
+ }
+ };
+
/**
* Returns the identity of this Sone.
*
Client getClient();
/**
- * Sets the client used by this Sone.
- *
- * @param client
- * The client used by this Sone, or {@code null}
- * @return This Sone (for method chaining)
- */
- Sone setClient(Client client);
-
- /**
* Returns whether this Sone is known.
*
* @return {@code true} if this Sone is known, {@code false} otherwise