Posts

Interfaces and Abstraction in Java

Image
What are Interfaces and Abstraction in Java? Interfaces are used in Java to achieve abstraction. Abstraction is a critical concept in Object-Oriented Programming and refers to the level of separation between an interface in Java (which only allows you to define functionality, not implementation) and Classes in Java ( which contain the actual methods being implemented).  Abstraction is an important tool because it helps to reduce the complexity of a program and the efforts of the developer and to improve the overall security of the program. This is done by hiding complex and unnecessary code from the user. Interfaces are an important tool for software developers as Java only allows a class to extend one abstract class at a time. In order to work around this, we can use interfaces as Java allows a class to implement multiple interfaces.  Generally, an interface can be defined as a container that stores only calls to the methods to be implemented in a program.  An interface ...

Concurrency Fundamentals

Image
What is Concurrency?  This blog post aims to simply explain the meaning, function and importance of concurrent programming. Luckily, concurrency is a lot easier to understand than it's name sets out. Basically, it explains a system or program's ability to 'multi-task' ,  or at least give the impression of doing so. You see, a computer never actually does more than one task at a time but instead jumps between running pieces of each task, so quickly that it seems simultaneous. We have all used a computer for many things at once, just this morning I was sending e-mails, listening to music, writing this blog... and then some. So how does the computer manage to do all things things at seemingly the same time? By loading processes into    The two most basic units of concurrency are processes and threads.  Processes operate on the program level while threads operate on the process level. This is due to the fact that processes are themselves made up of threads.  ...