Interface DefaultUserId

  • All Implemented Interfaces:

    
    public interface DefaultUserId
    
                        
    The UserId range in wings convention,
    a positive number is a login user,
    otherwise it is a non-login user.
    
    (1) Big positive numbers are business users;
        small positive numbers are built-in users;
        0-99 are reserved Wings users.
    (2) Negative numbers are special users.
    (3) Zero has no privileges, root has the highest privileges,
        it is recommended not to login.
    
    Since:

    2021-02-20

    Author:

    trydofor

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      static boolean isGuest(long uid) Whether is Guest (eq -1)
      static boolean asGuest(Long uid) Whether as Guest (null or le -1)
      static boolean isNull(long uid) Whether Null value
      static boolean asNull(Long uid) Whether null Object or Null value
      static long value(Long uid) trim value or Null
      static boolean isWings(long uid) Whether reserved Wings users.
      static boolean asWings(Long uid) Whether null or reserved Wings users.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • isGuest

         static boolean isGuest(long uid)

        Whether is Guest (eq -1)

      • asGuest

         static boolean asGuest(Long uid)

        Whether as Guest (null or le -1)

      • isNull

         static boolean isNull(long uid)

        Whether Null value

      • asNull

         static boolean asNull(Long uid)

        Whether null Object or Null value

      • value

         static long value(Long uid)

        trim value or Null

      • isWings

         static boolean isWings(long uid)

        Whether reserved Wings users.

      • asWings

         static boolean asWings(Long uid)

        Whether null or reserved Wings users.