Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

...

  • wsdl2js - reads a WSDL file, write JavaScript.
  • java2js - 'reads' Java code, using one of the CXF front ends (simple or JAX-WS) and one of the supported data bindings (Aegis or JAXB), and write JavaScript.
  • dynamic JavaScript - responds to a URL of the form http://host:port/port_and_or_service?jsImage Removed with the JavaScript code to talk to the service.

The dynamic mode is convenient: it avoids the need to generate and manage JavaScript files. You will probably find it helpful to generate some JavaScript files, however, and read them in order to understand what to code.

As a code generator, the JavaScript client generator is parallel to JAXB or JAX-WS. It defines a mapping from an abstract model of a web service to JavaScript objects. Unlike JAXB and JAX-WS, there is no committee that has standardized a 'JavaScript binding.' The CXF binding may not be to everyone's tastes.

The CXF JavaScript binding is only concerned with interfaces and operations. It is completely oblivious to 'services' and 'ports'. The programmer is expected to know the URL of the service, and that's that.

The Details