Chapter 23. Working with HTTPService and XML

IN THIS CHAPTER

  • Understanding RPC and REST Web services

  • Understanding HTTP communications

  • Generating HTTP data connection code with Flash Builder 4

  • Using the HTTPService control

  • Retrieving data at runtime

  • Parsing XML formatted data

  • Passing parameters to an application server

  • Generating HTTPService code with Flash Builder

  • Working with Flash Player security

Applications built with the Flex framework are commonly both dynamic and data-centric: They use, present, and enable users to modify data that's imported at runtime from a server-based data store (or, in the case of desktop applications running on Adobe AIR, a local database).

Flash Player and Adobe AIR don't have the capability to communicate directly with server-based data storage applications such as database and Lightweight Directory Access Protocol (LDAP) servers. Instead, they're designed to communicate with middleware application servers using a variety of protocols.

The Flex framework includes three Remote Procedure Call (RPC) components that enable you to integrate your Flex applications with common application server products. Of these, the HTTPService component has the most flexibility in terms of the format of messages that are exchanged between the client and server at runtime. Unlike the other RPC components, you can use the HTTPService component with any application server, because it exchanges data in the form of simple HTTP (Hypertext Markup Language) parameters and XML (EXtensible ...

Get Flash® Builder™ 4 and Flex® 4 Bible now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.