Package com.iizix.urn

Enum Class NID

All Implemented Interfaces:
Serializable, Comparable<NID>, Constable

public enum NID extends Enum<NID>
Available Namespace IDentifiers (NID) for IIZI resources. The NID string is case sensitive.

IIZI Uniform Resource Names (URN) are using the common standard.

A URN normally looks like below, but you can read more at Uniform Resource Name.

The IIZI implementation for URN's to reference various parts in IIZI is:

   "urn:NID:NSS:[?+r-component]][?=q-component][#fragment]".
 

or, in the form of a syntax diagram, as:

URN syntax diagram - namestring

In the IIZI case, the use of the some NID's also requires specifying an environment location ({@link NIDLocation}) where the data is stored, e.g. in a database, a server cluster, a server instance (for security), a user (chosen to be identified or not), a user identifier, an application, a specific user session or a specific user client session. In the case a location is used, the resource URL produced from the URN will be private to that particular location, e.g. a server, a user or its application/client session.

Luckily, the abstraction of the final naming depends on so many things, but you don't have to worry about it. Just place it in the correct NID (Name space IDentifier) and leave the complexity to the framework.

The IIZI NID's are not registered with IANA, so they are all prefixed with "iz-" in this enum class.

Author:
Christopher Mindus
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    Barcode with required type and string: "iz-barcode".
    File (e.g.
    Image in bitmap form: "iz-img".
    Profile image: "iz-pimg".
    Profile string (fullName, firstName, lastName, etc): "iz-pstr".
    SVG image: "iz-svg".
    External (web) URL (typically http[s] or ftp[s]): "iz-url".
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    final String
    The NID string, always starting with "iz-" because the NID is not registered with IANA, and is "private" to the IIZI platform.
  • Method Summary

    Modifier and Type
    Method
    Description
    static NID
    from(String nid)
    Looks up a NID Namespace IDentifier from a case sensitive string.
    static NID
    Returns the enum constant of this class with the specified name.
    static NID[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

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

    • BARCODE

      public static final NID BARCODE
      Barcode with required type and string: "iz-barcode".
    • IMAGE

      public static final NID IMAGE
      Image in bitmap form: "iz-img".
    • SVG

      public static final NID SVG
      SVG image: "iz-svg".
    • PROFILE_IMAGE

      public static final NID PROFILE_IMAGE
      Profile image: "iz-pimg".
    • PROFILE_STRING

      public static final NID PROFILE_STRING
      Profile string (fullName, firstName, lastName, etc): "iz-pstr".
    • URL

      public static final NID URL
      External (web) URL (typically http[s] or ftp[s]): "iz-url".
    • FILE

      public static final NID FILE
      File (e.g. a PDF accessible from server using file system): "iz-file".
  • Field Details

    • nid

      public final String nid
      The NID string, always starting with "iz-" because the NID is not registered with IANA, and is "private" to the IIZI platform.
  • Method Details

    • values

      public static NID[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static NID valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified name
      NullPointerException - if the argument is null
    • from

      public static NID from(String nid)
      Looks up a NID Namespace IDentifier from a case sensitive string.
      Parameters:
      nid - The NID string to find.
      Returns:
      The NID for the nid string, or null if not found.