What is a UUID?

It’s an identification number that will uniquely identify something. The idea being that id number will be universally unique. Thus, no two things should have the same uuid. In fact, if you were to generate 10 trillion uuids, there would be something along the lines of a .00000006 chance of two uuids being the same.

Java Annotations

Annotations are primarily used by code that is inspecting other code. They are often used for modifying (i.e. decorating or wrapping) existing classes at run-time to change their behavior. Frameworks such as JUnit and Hibernate use annotations to minimize the amount of code you need to write yourself to use the frameworks. Oracle has a … Read more

What is the difference between Type and Class?

The following answer is from Gof book (Design Patterns) An object’s class defines how the object is implemented. The class defines object’s internal state and the implementation of its operations. In contrast, an object’s type only refers to its interface – a set of requests to which it can respond. An object can have many … Read more

What is the difference between procedural programming and functional programming? [closed]

A functional language (ideally) allows you to write a mathematical function, i.e. a function that takes n arguments and returns a value. If the program is executed, this function is logically evaluated as needed.1 A procedural language, on the other hand, performs a series of sequential steps. (There’s a way of transforming sequential logic into … Read more

What is the dependency inversion principle and why is it important?

The books Agile Software Development, Principles, Patterns, and Practices and Agile Principles, Patterns, and Practices in C# are the best resources for fully understanding the original goals and motivations behind the Dependency Inversion Principle. The article “The Dependency Inversion Principle” is also a good resource, but due to the fact that it is a condensed … Read more