Recent update: 2008-5-9

Singleton pattern over Factory pattern

417 byte By ckollareddy at 2008-2-1
HiWhat is the difference between the Factory and Singleton pattern.Can we use a singleton (pattern) class to create other object instances and return them.What are the advantages and disadvantages for using the Singleton pattern here.Or do we have to use only a factory (pattern) class to do the ...

Can JDO replace Entity beans.

193 byte By selkumarm at 2008-1-21
I feel that while designing a J2EE application, using the Java Data Objects alongwith Entity beans is somewhat redundant. Is it so or there is any reason behind this architecture?

Cannot find PortableRemoteObject

1133 byte By factor3 at 2008-1-10
Greetings:I am attempting to compile an EJB test client using the Sun tools. I am running on a Red Hat Linux environment. My classpath is as follows:CLASSPATH=/home/work/research/jdk1.3.1_01and I am attempting to do the compile using compile.sh, which contains the following ...

FrontController Apache / Tomcat

2548 byte By stockmry at 2007-12-22
I'm trying to implement the FrontController design pattern from Sun. But we keep on running into problems when we port the application to apache/Tomcat structure. It works fine in a tomcat stand alone. De context is initialised and the servlet is found using the url pattern, however when we ...

System guide

708 byte By hellosamhia at 2007-11-27
Hi experts,I have been programming in Java for a while but I'm relative new to system design. I was asked to write a web-based system to manage student information (such as marking their test result, generate reports based on the marks).In the end, I would like it to be able to use by multiple ...

OOD Gems

862 byte By Gargoylea at 2007-11-24
Like the title of this thread the brevity and value of experienced design advice often helps to navigate the volume of material available.I have found this particularly true with Java when reading all the methods of a new object may not be the best use of precious developer time if there are ...

Separation of tiers

425 byte By pmohanana at 2007-11-14
Hi...,In one of our application, we are thinking to separate the Web Layer(Jsp/JSF) & deploy it on the Web Server , EJB's on the App Server. My question is ,-what benefits does it provide having such separation?-When should we decide to separate the web tier from the application server?- ...

Performance Issues with Validation Framework

438 byte By irshad007a at 2007-11-14
I am planning to use Validation Framework in my project (non-struts based ) for the form validations. But I am not too sure about the performance issues I am gonna face bcoz of this. Since its a banking application so any response beyond half a second would not be bearable.Please share ur ideas ...

design pattern: facade for delete?

1069 byte By xianwinwina at 2007-9-25
Hi guys,I have the following info (db):department (dep_id, name, description)empl(empl_id, dep_id, name)invoice (inv_id, dep_id, description)....question is this: say I would like to delete the department (which include the empl as well). What is the best way to do that?obviously, I can do ...

Where does business logic go?

1524 byte By fedetxfa at 2007-9-25
We have a telephone ticket pricing application. We designed an object model and we have objects that have logic to decide how to price each ticket according to its characteristics and information from a database.The customer wants to remove all the logic from the application and build up the ...

DAO pattern and Java Persistence API

1145 byte By jusia at 2007-9-25
HiThis is a question for anyone who might be familiar with the standard DAO design pattern and the Java Persistence API (JPA - part of EJB3). I'm new to this technology, so apologies for any terminology aberrations.I am developing the overall architecture for an enterprise system. I intend to ...

Scheduling application

1314 byte By serezhaa at 2007-9-25
I need help on design in class scheduling application for my university. The data is taken from xml file which is a database transformation to xml. My classes reflect xml file:Instructor, Course, Department, Room, Semester, Schedule.Schedule is an entity that has instructor, course, room, ...

Psuedo Singleton, or other options?

949 byte By guitar_man_Fa at 2007-9-24
I am working on a project in which I am going to need to reuse a lot of the functionality of some existing singletons in the code base of my company's application.There are ligitimate reasons for these objects to be singletons (i.e. they store data that I only want stored once, etc). But, in ...

MVC and chess game design

483 byte By Galaxya at 2007-9-24
Hi,I am trying to do a chess game using mvc. The view obviously should handle all the drawing stuff and the model the logic, which means in mvc I have to have a pawn concrete class (model) and a pawnviewer class (view)?If that is the case is there a better solution than to check for the chess ...

Shall I use Value Objects?

340 byte By Kavansa at 2007-9-24
Hi,I am creating a web app with approx 25 web pages with not much business logic.I plan to use struts framework.What I wanted to know was, shall I use value object pattern for my web page? Is there some kind of questionaire which I can take to decide whether I should use VO or ...

OO design is provoking

3849 byte By alta at 2007-9-24
Hello,I want to build a good website rapidly that is easy to add new features. I want to program my site in a platform-independant programming language so it can be ported to different platforms easily.One suggestion is to program the interface using XSLT. There are XSLT compilers that ...

System scalability issue

813 byte By amit230978a at 2007-9-24
Hi,We are in the process of developing one application which will be used to upload several feed files (Excel and CSV format). These files will be processed at the application server side using POI (to read excel format) and than after certain processing, it will be stored in the staging tables ...

Sorting and filtering design question

2202 byte By oturcoa at 2007-9-24
Hi All,I have several list of POJO classes like;public class Person{private String name;private String surname;private int no=0;public String getName(){return name;}public void setName(String name){this.name = name;}public int getNo(){return no;}public void setNo(int no){this.no = no;}public ...

Systems Analysis

266 byte By nantucketa at 2007-9-24
I'd like to learn more about systems analysis. What is systems analysis... Are there any good books or links one would recommend I look at.. I'm interested in it as it applies to the process of software development of course. Thanks for any feedback.

Using Service Locator in Struts app without ant eejb components

482 byte By Ottrana at 2007-9-24
HiWe are developing a Struts application witjout any EJB components.But we may go for EJB in future.Keeping that in mind we want to introduce a service locator between the action class and the business logic. So it may be easier to acomodate in future.But how do i do that ? Can anyone help me ...

Breeder Pattern in java

68 byte By Bulla at 2007-9-24
Can anyone please give info about this design pattern in java

puzzle about prototype pattern

535 byte By dxuranusa at 2007-9-24
is prototype just use clone substitute the "new" operation? but client must know about manager and concrete products and initial manager with products he or she wants,so what's use of this manager and clone-- if client want to get product, he or she must "new" it and then clone it .in my view ...

Aggregation and composition in UML 2.0

498 byte By devesaa at 2007-9-24
Hi,a) I've been told that aggregation and composition do not exist in UML 2.0. Is it true? Then how are these relations written?b) We have UC 1 and UC 2. They include UC 3 (abstract). Then in UC 3 sequence diagrams, the start message wouldn't be from an actor, but from an Object. Is it ...

Design Guestion

634 byte By haroldclementsa at 2007-9-24
Hello,I have a design question; I am not too sure if I am going against the whole principle of OO but here is my question.I have a main window that calls two different classes, one is a load of JSlider and the other that has a JTextPane. Now if I make an adjustment to the slider how do I get ...

Question about MVC

1544 byte By zpyounga at 2007-9-24
I have been working for the past couple of days on a project. I have been researching and studying different methods for developing my project. This project is a very simple order entry system. From my research I have discovered many new terms and concepts that have really got me confused. ...

Signle Sign On in a normal client server environment

1964 byte By JSTigera at 2007-9-24
We are designing a client server system, and we are running into a single sign on problem.Basically, a client's requests are served by many sockets, although the client doesn't know its requests are served by multiple sockets. For every socket, the user identity has to be authenticated via ...

Good example of a "well-designed" Swing application ?

827 byte By lelasseuxa at 2007-9-23
Hi all,I'd like to find an application which is recognized to have a stable and well-designed UI architecture (I mean the software architecture, not the visual appearance). My goal is to analyze it and use it as a "model" to check my own application.My main concern being the software ...

Can anyone suggest a good pattern in this scenario ?

2164 byte By mels_29a at 2007-9-23
Hi, I am in to developing a browser based enterprise application supposed to be used by a group of users over 'intranet'. We have though of using following: - Web Tier: Struts & JSF Framework, JSP, EL- Business Tier: EJB Components using EJB 2.0- Database: SQL Server 2000- Application ...

DAO Stratergy

2447 byte By kmathewma at 2007-9-23
We have 3 Bussiness objects say BUSOBJ1, BUSOBJ2,BUSOBJ3,each has different methods calls andeach bussiness objects gets data from different database say DB1,DB2,DB3, Now if i want to design/implment a DAO pattern , How do i go about designing the DAO classes,Below is my current ...

how to set role based Authorization in JAAS

137 byte By arunagirinathana at 2007-9-23
how to set role based Authorization in JAAS i had user name , password and role in FileLogin thanks arun .v.

Rule Based System

283 byte By RashmiKant_ at 2007-9-22
Hi all,I am currently working on a project which required to Implemented 500-600 rules in the System. Some of them are global Rules and some are just module level rules. Is there any pattern exist for Rule Based System? Thanks in AdvanceRashmikant

Singleton Design Pattern

253 byte By ThinkMan at 2007-9-22
Hi all,I want to apply Singleton Design Pattern into my application.And I am confuse about multithreading in its application.Is it a "must" to synchronized all public methods on that Singleton class?thanksdaniel

Queue delay or denied service

646 byte By Rafael_M at 2007-9-22
We have the following problem.Our system needs to asign resources on a FIFO manner with only one exception. A reasignation could be triggered and takes priority over every other request. So any following requests that come through the standard inputs need to be denied. The reasignation could ...

doctors surgery scenario

921 byte By lwckenny at 2007-9-22
hi!I'm new anda i want to know if anyaone can help me? i need to do a program about a doctor surgery patient record (the name and address of each patient, their first choice doctor, a list of each visit to the surgery (with date) a list of each outcall, any drug prescribed)doctor record( name ...

Observable producing late notification to Observer

1148 byte By rajib_cal at 2007-9-22
Hi!We're working with an asynchronous JMS/MDB messageing scenario. And the requirement is to match the responses to respective requestsThe participating classes in a nutshell are- Communique (Contain request message, response message) Observable- CommuniqueMap (contain messageUID for request, ...

database class design problem

2884 byte By tnguyen1973 at 2007-9-22
I have an application that access severals different databases (not at the same time) class Database{public void connect(String url, String drivername, boolean autoCommit) throws Exception;public void disconnect();public boolean isOpen();public void closeResource(ResultSet res);public void ...

HashCode and Inconsistency between program runs

971 byte By mertero at 2007-9-22
Hi Guys.I'm having this problem. We have a large project in java (It is a compiler). It involves lot's & lot's of HashSets and HashMaps. Our problem is that Java's Object implementation of hashCode is by the address it gets.This means that on different runs, the hashCodes are different, ...

Drag and drop panel

1940 byte By edeca at 2007-9-22
I plan on writing a "drag and drop" interface that lets a user place things on a "canvas" and move them around. I will then let the user connect them with lines. Such things could be nodes in a network, one of the ideas I've had for using it. Basically this will allow visualization of whatever ...

Doubt in Value Object Designing Pattern

473 byte By amateca at 2007-9-21
Hi all,I have a little doubt about getting a mid-term on defining VO's. Suppose we have an EmployeeVO with about 50 atributes. This Object appears in many, many views of the application and in each of them it shows a different subset of attributes. Wonder which would be better: always send the ...

erroe while configering jbuilder for Oracle9iAS

1559 byte By kiranchandra1a at 2007-9-21
hi,when i configured and tried to run a jsp client for my ejb,i am getting the following error.could anybody give some clue.I configured the oracle 9iAs 9.0.2 to my jbuilder9 and i am running the server from there.error: Invalid class file format in ...

a question of code design

1317 byte By Maurice_Ta at 2007-9-21
many times i stumble over a problem, concerning the desing of my code.i think i can describe the situation best on a game-example. imaging i have a manager class for may game, which holds all of my game objects (space ships, landscape, what the heck) and schedules them for animation etc.the ...

Java patterns

221 byte By oopsjunka at 2007-9-21
Hi,I am just starting to learn design patterns in java, I have bought a book 'applied java patterns', since the book is from 'sun microsystems press', I wanted start this thread and get your expert help.

Singleton question

876 byte By tuffythecata at 2007-9-21
Hi everyone :)I have implemented a singleton pattern on one of my classes. I have two applications, each of which run independently of each other but require access to the same (single) instance of my object.When I start my first application it successfully creates the singleton object (which ...

InitialContext.lookup NamingException

652 byte By jlkiveya at 2007-9-21
Hello all,I am running weblogic 6.1 and I have an intermittent problem. After running the server for 1 to 3 hours with a small number of users hitting it, the following code block starts throwing a NamingException (see code below). What is unusual is that this code performs properly for a while ...

UML for a graphic interface

270 byte By lguillemaina at 2007-9-21
Hi,I want to create a graphic interface (with Swing, JDBC connection etc).Does someone know where I can find documentation for the structure of this kind of application (UML, type of classes, data structure ....)Thanx in advanceRegards

Why WEB services?

5217 byte By valjoka at 2007-9-21
Hello, I'm starting learning Struts. I have some experience creating WEB sites basing on 3-tier architecture. Until recently, I considered database and web server components as a high level objects that need some talioration to achieve the goal of building a web site. Yes, I always looked for ...

How to return Multiple Values Objects

398 byte By rnatsa at 2007-9-20
Hi! I have a handler which perform queries against two databases. It sets them in to two Value Objects of type 'List' - ListA and ListB. I want to return these to my jsp page and process them in my jsp page. How can I do this. I am using MVC pattern - A jsp web form talking to Controller ...

client data buffer

377 byte By spring111000a at 2007-9-20
I want to use a data buffer in a Browser(for example:Internet Explorer),when a http connection is disconnected I can operate on the data buffered(Perhaps in XML format),for example,I can query,sort or modify the data buffered,afterthat I can update the data source truly,just like in a C/S model ...

Entity beans and Database tables relationship

456 byte By JagBainsa at 2007-9-20
Hi,I'm new to j2EE as you may cater from the question.The question is, should Entity beans and Database tables be a 1 to 1 relationship i.e. for each database table there should be an entity bean?I don't think this should be the case, but if it is, then isn't there a case that we may end up ...

Can anyone tell me the class diagrams of a simple java notepad

154 byte By moazzamfna at 2007-9-20
hi,Can anyone tell me the class diagrams of a simple java notepad.i'm a very beginner in UML.thanks in advance.Moazzam