Package org.eclipse.rdf4j.sparqlbuilder.constraint.propertypath.builder

## Class PropertyPathBuilder

- java.lang.Object
- - org.eclipse.rdf4j.sparqlbuilder.constraint.propertypath.builder.PropertyPathBuilder

-     public class PropertyPathBuilder
      extends Object

  Since:
    4.0.0
  Author:
    Florian Kleedorfer

- - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `PropertyPath` | `build()` | Build the path.
    `PropertyPathBuilder` | `group()` | Enclose the path with ``(` and `)``.
    `PropertyPathBuilder` | `inv()` | Invert whatever comes next (i.e.
    `static PropertyPathBuilder` | `of​(IRI predicate)` |
    `static PropertyPathBuilder` | `of​(Iri predicate)` |
    `PropertyPathBuilder` | `oneOrMore()` | Append ``+`` to the path.
    `PropertyPathBuilder` | `or​(Consumer<EmptyPropertyPathBuilder> subtreeBuilder)` | Append ``|`` and the product of the `subtreeBuilder` to the path.
    `PropertyPathBuilder` | `or​(IRI predicate)` | Append ``|` path` to the path.
    `PropertyPathBuilder` | `or​(PropertyPath path)` | Append ``|` path` to the path.
    `PropertyPathBuilder` | `or​(Iri predicate)` | Append ``|` predicate` to the path.
    `PropertyPathBuilder` | `then​(Consumer<EmptyPropertyPathBuilder> subtreeBuilder)` | Append ``/`` and the product of the `subtreeBuilder` to the path.
    `PropertyPathBuilder` | `then​(IRI predicate)` | Append ``/` path` to the path.
    `PropertyPathBuilder` | `then​(PropertyPath path)` | Append ``/` path` to the path.
    `PropertyPathBuilder` | `then​(Iri predicate)` | Append ``/` predicate` to the path.
    `PropertyPathBuilder` | `zeroOrMore()` | Append ``*`` to the path.
    `PropertyPathBuilder` | `zeroOrOne()` | Append ``?`` to the path.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### of

          public static PropertyPathBuilder of​(Iri predicate)

    - #### of

          public static PropertyPathBuilder of​(IRI predicate)

    - #### build

          public PropertyPath build()

      Build the path.
      Returns:

    - #### inv

          public PropertyPathBuilder inv()

      Invert whatever comes next (i.e. append `^`.

    - #### then

          public PropertyPathBuilder then​(Iri predicate)

      Append ``/` predicate` to the path.

    - #### then

          public PropertyPathBuilder then​(IRI predicate)

      Append ``/` path` to the path.

    - #### then

          public PropertyPathBuilder then​(PropertyPath path)

      Append ``/` path` to the path.

    - #### then

          public PropertyPathBuilder then​(Consumer<EmptyPropertyPathBuilder> subtreeBuilder)

      Append ``/`` and the product of the `subtreeBuilder` to the path.

    - #### or

          public PropertyPathBuilder or​(Iri predicate)

      Append ``|` predicate` to the path.

    - #### or

          public PropertyPathBuilder or​(IRI predicate)

      Append ``|` path` to the path.

    - #### or

          public PropertyPathBuilder or​(PropertyPath path)

      Append ``|` path` to the path.

    - #### or

          public PropertyPathBuilder or​(Consumer<EmptyPropertyPathBuilder> subtreeBuilder)

      Append ``|`` and the product of the `subtreeBuilder` to the path.

    - #### zeroOrMore

          public PropertyPathBuilder zeroOrMore()

      Append ``*`` to the path.

    - #### oneOrMore

          public PropertyPathBuilder oneOrMore()

      Append ``+`` to the path.

    - #### zeroOrOne

          public PropertyPathBuilder zeroOrOne()

      Append ``?`` to the path.

    - #### group

          public PropertyPathBuilder group()

      Enclose the path with ``(` and `)``.