Question about design pattern - business delegate

hi guys
i have got a question to ask about the delegate pattern. usually, we use it to decouple between presentation client and businessservice tiers. for instance, the service tier has an session ejb, and delegate wrapps the ejb. and the web client calls delegate to access service. is the delegate only used by the presentation tier? within the service tier, we can have many ejbs that work together to get tasks done. do we still use delegates in the service tier? what is ur suggestion? thanks

Try the Patterns and OO Design forum.

Similar Messages

  • Question about design pattern - business delegate: repost

    hi guys
    i have got a question to ask about the delegate pattern. usually, we use it to decouple between presentation client and businessservice tiers. for instance, the service tier has an session ejb, and delegate wrapps the ejb. and the web client calls delegate to access service. is the delegate only used by the presentation tier? within the service tier, we can have many ejbs that work together to get tasks done. do we still use delegates in the service tier? what is ur suggestion? thanks

    thanks, but i don't think i follow what u said.
    bascially i was asking if it was still a good idea to use delegates to communicate between ejbs the same way presentation tier calls service tier. i.e. SessionEJBA calls DelegateB to access SessionEJBB. or SessionEJBA calls SessionEJBB directly including the lookup, etc.

  • A question about design of Java Application on java card.

    Hi every one,
    I have a question about design of Java applet on java card,
    There is an application on my card that it is not java card, it include a DF and some EF under DF, I would like to know if I want to have this application on java card ,how can I design DF and EF on java card ,I mean is there any relation between DF,EF with applet and file? for example can I say DF is same as applet and EF is same as file?
    I'll appreciate for any help .
    yours sincerely,
    orchid

    hi
    you can write a java class for DF.
    an instance of DF class have some EF objects.
    for example,
    samples/com/sun/javacard/samples/JavaPurse/CyclicFile.java
    implements ISO 7816 CyclicFile ( EF )
    see also:
    http://forum.java.sun.com/thread.jspa?threadID=673745&messageID=3936272
    best regards,
    siavash

  • Questions about DAO pattern

    Hi,
    I am a junior programmer and I am trying to understand somewhat more about best practices and design patterns.
    I am looking for more information regarding the DAO pattern, not the easy examples you find everywhere on the internet, but actual implementations of real world examples.
    Questions:
    1) Does a DAO always map with a single table in the database?
    2) Does a DAO contain any validation logic or is all validation logic contained in the Business Object?
    3) In a database I have 2 tables: Person and Address. As far as I understand the DAO pattern, I now create a PersonDAO and an AddressDAO who will perform the CRUD operations for the Person and Address objects. PersonDAO only has access to the Person table and AddressDAO only has access to the Address table. This seems correct to me, but what if I must be able to look up all persons who live in the same city? What if I also want to look up persons via their telephone numbers? I could add a findPersonByCity and findPersonByTelephoneNumber method to the PersonDAO, but that would result in the PersonDAO also accessing the Address table in the database (even though there already is an AddressDAO). Is that permitted? And why?
    I hope someone can help me out.
    Thanks for your time!
    Jeroen

    That is exactly what I am trying to do. I am writing it all myself to get a better understanding of it.
    Please bear with me, because there are some things I dont understand in your previous answer.
    1) Each BO validates his corresponding DTO and exposes operations to persist that DTO. Each DTO will be persisted in the database via his corresponding DAO. So this would be:
    - in PersonBO
    public void save(PersonDTO personDTO) {
    this.validate(personDTO); // does not validate the nested address DTOs
    this.personDAO.save(personDTO); // does not save the nested address DTOs
    - in AddressBO
    public void save(AddressDTO addressDTO) {
    this.validate(addressDTO);
    this.addressDAO.save(addressDTO);
    Am I viewing it from the right side now?
    2) Imagine a form designed to insert a new person in the database, it contains all fields for the Person DTO and 2 Address DTOs.
    How would I do this using my Business Objects?
    This is how I see it:
    // fill the DTOs
    daoManager.beginTransaction();
    try {
    personBO.setDao(daoManager.getDao(PersonDAO.class));
    personBO.save(personDTO); // save 1
    addressBO.setDao(daoManager.getDao(AddressDAO.class));
    addressBO.save(personDTO.getAddress(1)); // save 2
    addressBO.save(personDTO.getAddress(2)); // save 3
    daoManager.commit();
    catch(Exception e) {
    daoManager.rollBack();
    If I insert the transaction management inside the DAOs, I can never rollback save 1 when save 2 or save 3 fail.
    It can be that I am viewing it all wrong, please correct me if that is the case.
    Thanks!
    Jeroen

  • Basic Questions about Oracle E-Business Suite

    I am just now starting to learn about Oracle E-Business Suite.
    I am an Oracle DBA, and I want to become an "Oracle Apps DBA".
    The following questions pertain to the DATABASE side of E-Business:
    *(1)* Is "Oracle E-Business Suite", and "Oracle Applications 11i" the
    same product?
    *(2)* Is Release 12, the current version of E-Business Suite?
    *(3)* What is the Release of E-Business Suite that most Businesses are
    currently using?
    *(4)* I want to use 1GB of RAM, for the Laptop, that I want to install
    E-Business Suite on, and it will be running under Oracle
    Enterprise Linux -- Will this type of setup be OK for building a
    personal training and learning environment (especially RAM size)?
    *(5)* How much disk space do I need, just to do a basic install (no
    demo databases)?

    Hi,
    *(1)* Is "Oracle E-Business Suite", and "Oracle Applications 11i" the
    same product?Yes, it even includes R12.
    *(2)* Is Release 12, the current version of E-Business Suite?Yes, the most recent versions of R12 are (12.1.1 and 12.1.2).
    *(3)* What is the Release of E-Business Suite that most Businesses are
    currently using?Depends, some customer still on 11i while other customer managed to upgrade to R12 (or did a fresh installation/implementation of R12).
    *(4)* I want to use 1GB of RAM, for the Laptop, that I want to install
    E-Business Suite on, and it will be running under Oracle
    Enterprise Linux -- Will this type of setup be OK for building a
    personal training and learning environment (especially RAM size)?1 GB RAM is not enough, I would suggest you have 4 GB RAM (or more if possible).
    *(5)* How much disk space do I need, just to do a basic install (no
    demo databases)?This is documented in the installation manual, please refer to it to get the hardware requirements.
    Oracle Applications Installation Guide: Using Rapid Install
    http://download.oracle.com/docs/cd/B53825_03/current/acrobat/121oaig.pdf
    Regards,
    Hussein

  • [BOOK] What's the best book about DESIGN PATTERN

    Hi Guys,
    by experience, what's the best book for you concerning the Design Pattern in Abap. I mean :
    Quality,
    Comprehensiveness,
    Clearness,
    Amount of chapter,
    etc.
    Thank for advices.
    Rachid.

    Dear Rachid,
    This is rank 1 book, but u have learn online also. So many websites are there. example search: OO Design patterns ZEVOLVING.
    Regards,
    Abbas.

  • Question about bridge pattern

    its definition is "decouple an abstraction from its implementation so that the two can vary independently". I don't understand what "abstraction and the implementation vary independently" really mean and how .
    Before another question pls see the below class diagram of bridge pattern:
    http://images.cnblogs.com/cnblogs_com/zhenyulu/Pic91.gif
    My question is whether not using abstraction and just keeping implementation hierarchy can do the same thing? Interface and its implementation itself(polymorphism) can make extending easily and be well subject to open-closed principle,can't they?
    Sorry for my bad English.
    Edited by: fxbird on 2011-7-17 上午5:13

    fxbird wrote:
    jschell wrote:
    fxbird wrote:
    I think it's very common in j2ee development. Certainly isn't if someone is using a container.
    If someone is creating a container then I would suspect that such a pattern might be useful.
    However if someone is creating a container then there are going to be a lot of useful patterns. And lot of classes as well.
    And in total of the entire scope of creating a container the bridge would be a very small part.
    So it certainly isn't going to be "common".Hello jschell , what do you mean by 'container'? You phrased your comment about J2EE. A common idiom is to refer to a J2EE (actually newer name is JEE) server as a JEE container. Not sure why specifically that word is used but maybe because such servers are said to 'contain' applications.
    In my previous reply, the architecture I mentioned is ss(spring+struts2.x),the pattern I mentioned is a standard way. You either do not understand what I said or you do not understand what happens in those implementations.
    If I have 100,000 classes and 3 of them are implementing the bridge pattern then it is not "common".
    If I have 100,000 classes and 3,000 of them implement many bridge patterns (and not generated) then one could say it is "common".
    And having done some JEE applications I seriously doubt there is an implicit need to use the bridge pattern.
    The bridge pattern is intended to deal with a complex situation. Since there are more simple JEE applications than complex ones then it seems unlikely that there is a "common" need for it in JEE applications.
    Actual I've not been understood why it's used this way---define business interface, from my perspective, it doesn't have to define it, simply writing a business class and calling dao method is enough. I assume bo interface thing is a bridge pattern.I don't know why they would use the bridge pattern nor even if they really do. I wouldn't be surprised that it is used and I can also suppose that the use would be a good idea. Although it is quite possible as well that it is used incorrectly in some places.

  • Question about commond pattern

    Hi!
    can somebody tell me about any good resource where i can get knowledge of designing controller on basis of command pattern and an example will help me a lot....
    I want to develop a controller for my application which except's data from swing client and calls the appropriate business components (session beans) to perform the requested task , asked by customer.....
    Also i need to design Factories for my objects and need good resource to get started from....
    thanx in advance
    sajjad ahmed paracha

    Also take a look at Struts on apache.org. You can either use Struts directly or, if you want to develop your own, look at how they architected things as a starting point.
    - Saish

  • Question about Design Standard licence

    Hi!
    I would like to know, when you buy a licence Design Standar, this is only for one computer or you can install it on 2?
    I'm trying to understand also about volume licence.. This is useful only when you have how much computer? we are going to have maybe a maximum of 6 computer using that suite.
    Thanks!
    Christ

    Hi Christ, here's an overview guide to answer all those questions and more on Adobe volume licensing...
    If not, just post back with anything further.

  • Questions about  Designer

    Hello,
    I am new in this forum and in Oracle Designer also.
    I have started to work with Designer last month,
    I am learning to use it,
    and I have a question :
    - what is the difference between Template object and object library???? waht ares the uses of both them ?
    - waht is the difference between Designer et Designer headstart?
    thanks for your help ans have a good day,

    I'll give you my opinion based on my experience...
    Templates serves as 'skeletons' of generated forms and reports. You use them to define global appearance and functionalities of the module, but not details like specific item properties.
    The object libraries define the details of the generated objects, like items, canvas, windows. Many properties you can't define using templates, but can do using object libraries.
    Usually to generate an app you rely on both templates and object libraries, as well on preferences.
    I've never used headstart, but I think it's a kind of "add-on" to Designer, with pre-customized templates, object libraries etc (maybe it can be thought as a framework?)
    hth

  • Odd question about potential funny business on black berry.

    Im not really sure the model but my dad thinks it is 8530. He isn't too savy on technology and after spending 45 minutes on the main site looking at features, im still uncertain. My dad believes his gf is sending pictures or messages to randoms. One of the things he thinks she does is that she will go to send a message, addressed to my father himself, but also tag along another message to a different address with differing content. They argue almost everyday and he says he finds more and more shady business and im simply growing sick of it and its causing alot of stress on us all. To top it off she passwords tons of stuff in the phone and I dont have access to it. I was wondering if what I aforementioned is A: Possible, and B: if there are other things that she could be doing. She has... history.... anyways im wondering why in the hell she would go through all the effort, why not just delete the messages... 
    Thx for the help and sorry this message was so long=]

    Your situation is a bit confusing.  If she's about to send a message to your dad, she can also forward it to other people.  This bit about "tagging along another message to a different address with differing content" is not possible.  One message to one person or one message to multiple people, but sending one message to different people at once with another message which has differing content to many people is not possible.
    I hope I've understood you correctly and that my solution has helped you.  Please post back with clarification if I've missed something. 
    - If my response has helped you, please click "Options" beside my post and mark it as solved. Clicking the "thumbs up" icon near the bottom of my response would also be appreciated.

  • A question about design.

    I have a program I wrote using Visual Basic that I use at my church to print a deposit slip for our weekly offerings.  A pretty simple program.  I enter the check information (giver name, check number, amount) or cash and put that data in a list
    box.  I also total the cash & check amounts to print on a deposit slip.  One aspect of the program is that I store the name and address of anyone who gives to the church and at the end of the year I print a letter giving them the total of their
    offerings throughout the year so they can deduct it on their income tax forms.  The names and address are keep in a simple access database.
    Now, I have added the capability to insert the check in a Magtek MICR check reader and using the account number on the check (which I have stored in the database in the same table that holds the names) I can get the name of the person making the contribution
    along with the check number.  Then I just enter the amount, hit enter and I'm ready for the next check.
    Here is the problem (and it's not a big one): some of our members have two or more checking accounts so I end up with two rows with duplicate information in my database.  My question is should I create another table with the account number and a key
    pointing to the member name?  I know, I've been kinda wordy for such a simple question but I really want the views of the members of this forum.
    Thanks in advance.
    Philip

    Philip,
    Just thinking out loud. How about having seperate tables for the personal info, account and contribution?? Something like below:
    Person
    PersonID, Name, Address and other personal details
    BankAccount
    Account_ID, PersonID, Branch_details etc.
    Donation:
    Donation_ID, Person_ID, Account_ID, Check_Number, Amount, Datetime etc.
    So you can have a track of all names and accounts seperately. Now for the contributions, if a person has given two checks each with different bank account, the same can be captured distinctly with the combination of Account, Check and Donation id. The Person_ID
    can be removed from the last table if we can assume that each account maps to only one person (eliminating the possibility of shared accounts)
    Thanks,
    Jay
    <If the post was helpful mark as 'Helpful' and if the post answered your query, mark as 'Answered'>

  • Question about design - use patch-panels or switches in racks?

    I'm trying to suggest should I use patch-panels in server 19" racks and use stand-alone telecomm racks for access layer switches
    OR
    should I install 2-3 access layer switches in every server rack?
    First version looks more correct, but than I have to use MUCH MORE cables, organizers etc - all of it eats place in data-center.
    Maybe someone saw some guides for that question?
    Thanks!

    2 or 3 access layer switches in every server rack? Considering typical stand-alone rack switches offer 24 or 48 ports, how many servers per rack or how big are these racks?! Or, were your intended access layer switches only 4 port switches?! (laugh)
    The main disadvantage of rack switches, you either run out of ports or have too many ports. Since server hosts often push bandwidth harder than user hosts, you also have the issue of how much aggregate bandwidth you need to move out of an individual rack. These issues are better addressed by your suggestion of using patch panels from each rack that come to a network switch rack.
    You're correct, all the cables, and their organization, has an expense, but this has to be considered against switch costs. Assuming you intend to use Enterprise switches that offer gig to the servers and perhaps 10 gig uplinks, there's a cost to having extra swiches by deploying to each rack. Also switches per rack would disallow the advantages you might find with a chassis switch in a switch rack. Further, depending on performance to provide, do you want to be limited by uplink bandwidth from each rack, or pay for high bandwidth from each rack that's usually underutilized.
    Besides "looking right", the foregoing is often why there are server rack patch panels, etc.
    One design, that I found interesting, was using the 3750 "stacked" across racks (guess you could do same with newer 2975s).

  • Copyright Question about Adobe Patterns

    I have created illustrations for a book and am using Adobe Photoshop Elements to "color in" my drawings. In addition to the patterns which came with my program, I have downloaded patterns from Adobe Exchange. How would you suggest I reference/give credit to Adobe in my publication since these patterns are under copyright protection?

    Unless you sell it as your own creation (that is the pattern template/ swatches, not the result), the usage of provided content is covered in the EULA. No need to make any extra mention of specific stuff beyond perhaps a generic © Adobe for the relevant parts. For third-party content that may be different, but you should find the relevant info from the authors there...
    Mylenium

  • Question about DAO pattern

    Greetings.
    If I'm using EJB's in my application when does DAO fits in?? I mean, it is DAO an alternative to EJB's or a complement ??
    Thanks in advance.

    DAO fits in if you are using entity beans using bean managed persistence. In this case, the DAO brokers the database calls during the EJB's lifecycle. The other instance when you would use DAO would be if you forgo entity beans altogether. In this model, stateful or stateless session beans would use DAO's to broker the database calls directly, outside of the normal entity bean lifecycle. The DAO pattern can also be used with POJO's (plain 'ole Java objects).
    The only instance where DAO would not apply is in the case of a container managed entity bean. In this case, there is no need to write a DAO, as the container will persist the bean for you.
    - Saish
    "My karma ran over your dogma." - Anon

Maybe you are looking for

  • Expanding text field in table

    Hi, I'm pretty inexperienced with Live Cycle and was hoping I could get some help using text fields within a table. I'm creating a form with a table into which the user enters information. I'd like the row height in the table to adjust to the amount

  • No audio on One-Step DVD in iDVD

    Just recently I have been tranfering VHS to mini-DV tape and then going straight to DVD using the OneStep DVD method. I have never had a problem until recently. Now when I do that, there is no audio on the final product. Any solutions out there?

  • Create Session and notify process via WS-Papi

    Hi, In the development of several examples and tutorials to learn how to "communicate" with other services, i'm finding some doubts about the session generated for the external program. This point made me ask two great doubts: 1) How can i iniciate a

  • I cant uninstall quicktime!

    hey, I am one of the many people that have been having trouble installing the latest version of itunes so I've been through all the discussion rooms and looked at different ways of trying to install. Ive been trying to uninstall quicktime so I can do

  • Declaration of Constants in classes

    Hi experts, Can we declare Constants in Abap classes as we delcare in report programming using Constants statement  and pass them ? Please let me know the procedure ? Thanks and regards, Uma.