Class RequestCreator

java.lang.Object
org.opengis.cite.cat20.dgiwg10.xml.RequestCreator

public class RequestCreator extends Object
Author:
Lyn Goltz
  • Constructor Details

    • RequestCreator

      public RequestCreator()
  • Method Details

    • createGetRecordsRequest

      public Document createGetRecordsRequest(OutputSchema outputSchema, ElementSetName elementSetName)
      Parameters:
      outputSchema - the outputSchema to use in the request, never null
      elementSetName - the elementSetName to use in the request, never null
      Returns:
      the request, never null
      Throws:
      IllegalArgumentException - if no POST endpoint for operation GetRecords could be found in the capabilities
    • createGetRecordsRequest

      public Document createGetRecordsRequest(OutputSchema outputSchema, ElementSetName elementSetName, Node filter)
      Parameters:
      outputSchema - the outputSchema to use in the request, never null
      elementSetName - the elementSetName to use in the request, never null
      filter - the filter to append (local name must be 'Filter'), may be null if no filter should be added
      Returns:
      the request, never null
      Throws:
      IllegalArgumentException - if no POST endpoint for operation GetRecords could be found in the capabilities or the passed filter does not have a local name 'Filter'
    • createGetRecordById

      public Document createGetRecordById(OutputSchema outputSchema, ElementSetName elementSetName, String identifier)
      Parameters:
      outputSchema - the outputSchema to use in the request, never null
      elementSetName - the elementSetName to use in the request, never null
      identifier - the id to append, never null
      Returns:
      the request, never null
      Throws:
      IllegalArgumentException - if no POST endpoint for operation GetRecordById could be found in the capabilities
    • createInsertRequest

      public Document createInsertRequest(RequestCreator.RECORDTYPE recordType)
      Parameters:
      recordType - the type of the record, never null
      Returns:
      an CSW insert request, never null
      Throws:
      IllegalArgumentException - if the request could not be created
    • createUpdateRequest

      public Document createUpdateRequest(RequestCreator.RECORDTYPE recordType)
      Parameters:
      recordType - the type of the record, never null
      Returns:
      an CSW update request, never null
      Throws:
      IllegalArgumentException - if the request could not be created
    • createDeleteRequest

      public Document createDeleteRequest(String identifier)
      Parameters:
      identifier - the identifier of the record to delete, never null
      Returns:
      an CSW delete request, never null
      Throws:
      IllegalArgumentException - if the request could not be created
    • createHarvest

      public Document createHarvest(String source)