com.android.sdklib.internal.repository.packages
Enum Package.UpdateInfo

java.lang.Object
  extended by java.lang.Enum<Package.UpdateInfo>
      extended by com.android.sdklib.internal.repository.packages.Package.UpdateInfo
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<Package.UpdateInfo>
Enclosing class:
Package

public static enum Package.UpdateInfo
extends java.lang.Enum<Package.UpdateInfo>

Enum for the result of Package.canBeUpdatedBy(Package). This used so that we can differentiate between a package that is totally incompatible, and one that is the same item but just not an update.

See Also:
Package.canBeUpdatedBy(Package)

Enum Constant Summary
INCOMPATIBLE
          Means that the 2 packages are not the same thing
NOT_UPDATE
          Means that the 2 packages are the same thing but one does not upgrade the other.
UPDATE
          Means that the 2 packages are the same thing, and one is the upgrade of the other
 
Method Summary
static Package.UpdateInfo valueOf(java.lang.String name)
          Returns the enum constant of this type with the specified name.
static Package.UpdateInfo[] 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, toString, valueOf
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

INCOMPATIBLE

public static final Package.UpdateInfo INCOMPATIBLE
Means that the 2 packages are not the same thing


NOT_UPDATE

public static final Package.UpdateInfo NOT_UPDATE
Means that the 2 packages are the same thing but one does not upgrade the other.

TODO: this name is confusing. We need to dig deeper.


UPDATE

public static final Package.UpdateInfo UPDATE
Means that the 2 packages are the same thing, and one is the upgrade of the other

Method Detail

values

public static Package.UpdateInfo[] 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 (Package.UpdateInfo c : Package.UpdateInfo.values())
    System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they are declared

valueOf

public static Package.UpdateInfo 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