Not working. :(

To be more specific :

Here is my classpath (I am using eclipse)

<classpath>
<classpathentry kind="src" path="src"/>
 <classpathentry kind="con"
path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
 <classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/3"/>
<classpathentry kind="lib"
path="lib/httpcomponents-client-4.0.1/lib/apache-mime4j-0.6.jar"/>
 <classpathentry kind="lib"
path="lib/httpcomponents-client-4.0.1/lib/commons-codec-1.3.jar"/>
<classpathentry kind="lib"
path="lib/httpcomponents-client-4.0.1/lib/commons-logging-1.1.1.jar"/>
 <classpathentry kind="lib"
path="lib/httpcomponents-client-4.0.1/lib/httpclient-4.0.1.jar"/>
<classpathentry kind="lib"
path="lib/httpcomponents-client-4.0.1/lib/httpcore-4.0.1.jar"/>
 <classpathentry kind="lib"
path="lib/httpcomponents-client-4.0.1/lib/httpmime-4.0.1.jar"/>
<classpathentry kind="output" path="bin"/>
</classpath>


It says not found for following imports :

import org.apache.commons.httpclient.HttpClient;
import org.apache.commons.httpclient.methods.FileRequestEntity;
import org.apache.commons.httpclient.methods.PostMethod;
import org.apache.commons.httpclient.methods.RequestEntity;

=========================


Also, as suggested by Florent, org.apache.httpcomponents.httpclient is also
not working.


-Ajay


On Wed, Jan 6, 2010 at 6:58 PM, Florent Blondeau <[email protected]>wrote:

> hi
>
> I think org.apache.httpcomponents.httpclient are the new packages from 4.0
> version
>
> org.apache.commons.httpclient are the old ones for 3.x versions
>
> see the examples (and use IDE Autocompletion) to be sure ;-)
>
> Hope that helps
>
> florent
>
> Pingwy
> 27, rue des arčnes
> 49100 Angers
>
>
>
> Ajay Bansal a écrit :
>
>  Hi friends,
>>
>>
>> Today I was trying to use httpclient to generate some http requests.
>> However, I am not able to go past the first step itself. I am getting
>> errors
>> for following classes :
>>
>>
>> import org.apache.commons.httpclient.HttpClient;
>>
>> import org.apache.commons.httpclient.methods.FileRequestEntity;
>>
>> import org.apache.commons.httpclient.methods.PostMethod;
>>
>> import org.apache.commons.httpclient.methods.RequestEntity;
>>
>>
>>
>> It says : can not be resolved.
>>
>> I have following jar files in my classpath
>>
>>
>>
>> httpclient-4.0.1.jar
>>
>>
>> Am I missing some other jar file for above mentioned packages?
>>
>>
>> Thanks
>>
>> -Ajay
>>
>>
>>
>>
>>
>>
>


-- 

Regards,

Ajay Bansal
Expert HRM Professionals
Telfax: +91 22 40033147, Mob: +91 9029002425
[email protected], www.ehrmp.com
LinkedIn Profile : http://www.linkedin.com/in/abansal

Reply via email to