Raible's Wiki

Raible Designs
Wiki Home
News
Recent Changes

AppFuse

Homepage
  - Korean
  - Chinese
  - Italian
  - Japanese

QuickStart Guide
  - Chinese
  - French
  - German
  - Italian
  - Korean
  - Portuguese
  - Spanish
  - Japanese

User Guide
  - Korean
  - Chinese

Tutorials
  - Chinese
  - German
  - Italian
  - Korean
  - Portuguese
  - Spanish

FAQ
  - Korean

Latest Downloads

Other Applications

Struts Resume
Security Example
Struts Menu

Set your name in
UserPreferences


Referenced by
Articles
Articles_pt
CreateDAO_es
SandBox




JSPWiki v2.2.33

[RSS]


Hide Menu

CreateManager_es


Difference between version 3 and version 2:

At line 3 changed 1 line.
;:''This tutorial depends on __Part I:__ [Creating new DAOs and Objects in AppFuse|CreateDAO].''
;:''Este tutorial depende de __Part I:__ [Creating new DAOs and Objects in AppFuse|CreateDAO].''
At line 5 changed 2 lines.
!!About this Tutorial
This tutorial will show you how to create a Business Facade class (and a JUnit Test) to talk to the [DAO we created in Part I|CreateDAO].
!!Sobre este tutorial
Este tutorial te mostrara como crear clases del tipo Business Facada (asi como test unitario ) para interactuar ,[con la capa DAO creada in Part I|CreateDAO].
At line 8 changed 1 line.
In the context of [AppFuse], this is called a Manager class. Its main responsibility is to act as a bridge between the persistence (DAO) layer and the web layer. It's also useful for de-coupling your presentation layer from your database layer (i.e. for Swing apps). Managers should also be where you put any business logic for your application.
En el contexto de [AppFuse], crearemos lo que se llama una clase Manager. Su principal objetivo es la de servir de puente entre la capa de persistencia DAO y la capa de presentacion. Tambien permite aislar la capa de presentacion de la capa de persistencia(i.e. para aplicaciones Swing ). Ademas, contienen toda la logica de la aplicacion.
At line 10 changed 1 line.
;:%%(color: blue)''I will tell you how I do stuff in the __Real World__ in text like this.''%%
;:%%(color: blue)''Te voy a decir como yo hago las cosas en la __Vida Real__ en texto como este.''%%
At line 12 removed 1 line.
Let's get started by creating a new ManagerTest and Manager in AppFuse's architecture.
At line 14 changed 5 lines.
!Table of Contents
* [1] Create a new ManagerTest to run JUnit tests on the Manager
* [2] Create a new Manager to talk to the DAO
* [3] Configure Spring for this Manager and Transactions
* [4] Run the ManagerTest
Vamos a empezar creando una clase ManagerTest y otra clase Manager en la arquitectura de AppFuse.
At line 20 changed 2 lines.
!!Create a new ManagerTest to run JUnit tests on the Manager [#1]
In [Part I|CreateDAO], we created a Person object and PersonDao - so let's continue developing this entity. First, let's create a JUnit test for the PersonManager. Create PersonManagerTest in the test/service/**/service directory. We'll want to test the same basic methods (get, save, remove) that our DAO has.
!Tabla de Contenidos
* [1] Crear una nueva clase ManagerTest para ejecutar tests JUnit con relacion a la clase Manager.
* [2] Crear una nueva clase Manager que interaccionara con la capa DAO.
* [3] Configurar Spring para la clase Manager y gestion de transacciones.
* [4] Ejecutar la clase ManagerTest
At line 23 changed 1 line.
;:''This may seem redundant (why all the tests!), but these tests are GREAT to have 6 months down the road.''
!!Crear una nueva clase ManagerTest para ejecutar tests JUnit con relacion a la clase Manager. [#1]
En [Part I|CreateDAO],creamos una clase Person y PersonDao - por lo que vamos a seguir desarrollando esta entidad. Primero, crearemos una nueva clase de prueba JUnit para probar la clase PersonManager. Crea la clase PersonManagerTest en el directorio test/service/**/service. Vamos a probar los metodos basicos (leer, anadir, eliminar) que contiene nuestra clase.
At line 24 added 2 lines.
;:''El hecho de tener tantas clases de prueba puede parecer redundante, sin embargo, dentro de 6 meses nos seran de mucha ayuda.''

Back to CreateManager_es, or to the Page History.