Package com.uc4.api

Class UC4Alias


  • public class UC4Alias
    extends java.lang.Object
    This class stores a valid alias. The method toString() of this class can be used to get the alias as String
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static UC4Alias EMPTY
      Represents an empty UC4Alias.
    • Constructor Summary

      Constructors 
      Constructor Description
      UC4Alias​(java.lang.String name)
      Creates a new alias.
    • Field Detail

      • EMPTY

        public static final UC4Alias EMPTY
        Represents an empty UC4Alias.
    • Constructor Detail

      • UC4Alias

        public UC4Alias​(java.lang.String name)
        Creates a new alias.
        Parameters:
        name - Name of the Object
        Throws:
        InvalidUC4NameException - If the name has more than 200 characters.
    • Method Detail

      • aliasOf

        public static UC4Alias aliasOf​(java.lang.String value)
        Creates an alias from a String value. If input value is not valid then an empty UC4Alias is returned.
        Parameters:
        value - input value
        Returns:
        a UC4Alias which is empty if input is not valid.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object obj)
        Overrides:
        equals in class java.lang.Object