Global Endpoint user-defined type definition

Bindings defined for the Web service can be changed at runtime.

A public variable for the bindings of the Web Service is generated in the stub file generated by the fglwsdl. For example:

#
# Location of the SOAP endpoint.
# You can reassign this value at run-time.
#

PUBLIC Calculator_CalculatorPortTypeSoap12Endpoint WSHelper.tGlobalEndpointType
This references the WSHelper.tGlobalEndpointType defined in the WSHelper module, included in the $FGLDIR/lib directory of the Genero Web Services package.
#
# Global Endpoint user-defined type definition in WSHelper
#
PUBLIC TYPE tGlobalEndpointType RECORD  # End point
	Address RECORD # Address
	   Uri STRING  # URI
	END RECORD,
	Binding RECORD # Binding
	   Version STRING,	# HTTP Version (1.0 or 1.1)
	   Cookie STRING,	 # Cookie to be set
	   Request RECORD	 # HTTP request
             Headers DYNAMIC ARRAY OF RECORD  # HTTP Headers
	        Name STRING,
	        Value STRING
	      END RECORD
	   END RECORD,
	   Response RECORD # HTTP response
             Headers DYNAMIC ARRAY OF RECORD # HTTP Headers
	         Name STRING,
                Value STRING
             END RECORD
          END RECORD,
          ConnectionTimeout INTEGER,  # Connection timeout
          ReadWriteTimeout INTEGER,   # Read write timeout
          CompressRequest STRING      # HTTP request compression mode (gzip or deflate)
	END RECORD
END RECORD

The CompressRequest entry is of type string. It is NULL by default, meaning that no request is compressed. To compress a request, set this variable to gzip or deflate. The server must support compression, otherwise the request will be rejected.