Store locality of a Sone in the Sone itself, remove related methods from Database.
[Sone.git] / src / main / java / net / pterodactylus / sone / database / Database.java
index 7b48151..0ff7dfb 100644 (file)
@@ -29,62 +29,6 @@ import net.pterodactylus.sone.data.Sone;
 public interface Database {
 
        /**
-        * Returns whether the given Sone is a local Sone.
-        *
-        * @param sone
-        *            The Sone to check
-        * @return {@code true} if the given Sone is a local Sone, {@code false}
-        *         otherwise
-        * @throws IllegalArgumentException
-        *             if {@code sone} is {@code null}
-        * @throws DatabaseException
-        *             if a database error occurs
-        */
-       public boolean isLocalSone(Sone sone) throws DatabaseException;
-
-       /**
-        * Returns whether the given Sone ID belongs to a local Sone.
-        *
-        * @param id
-        *            The Sone ID to check
-        * @return {@code true} if the given Sone ID belongs to a local Sone,
-        *         {@code false} otherwise
-        * @throws IllegalArgumentException
-        *             if {@code id} is {@code null}
-        * @throws DatabaseException
-        *             if a database error occurs
-        */
-       public boolean isLocalSone(String id) throws DatabaseException;
-
-       /**
-        * Returns whether the given Sone is a remote Sone.
-        *
-        * @param sone
-        *            The Sone to check
-        * @return {@code true} if the given Sone is a remote Sone, {@code false}
-        *         otherwise
-        * @throws IllegalArgumentException
-        *             if {@code sone} is {@code null}
-        * @throws DatabaseException
-        *             if a database error occurs
-        */
-       public boolean isRemoteSone(Sone sone) throws DatabaseException;
-
-       /**
-        * Returns whether the given Sone ID belongs to a remote Sone.
-        *
-        * @param id
-        *            The Sone ID to check
-        * @return {@code true} if the given Sone ID belongs to a remote Sone,
-        *         {@code false} otherwise
-        * @throws IllegalArgumentException
-        *             if {@code id} is {@code null}
-        * @throws DatabaseException
-        *             if a database error occurs
-        */
-       public boolean isRemoteSone(String id) throws DatabaseException;
-
-       /**
         * Returns the Sone with the given ID, creating a new Sone if a Sone with
         * the given ID does not exist and {@code create} is {@code true}. When
         * searching for a Sone with the given IDs, local Sones are preferred.