Interface RenderStack


  • public interface RenderStack
    Represents the stack of models currently processed by the generator. For an example, if a Field is currently being transformed into a String, the stack might look like this:
         File → Class → Method → Field
     
    Since:
    2.0
    Author:
    Emil Forslund
    See Also:
    Generator
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      <T> Stream<T> fromBottom​(Class<T> type)
      Returns a Stream of all models in the stack of a particular type from bottom and up.
      <T> Stream<T> fromTop​(Class<T> type)
      Returns a Stream of all models in the stack of a particular type from top to bottom.
      boolean isEmpty()
      Returns true if there are no models in the stack.
    • Method Detail

      • fromBottom

        <T> Stream<T> fromBottom​(Class<T> type)
        Returns a Stream of all models in the stack of a particular type from bottom and up.
        Type Parameters:
        T - the type of the models to return
        Parameters:
        type - the type of the models to return
        Returns:
        a stream of all models of that type
      • fromTop

        <T> Stream<T> fromTop​(Class<T> type)
        Returns a Stream of all models in the stack of a particular type from top to bottom.
        Type Parameters:
        T - the type of the models to return
        Parameters:
        type - the type of the models to return
        Returns:
        a stream of all models of that type
      • isEmpty

        boolean isEmpty()
        Returns true if there are no models in the stack.
        Returns:
        true if the stack is empty