Omar Nassar

Greenhorn
+ Follow
since Mar 25, 2013
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
2
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Omar Nassar

Thank you all, i am very glad to see all these discussions.
this is one source.
Object Reuse section, says

objects are expensive to create. Where it is reasonable to reuse the same object, you should do so.


and there is alot of sources that says the same thing. :P

I understand the reason why this happens, and I know how to solve it, but as I told you How to get benefit of object reusing.
Another points are welcome also, even if I know these points, it is good to refresh them.
7 years ago
so reusing an object applied in case there is no another reference to the object?
7 years ago
hello all,
I have red alot that says you have to reuse an object when ever you can.

I have applied this



running this code will produce this output??

Employee [id=10, name=j]
Employee [id=10, name=j]
Employee [id=10, name=j]
Employee [id=10, name=j]
Employee [id=10, name=j]
Employee [id=10, name=j]
Employee [id=10, name=j]
Employee [id=10, name=j]
Employee [id=10, name=j]
Employee [id=10, name=j]

if we moved the object creation into the for loop, it will work as expected.
how can we get benefit from reusing an object in such a case?
7 years ago
Thanks for you all
we solved the problem by using the cxf version 2.5 jar file, then we could call the soap web service from the url like it was Restful webservice.
thanks for your help.
7 years ago
Sorry for Interruption,

I searched for "envelop" and found that cxf-2.5.0 has cxf-utils.js Java script file that contain alot of functions.
maybe these functions that do the work for get requets, but how it is used with the project.
it is just added into the lib folder.
7 years ago
but that what i am facing.
cxf-beans.xml file contains jax-ws's but no one is jax-rs.
and the source does not contain any annotation for jax-rs & no java script exist just beans.
after all of that is it accessible throw browser using http get requst
7 years ago
ok I know, but we can call one of the service methods and pass it a value for parameter, like we are using rest ws

http://localhost:8080/WS/servic/method?id=123
7 years ago
I have red alot that says you can not access SOAP ws throw web browser request.
but surprisingly one of our projects can be accessed throw browser using http get request and returns a result as xml.

howwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwwww???!!!???
7 years ago
Hello,
How to call a SOAP web service as http get using apache CXF.
please note that we do not need to expose that service as RESTful service.

ex:
http://localhost:8080/hr/Employees?wsdl ------------> this will call WSDL file

http://localhost:8080/hr/Employees/getAnyThing?id=123 ------------> this will call the method with param id = 123

this is done in one of our projects but we do not know how it is done for some reason, so any ideas on that please..
7 years ago
Thanks a lot.
7 years ago
I asked this question, because we do not want to build the service 2 times depending on customer requirement.
The .Net team of our company they are building a web service one time and they can call it to retrieve WSDL file or as http request.
how can we achieve that in java.
7 years ago
any suggestion please...
7 years ago
hello,
Is there a technology or something that build a web service that allows it to work as combination between SOAP and REST?
ex: build a web service and call it as http request or as WSDL files.
thanks in advance.
7 years ago
Hi all,
In java.lang.StringBuffer doc I found that it has 4 constructors, one of them takes CharSequence and the other takes String as a reference type of the argument!!!
isn't that duplicates, because String class implements CharSequence interface???
and why did they do that??
thanks alot.