Example 5-20: The xml_http helper package specification

CREATE OR REPLACE PACKAGE xml_http AS

  -- POST XML document in string buffer to URL, return response as XML Document

  PROCEDURE post(doc             VARCHAR2,
                 url             VARCHAR2,
                 resp        OUT xmldom.DOMDocument,
                 proxyServer     VARCHAR2 := NULL,
                 proxyPort       NUMBER   := 80);

  -- HTTP POST XML document to URL and return response as an XML document

  PROCEDURE post(doc             xmldom.DOMDocument,
                 url             VARCHAR2,
                 resp        OUT xmldom.DOMDocument,
                 proxyServer     VARCHAR2 := NULL,
                 proxyPort       NUMBER   := 80);

  -- HTTP GET resource at URL and return response as an XML document

  PROCEDURE get(url             VARCHAR2,
                resp        OUT xmldom.DOMDocument,
                proxyServer     VARCHAR2 := NULL,
                proxyPort       NUMBER   := 80);

END;