» Flex LiveCycle DataManagement Service and Hibernate together
Hibernate and Adobe Flex frontends are easily connected by using the DataManagement Service. In Java developed classes can be accessed in the Flex application using a ActionScript class with the same setter- and getter methods. This ActionScript class represents the Java class in the Client. Any changes you make at the ActionScript class are directly effecting the class on the server.
There is no need to develop DataAccess classes. All create-, update-, and delete-operations are handled by the DataManagement Service. Behind the Scenes the class
But there is also a disadvantage. The Service is based on the Real Time Messaging Protocol which uses the port 2038. This port might be blocked by firewalls. This actually limits this service to closed Environments like intranets. If you want to use Hibernate in for a internet application it might be better implementing your own DataAccess objects and provide the public methods of these Objects to your clients by a Webservice.
When you start the Tomcat the Hypersonic Database is up and running too.
This Flex application enables you to create, update and delete students and courses. To make the example less complex we do not develop a feature which enables you to assign courses to students. In the default database are already a few assignments made. Our application can show this assignments.
Don't understand this as a tutorial. I do not give any explanation here like: now go to this folder, do this....bla. I just mention the important things. If you want to run the example download the tomcat or the sources (have a look at the boxes at the left side).
There is no need to develop DataAccess classes. All create-, update-, and delete-operations are handled by the DataManagement Service. Behind the Scenes the class
flex.data.adapters.JavaAdapter is taking care of the CRUD-Operations.But there is also a disadvantage. The Service is based on the Real Time Messaging Protocol which uses the port 2038. This port might be blocked by firewalls. This actually limits this service to closed Environments like intranets. If you want to use Hibernate in for a internet application it might be better implementing your own DataAccess objects and provide the public methods of these Objects to your clients by a Webservice.
The student course application
Students and courses, a m:n Relationship
In the following example we develop a application which enables you to manage students and courses. For both entities we create the Bean classes in Java and ActionScript. Hibernate takes care of persisting the Java objects. As database we using Hypersonic SQL, the web application server is a Tomcat.When you start the Tomcat the Hypersonic Database is up and running too.
This Flex application enables you to create, update and delete students and courses. To make the example less complex we do not develop a feature which enables you to assign courses to students. In the default database are already a few assignments made. Our application can show this assignments.
The application shows the assigned courses for a certain student
Don't understand this as a tutorial. I do not give any explanation here like: now go to this folder, do this....bla. I just mention the important things. If you want to run the example download the tomcat or the sources (have a look at the boxes at the left side).
03. November 2007