Interface PrintoutContents


@Nullable public interface PrintoutContents
The contents of a page (or book) created by a ComputerCraft printer.
Since:
1.115
  • Method Summary

    Modifier and Type
    Method
    Description
    static @Nullable PrintoutContents
    get(net.minecraft.world.item.ItemStack stack)
    Get the printout contents for a particular stack.
    Get the text contents of this printout, as a sequence of lines.
    Get the (possibly empty) title for this printout.
  • Method Details

    • getTitle

      String getTitle()
      Get the (possibly empty) title for this printout.
      Returns:
      The title of this printout.
    • getTextLines

      Stream<String> getTextLines()
      Get the text contents of this printout, as a sequence of lines.

      The lines in the printout may include blank lines at the end of the document, as well as trailing spaces on each line.

      Returns:
      The text contents of this printout.
    • get

      static @Nullable PrintoutContents get(net.minecraft.world.item.ItemStack stack)
      Get the printout contents for a particular stack.
      Parameters:
      stack - The stack to get the contents for.
      Returns:
      The printout contents, or null if this is not a printout item.