Class FaunaTemplate

  • All Implemented Interfaces:
    java.lang.Iterable<FaunaTemplate.TemplatePart>

    public class FaunaTemplate
    extends java.lang.Object
    implements java.lang.Iterable<FaunaTemplate.TemplatePart>
    Represents a template for constructing Fauna queries with placeholders for variable interpolation.
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static class  FaunaTemplate.TemplatePart
      Represents a part of the template, which can either be a literal string or a variable placeholder.
    • Constructor Summary

      Constructors 
      Constructor Description
      FaunaTemplate​(java.lang.String template)
      Constructs a new FaunaTemplate with the given string template.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Iterator<FaunaTemplate.TemplatePart> iterator()
      Creates an iterator over the parts of the template, distinguishing between literals and variable placeholders.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.lang.Iterable

        forEach, spliterator
    • Constructor Detail

      • FaunaTemplate

        public FaunaTemplate​(java.lang.String template)
        Constructs a new FaunaTemplate with the given string template.
        Parameters:
        template - the string template containing literals and placeholders.
    • Method Detail

      • iterator

        public java.util.Iterator<FaunaTemplate.TemplatePart> iterator()
        Creates an iterator over the parts of the template, distinguishing between literals and variable placeholders.
        Specified by:
        iterator in interface java.lang.Iterable<FaunaTemplate.TemplatePart>
        Returns:
        an Iterator that traverses the template parts.