com.h3c.sdn.artifact

## Enum ArtifactType

- java.lang.Object
- - java.lang.Enum<ArtifactType>
  - - com.h3c.sdn.artifact.ArtifactType

- All Implemented Interfaces:
    Serializable, Comparable<ArtifactType>

      public enum ArtifactType
      extends Enum<ArtifactType>

  Define values for the types of artifacts managed by the system. Each ArtifactType understands the known file extensions for OSGi artifacts represented by these types.

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `BUNDLE` OSGi bundle artifact.
    `CONFIG` OSGi configuration file.
    `PAR` OSGi par application package.
    `PLAN` OSGi application definition plan.
    `ZIP` Compressed Zip archive.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `static ArtifactType` | `getByFileName(String fileName)` Find the ArtifactType enumeration represented by the supplied file name.
    `static ArtifactType` | `getByTypeId(String typeId)` Find the ArtifactType enumeration represented by the supplied parameter.
    `String` | `toString()`
    `static ArtifactType` | `valueOf(String name)` Returns the enum constant of this type with the specified name.
    `static ArtifactType[]` | `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

    - #### BUNDLE

          public static final ArtifactType BUNDLE

      OSGi bundle artifact.

    - #### PAR

          public static final ArtifactType PAR

      OSGi par application package.

    - #### PLAN

          public static final ArtifactType PLAN

      OSGi application definition plan.

    - #### CONFIG

          public static final ArtifactType CONFIG

      OSGi configuration file.

    - #### ZIP

          public static final ArtifactType ZIP

      Compressed Zip archive.

  - ### Method Detail

    - #### values

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

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

    - #### valueOf

          public static ArtifactType valueOf(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:
        `IllegalArgumentException` - if this enum type has no constant with the specified name
        `NullPointerException` - if the argument is null

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Enum<ArtifactType>`

    - #### getByTypeId

          public static ArtifactType getByTypeId(String typeId)

      Find the ArtifactType enumeration represented by the supplied parameter.
      Parameters:
        `typeId` - the string representing the desired ArtifactType
      Returns:
        the ArtifactType matching the supplied parameter string, null if the parameter string does not resolve to a supported type.

    - #### getByFileName

          public static ArtifactType getByFileName(String fileName)

      Find the ArtifactType enumeration represented by the supplied file name. The file name is matched against the known file extension strings for OSGi artifacts.
      Parameters:
        `fileName` - the name of the file representing an OSGi artifact
      Returns:
        the ArtifactType associated with this OSGi file (based on extension) or null if filename does not represent a known OSGi file extension.

Copyright © 2014. All Rights Reserved.