Class Typedef

  • Direct Known Subclasses:
    TypeDef, TypeDef

    public abstract class Typedef
    extends java.lang.Object
    Implements the typedef element, actually a type alias.
    Author:
    Holger Eichelberger
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.String name  
      private TypeDescriptor<?> type  
    • Constructor Summary

      Constructors 
      Constructor Description
      Typedef​(java.lang.String name, TypeDescriptor<?> type)
      Creates a typedef.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.Object accept​(IVisitor visitor)
      Accepts the visitor for visiting.
      java.lang.String getName()
      Returns the alias name.
      TypeDescriptor<?> getType()
      Returns the represented type.
      • Methods inherited from class java.lang.Object

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

      • name

        private java.lang.String name
    • Constructor Detail

      • Typedef

        public Typedef​(java.lang.String name,
                       TypeDescriptor<?> type)
                throws VilException
        Creates a typedef.
        Parameters:
        name - the alias name
        type - the type to be used for name
        Throws:
        VilException - if one of the arguments is invalid
    • Method Detail

      • accept

        public java.lang.Object accept​(IVisitor visitor)
                                throws VilException
        Accepts the visitor for visiting.
        Parameters:
        visitor - the visitor to be used
        Returns:
        the result of visiting this instance (may be null)
        Throws:
        VilException - in case that visiting fails (e.g., execution)
      • getName

        public java.lang.String getName()
        Returns the alias name.
        Returns:
        the alias name
      • getType

        public TypeDescriptor<?> getType()
        Returns the represented type.
        Returns:
        the represented type