Enum ElevationState

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<ElevationState>

    public enum ElevationState
    extends java.lang.Enum<ElevationState>
    Enumeration class for the different elevation states the current process can be in.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String toString()  
      static ElevationState valueOf​(java.lang.String name)
      Returns the enum constant of this type with the specified name.
      static ElevationState[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      • Methods inherited from class java.lang.Enum

        clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, valueOf
      • Methods inherited from class java.lang.Object

        getClass, notify, notifyAll, wait, wait, wait
    • Enum Constant Detail

      • ELEVATION_STATE_NOT_APPLICABLE

        public static final ElevationState ELEVATION_STATE_NOT_APPLICABLE
        All processes on a system with a Windows version previous to Vista.
      • ELEVATION_STATE_DEFAULT

        public static final ElevationState ELEVATION_STATE_DEFAULT
        The current process is not limited and not elevated on Vista or higher. This can be a process of a non-admin user, or of an admin user when UAC is turned off. You can differentiate between those two with Util.hasFullAdminRights().
      • ELEVATION_STATE_LIMITED

        public static final ElevationState ELEVATION_STATE_LIMITED
        The current process runs with limited rights. UAC is turned on.
      • ELEVATION_STATE_FULL

        public static final ElevationState ELEVATION_STATE_FULL
        The current process was elevated and runs with full rights. UAC is turned on.
    • Method Detail

      • values

        public static ElevationState[] values()
        Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:
        for (ElevationState c : ElevationState.values())
            System.out.println(c);
        
        Returns:
        an array containing the constants of this enum type, in the order they are declared
      • valueOf

        public static ElevationState valueOf​(java.lang.String name)
        Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
        Parameters:
        name - the name of the enum constant to be returned.
        Returns:
        the enum constant with the specified name
        Throws:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Enum<ElevationState>