org.eclipse.rdf4j.query.parser

## Class ParsedUpdate

- java.lang.Object
- - org.eclipse.rdf4j.query.parser.ParsedOperation
  - - org.eclipse.rdf4j.query.parser.ParsedUpdate

- Direct Known Subclasses:
    ParsedUpdateTemplate

      public class ParsedUpdate
      extends ParsedOperation

  A parsed update sequence formulated in the OpenRDF query algebra.
  Author:
    Jeen Broekstra

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ParsedUpdate()` Creates a new update sequence.
    `ParsedUpdate(Map<String,String> namespaces)` Creates a new update sequence.
    `ParsedUpdate(String sourceString)`
    `ParsedUpdate(String sourceString, Map<String,String> namespaces)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addUpdateExpr(UpdateExpr updateExpr)`
    `Map<UpdateExpr,Dataset>` | `getDatasetMapping()`
    `Map<String,String>` | `getNamespaces()`
    `List<UpdateExpr>` | `getUpdateExprs()`
    `void` | `map(UpdateExpr updateExpr, Dataset dataset)`
    `String` | `toString()`

    - ### Methods inherited from class org.eclipse.rdf4j.query.parser.ParsedOperation

      `getSourceString`

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

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

- - ### Constructor Detail

    - #### ParsedUpdate

          public ParsedUpdate()

      Creates a new update sequence. To complete this update sequence, one or more update expressions need to be supplied to it using `addUpdateExpr(UpdateExpr)`.

    - #### ParsedUpdate

          public ParsedUpdate(String sourceString)

    - #### ParsedUpdate

          public ParsedUpdate(String sourceString,
                              Map<String,String> namespaces)

    - #### ParsedUpdate

          public ParsedUpdate(Map<String,String> namespaces)

      Creates a new update sequence. To complete this update sequence, one or update expressions need to be supplied to it using `addUpdateExpr(UpdateExpr)`.
      Parameters:
        `namespaces` - A mapping of namespace prefixes to namespace names representing the namespaces that are used in the update.

  - ### Method Detail

    - #### getNamespaces

          public Map<String,String> getNamespaces()

    - #### addUpdateExpr

          public void addUpdateExpr(UpdateExpr updateExpr)

    - #### getUpdateExprs

          public List<UpdateExpr> getUpdateExprs()

    - #### map

          public void map(UpdateExpr updateExpr,
                          Dataset dataset)

      Parameters:
        `updateExpr` - The updateExpr to map to a dataset.
        `dataset` - the dataset that applies to the updateExpr. May be null.

    - #### getDatasetMapping

          public Map<UpdateExpr,Dataset> getDatasetMapping()

      Returns:
        Returns the map of update expressions and associated datasets.

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

Copyright © 2015-2021 Eclipse Foundation. All Rights Reserved.