Class TypeAlias

  • All Implemented Interfaces:
    Alias

    public class TypeAlias
    extends java.lang.Object
    implements Alias
    a simple Alias for a single Class or Type, using equals on the names in the resolve method.

    See Alias for concrete examples.
    • Constructor Summary

      Constructors 
      Constructor Description
      TypeAlias​(java.lang.Class storedClass, java.lang.Class runtimeClass)  
      TypeAlias​(java.lang.String storedType, java.lang.String runtimeType)
      pass the stored name as the first parameter and the desired runtime name as the second parameter.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String resolveRuntimeName​(java.lang.String runtimeTypeName)
      returns the stored type name if the alias was written for the passed runtime type name
      java.lang.String resolveStoredName​(java.lang.String storedTypeName)
      returns the runtime type name if the alias was written for the passed stored type name
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • TypeAlias

        public TypeAlias​(java.lang.String storedType,
                         java.lang.String runtimeType)
        pass the stored name as the first parameter and the desired runtime name as the second parameter.
      • TypeAlias

        public TypeAlias​(java.lang.Class storedClass,
                         java.lang.Class runtimeClass)
    • Method Detail

      • resolveRuntimeName

        public java.lang.String resolveRuntimeName​(java.lang.String runtimeTypeName)
        returns the stored type name if the alias was written for the passed runtime type name
        Specified by:
        resolveRuntimeName in interface Alias
      • resolveStoredName

        public java.lang.String resolveStoredName​(java.lang.String storedTypeName)
        returns the runtime type name if the alias was written for the passed stored type name
        Specified by:
        resolveStoredName in interface Alias