Win a copy of Head First Android this week in the Android forum!

sujith Acharya

Ranch Hand
+ Follow
since Dec 25, 2006
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by sujith Acharya

I searched this in the forum, but couldn't find answer to this, so I am posting it here.

I tried to call private methods outside the class using the Reflection API. Is it not the violation of encapsulation in OOP?

9 years ago

For multi paged threads when I click on the page number provided at the top of the thread,
I get the message "Howdy Pardner, unfortunately it looks like you've come to the wrong page or
maybe we've gone and moved that critter! "

Hope it will be resolved soon.

11 years ago

Initializing_Array[] ia = new Initializing_Array[10];

You have created 10 reference of type Initializing_Array
It doesnt mean 10 objects of Initializing_Array.

So you have to create Object and assign to these refence, then only you able to set the values.


11 years ago

Here you are mapping url-pattern to two different servlet name.
11 years ago
hello Tim,

as you mentioned, j_security_check displayed in the browser..


where I might be going wrong? I have changed in server.xml of tomcat directory and web.xml of application.
Any other file I need to be changed?

11 years ago
Thanks Misha for your reply..

<Resource name="UserDatabase" auth="Container"
description="User database that can be updated and saved"

is alredy present in server.xml..

Any other hint that I need to try?
11 years ago

I am trying to introduce authentication for some restricted resource in my we application.
I have introduced <security-constraint>.... </security-constraint> for secured resource and also I configured loginForm and loginError page.

So whenever I make a request to that secured resource, it asks for login id and password.

Now my issue is, the credentials I passed in the login form is not validated. Its always saying try again even if I provide the name/password that is present in tomcat-users.xml.

In server.xml , I added this line

In tomcat-users.xml, I modified,

Could you make out, what am I missing so that even if I enter aaaa/bbbbbbbb, why its not considerd as authenticated user?

-Thanks in advance
11 years ago
when you say conn=null, then its an indication to JVM is that, the object which conn is pointing is eligible for garbage collection(provided there no other reference to that object)
11 years ago
Hi Bue,

I don't see any try block for the second catch block

that you have written
11 years ago
make sure its db2java.jar and not
11 years ago
use RequestDisptcher object to servlet/servlet or servlet/jsp communication. Use include/forward method based on your requirement
11 years ago
Go to DB2 installation path. (Eg "C:\Program Files\IBM\SQLLIB\java" if its windows). There you find Rename this to db2java.jar and use it.
11 years ago
Since you are using JSF framework, why are you going out of this framework? framework provides you the facility to seperate your business logic and navigation part. I dont think its necessary to forward the request to Servlet from a manged bean
12 years ago

12 years ago
to get the value set in the object of type ClassA, in the classes ClassB, ClassC, ClassD, you should have the reference of that object(ClassA) where the value is set , instaed of creating new objects in every class.
12 years ago