Monday, December 16, 2013

Web Services :: Bottom Up vs Top Down Web Services

Bottom Up vs Top Down Web Services

Top-down means you start with a WSDL and then create all the necessary scaffolding in Java all the way down.
Bottom-up means you start with a Java method, and generate the WSDL from it.

Tuesday, July 23, 2013

Gen :: Solve When Virus Hit My Flash and Hide My Files

What to do When Virus Hit My Flash and Hide My Files?

Try the following steps:
1. Go to Start > Run > type cmd
2. Dos will open type cd\
3. Now type the drive letter in which you want to Unhide the files lets suppose in my case its E: this will open the E: drive
4. If you want to see all hidden files and folders   type E:\>dir/ah
5. Now type attrib *. -h -s /s /d
6. Now close cmd using exit command


then move all the files you need on the flash , format it to insure all viruses are cleaned.

Sunday, June 30, 2013

Java :: How To Override toString

How To Override toString
@Override public String toString()
{
return this.get(Field you want to return); // e.g: getName();
}

Why to use this kind override?
Sometimes we need to add for example a collection to a combo box so instead of looping
 over the object list you override the toString in that object to return one of the object variables

Sunday, June 9, 2013

Java :: HotSpot

Java HotSpot

The Java HotSpot Virtual Machine is a core component of the Java SE platform. It implements the Java Virtual Machine Specification, and is delivered as a shared library in the Java Runtime Environment. As the Java bytecode execution engine, it provides Java runtime facilities, such as thread and object synchronization, on a variety of operating systems and architectures. It includes dynamic compilers that adaptively compile Java bytecodes into optimized machine instructions and efficiently manages the Java heap using garbage collectors, optimized for both low pause time and throughput. It provides data and information to profiling, monitoring and debugging tools and applications.
HotSpot is an "ergonomic" JVM. Based upon the platform configuration, it will select a compiler, Java heap configuration, and garbage collector that produce good to excellent performance for most applications. Under special circumstances, however, specific tuning may be required to get the best possible performance. The resources collected here will help the reader understand and tune the Java HotSpot Virtual Machine.

The Java HotSpot Performance Engine Architecture

Wednesday, May 1, 2013

Java :: Why Java extends only one class?


Why Java extends only one class?
From SCJP 6 study guide:
"Some languages (like C++) allow a class to extend more than one other class.
This capability is known as "multiple inheritance." The reason that Java's
creators chose not to allow multiple inheritance is that it can become quite
messy. In a nutshell, the problem is that if a class extended two other classes,
and both superclasses had, say, a doStuff() method, which version of doStuff()
would the subclass inherit? This issue can lead to a scenario known as the
"Deadly Diamond of Death," because of the shape of the class diagram that
can be created in a multiple inheritance design. The diamond is formed when
classes B and C both extend A, and both B and C inherit a method from A. If
class D extends both B and C, and both B and C have overridden the method
in A, class D has, in theory, inherited two different implementations of the
same method. Drawn as a class diagram, the shape of the four classes looks
like a diamond."


Tuesday, April 30, 2013

SQL :: Convert Integer to String

Convert Integer to String
you can convert an integer to string using the following query:

select CAST(ID as varchar2(50)) as ID_STRING from TABLE_NAME.

Have a nice day.