Merge "Temporarily skip rollback test"
[lhc/web/wiklou.git] / includes / user / UserIdentity.php
index 57a0408..64c61fe 100644 (file)
@@ -45,7 +45,29 @@ interface UserIdentity {
         */
        public function getName();
 
-       // TODO: in the future, we should also provide access to the actor ID here.
+       /**
+        * @since 1.31
+        *
+        * @return int The user's actor ID. May be 0 if no actor ID is set.
+        */
+       public function getActorId();
+
        // TODO: we may want to (optionally?) provide a global ID, see CentralIdLookup.
 
+       /**
+        * @since 1.32
+        *
+        * @param UserIdentity $user
+        * @return bool
+        */
+       public function equals( UserIdentity $user );
+
+       /**
+        * @since 1.34
+        *
+        * @return bool True if user is registered on this wiki, i.e., has a user ID. False if user is
+        *   anonymous or has no local account (which can happen when importing). This must be
+        *   equivalent to getId() != 0 and is provided for code readability.
+        */
+       public function isRegistered();
 }