1////////////////////////////////////////////////////////////////////////////////
2//
3//  ADOBE SYSTEMS INCORPORATED
4//  Copyright 2007 Adobe Systems Incorporated
5//  All Rights Reserved.
6//
7//  NOTICE: Adobe permits you to use, modify, and distribute this file
8//  in accordance with the terms of the license agreement accompanying it.
9//
10////////////////////////////////////////////////////////////////////////////////
11
12package mx.rpc.soap
13{
14
15import mx.rpc.wsdl.WSDLOperation;
16import mx.rpc.xml.SchemaConstants;
17import mx.rpc.xml.IXMLEncoder;
18
19[ExcludeClass]
20
21/**
22 * An ISOAPEncoder is used to create SOAP 1.1 formatted requests for a web
23 * service operation. A WSDLOperation provides the definition of how a SOAP
24 * request should be formatted and therefore must be set before a call is made to
25 * encode().
26 *
27 */
28public interface ISOAPEncoder extends IXMLEncoder
29{
30    //--------------------------------------------------------------------------
31    //
32    // Properties
33    //
34    //--------------------------------------------------------------------------
35
36    /**
37     * Determines whether the encoder should ignore whitespace when
38     * constructing an XML representation of a SOAP request.
39     * The default should be <code>true</code> and thus whitespace not preserved.
40     * If an XML Schema type definition specifies a <code>whiteSpace</code>
41     * restriction set to <code>preserve</code> then ignoreWhitespace must
42     * first be set to false. Conversely, if a type <code>whiteSpace</code>
43     * restriction is set to <code>replace</code> or <code>collapse</code> then
44     * that setting will be honored even if ignoreWhitespace is set to <code>false</code>.
45     */
46    function get ignoreWhitespace():Boolean;
47    function set ignoreWhitespace(value:Boolean):void;
48
49    /**
50     * A WSDLOperation defines the SOAP binding styles and specifies how to
51     * encode a SOAP request.
52     */
53    function get wsdlOperation():WSDLOperation;
54    function set wsdlOperation(value:WSDLOperation):void;
55
56    //--------------------------------------------------------------------------
57    //
58    // Methods
59    //
60    //--------------------------------------------------------------------------
61
62    /**
63     * Creates a SOAP-encoded request to an operation from the given input
64     * parameters and headers.
65	 *
66	 * @param args values to be encoded in the body of the SOAP request.
67	 *
68	 * @param headers header values to be encoded in the SOAP envelope.
69     *
70     * @return SOAP-encoded XML representation of the passed in arguments and headers.
71     */
72    function encodeRequest(args:* = null, headers:Array = null):XML;
73}
74
75}