Solved

deprecated method

Posted on 2014-01-12
5
376 Views
Last Modified: 2014-01-12
I am writing a webservice client using axis 2-1.5.

client is working fine. however I have a depreciated method.  

How do I remove deprecated method ?

Please find the source code attached.
deprecation.zip
0
Comment
Question by:cofactor
  • 3
  • 2
5 Comments
 
LVL 86

Accepted Solution

by:
CEHJ earned 400 total points
Comment Utility
" Deprecated. As of 1.4 release, replaced by #attachPolicy(Policy)"

No need to zip jpgs btw. Just attach them inline

http://axis.apache.org/axis2/java/core/api/org/apache/axis2/description/PolicyInclude.html
0
 

Author Comment

by:cofactor
Comment Utility
when   I   remove  deprecated method  and replace  with this  ,....

client.getAxisService().getPolicySubject().attachPolicy(policy);


I get run time exception.
Exception in thread "main" org.apache.axis2.AxisFault: The input stream for an incoming message is null.
      at org.apache.axis2.transport.TransportUtils.createSOAPMessage(TransportUtils.java:92)


It works fine  with deprecated methods!
0
 
LVL 86

Expert Comment

by:CEHJ
Comment Utility
I can't think why that could be. If all else fails, just go back to deprecated with the annotation suggested by the error message
0
 

Author Comment

by:cofactor
Comment Utility
@CHEJ,

sorry ..I  messed up  with something else probably that time.

clean build and ran again. ... This works fine now.

Thanks
0
 
LVL 86

Expert Comment

by:CEHJ
Comment Utility
:)
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

After being asked a question last year, I went into one of my moods where I did some research and code just for the fun and learning of it all.  Subsequently, from this journey, I put together this article on "Range Searching Using Visual Basic.NET …
Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
The viewer will learn how to implement Singleton Design Pattern in Java.

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now