Win a copy of Node.js Design Patterns: Design and implement production-grade Node.js applications using proven patterns and techniques this week in the Server-Side JavaScript and NodeJS forum!

Prakash Pillai

Greenhorn
+ Follow
since Feb 17, 2002
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Prakash Pillai

Thanks James for your Valuable input,but is there any sites where i can find lots of scenario and problems ,As one of good example mentioned by you.

Yes i will look into this Design pattern Java workbook.....

Any more inputs most welcome

Thanks in Advance
I have read lots of Books on Design Patterns.Now i would like to practice the same in real world example.Does anyone know any resource or site from where we would get any Scenario and based on that we would design.

I just want to enhance my Design skills.
This Type of error normally occur when there is mismatch in complied class version.
Gurumurthy

While EJB conatiner starts it deploys ur application and at that time it runs ejbc ,which genrates the stubs and skeleton for the same.

I hope this answers your question

Prakash
Hi Alvin,
Advantage of using EJB is you need not bother about transactions,security or connecting to Legacy application.so as end progammer we need not write any logic or code for the same,all these things are taken care by EJB container.

So if ur using some tomcat server or some other servlet container and if your application needs to take care of security or heavy transaction,then u need to code for the same.which is not required in case EJB's.you need to just describe what u want in transaction in XMl file .thatz all

I hope you got difference
Meera,

I guess it is unable to find class file i.e home interface .so in your startup bat file set CLASSPATH of classes folder.and try to run again the same program.

Prakash
geeta can u give me some small code doing the same.so that it will give me clear picture
Hi All,
I would like to knw,how can i use stateful session bean across the pages,
i.e as we use setAttribute() and getAttribute(),in servlets, how can i use the stateful session bean in same way ? is it possible ?
how can i keep track of a client or user ?
Thanx in advance
Prakash
Hi Guys,
i wanted to know more about Marker interface ?
1. How marker interface work like serializable,clonnable.it doesn't have any method in it ?
2. Similarly in ejb u have interace like EnterpriseBean which is again Marker interface.
how all these work ??
19 years ago
Hi guys,
I am curious to know .
1.How Serializable interface works.As dosn't have any method to implement ?
2. Serializable s=new String("Hello");
How the above statement works or gets complied,as String is class and Serializable is interface ?
Thanx,
Prakash
19 years ago
Hi ,
I have doubt regarding the Creating of child threads.for example check out the following code.
class newthread implements Runnable
{
Thread t;
String name;
newthread (String tname)
{
name=tname;
t=new Thread(this,name);
System.out.println("New Thread :"+t);
t.start();
}
public void run()
{
try
{
for(int i=5;i> 0;i--)
{
System.out.println(name+":"+i);
Thread.sleep(1000);
}
}
catch(InterruptedException e)
{
System.out.println(name+"interrupted");
}
System.out.println(name+"exiting");

}
}

class threadinterface
{
public static void main(String args[])
{
newthread t1 = new newthread("one");
newthread t2 = new newthread("two");
newthread t3 = new newthread("three");
System.out.println("Thread one is alive "+t1.t.isAlive());
System.out.println("Thread two is alive "+t2.t.isAlive());
System.out.println("Thread three is alive "+t3.t.isAlive());
try
{
System.out.println("Waiting for threads to finish");
t1.t.join();
t2.t.join();
t3.t.join();
}
catch(InterruptedException e)
{
System.out.println("Main Thread Interrupted");
}
System.out.println("Thread one is alive "+t1.t.isAlive());
System.out.println("Thread two is alive "+t2.t.isAlive());
System.out.println("Thread three is alive "+t3.t.isAlive());

}
}
In the above code i am creating 3 child threads from main thread.Now my q are as follows
1. Can again spwan/create child thread inside child thread.something like Nested try or Nested if ?
2.In inter thread communication i have 3 methods wait(),notify()and notifyall() .Now can wake up a spcific thread from wait state to Runnable state. ?
I need ure valuable advice guys.Thanx in advance.
From,
Prakash
19 years ago
Hi ,
I need to know more about the interface espically ,Interface like enumration,it has two methods

1.hasMoreElements()
2.nextElement()
Check out the following code
Enumeration en = v.elements();
while(en.hasMoreElements())
{
Employee e = (Employee)en.nextElement();
if(e.name=="Prakash")
e.showDetails();
}
How these methods hasMoreElements()and nextElement work ? as it doesn't have the Body.

Thanking you,
Prakash
19 years ago