Web services you build communicate with their clients and other web services through text messages formatted in the syntax of Extensible Markup Language (XML). There may be occasions when the messages your web service receives and sends must conform to a specific format. When this is the case, you can ensure a functional relationship between the parts of a message and the Java types of your service code by using XML maps.
In addition, using XML maps supports loose coupling between your web service's code and other components such as clients and resources used by your service; in other words, you need not change your Java code to meet the needs of components with which your service communicates.
An XML map acts as a bridge between your Java code and an XML message's structure—or shape. Using XML maps, you can anticipate the shape of incoming messages or control the shape of outgoing messages.
Note: This section assumes that you are familiar with the basics of XML. For basic information about XML, see Introduction to XML.