21 April 2016

What do you mean by encapsulation in OOP ?



  • Encapsulation is a programming mechanism that binds together code and the data it manipulates and apply restricting access to some of the object's components. 
Encapsulation


  • In an object-oriented language, it is a language construct that facilitates the bundling of data with the methods or other functions operating on that data. 
  • Class (extensible program-code-template for creating objects) is used to ensure encapsulation of data and method in Object Oriented Programming.

Intro to Java Programming, Comprehensive Version (10th Edition)
Java: How to Program, 9th Edition (Deitel)

What do you mean by Object-Oriented Programming ?


  • Object-oriented programming (OOP) is a programming paradigm based on the concept of objects which may contain data and code what will operate on the data. 
  • Object refers to a particular instance of a class where the object can be a combination of variables, functions, and data structures. 
    Object-Oriented Programming (oop)
  • In OOP the variable declared inside a Class (self defined data type like int, char, float etc is primitive type ) is called Data & the function declared inside a Class is called method. 
  • Object-oriented programming took the best ideas of structured programming and combined them with several new concepts. It is a different way of organizing a program. 
    Objects of Object-Oriented Programming
  • Example: In reality everything is object of its class like CAR is an object of CAR class. Any person is an object of Human Class, Mango is an object of Fruit class, Rose is an object of Flower class etc.
PHP Advanced and Object-Oriented Programming: Visual QuickPro Guide (3rd Edition) (Visual QuickPro Guides)

What is Java Bytecode ?


Java Bytecode
  • When a Java program source is compiled, the output of the Java compiler is called bytecode. 
  • Many language generate executable code after compilation. 
  • In Java the output is converted to a special type of file which is called the bytecode.
  • Bytecode is a highly optimized set of instructions designed to be executed by the Java run-time system,which is called the Java Virtual Machine (JVM). 
  • Bytecode makes it much easier to run a program in  a wide variety of environments because only the JVM needs to be implemented for each  platform.


Java: A Beginner's Guide, Seventh Edition

What is Java Applets and Java Servlet ?


Java Applet
  • An Java applet is a special kind of small Java program that is designed to be transmitted over the Internet and automatically executed by a Java-compatible web browser. 
  • Applet are typically used to display data provided by the server, handle user input, or provide simple functions, such as a loan calculator, that execute locally on client machine, rather than on the server.
  • An applet is downloaded on demand, without further interaction with the user. 
  • When a user clicks a link that contains an applet, the applet will be automatically downloaded and run in the browser.
    Java Applets and Java Servlet
 Java Servlet:
  • A servlet is a small program that executes on a server. 
  • Servlets dynamically extend the functionality of a web server and applets dynamically extend the functionality of a web browser. 
  • Java spanned both sides of the client/server connection with Applet and Servlet.



Java: The Complete Reference, Tenth Edition (Complete Reference Series)

20 April 2016

How Java is relates to C, C++ & C# programming language

  • Java programming language syntax come from C programming language. 
  • Java language object model is adapted from C++ programming language. 
  • Java also inherits design philosophy from C/C++.
  • Although Java was influenced by C++, it is not an enhanced version of C++
  • Java has many distinct features than C/C++.
  • Microsoft developed the C# (C- Sharp) language after few years of the creation of Java &  C# is closely related to Java.
    Java,C,  C++ & C# programming language
  • Many of C#’s features directly parallel Java. 
  • Both Java and C# share the same general C++-style syntax, support distributed programming, and utilize the same object model. 
  • There are, of course, differences between Java and C#, but the overall “look and feel” of these languages is very similar.

Java All-in-One For Dummies (For Dummies (Computers))

What is Java (programming language)

  • Java is a general-purpose,powerful and versatile computer programming language for developing software  running on mobile devices, desktop computers, and servers.
  • Java was developed by a team led by James Gosling at Sun Microsystems. 
  • Sun Microsystems was purchased by Oracle in 2010. 
  • Originally called Oak,Java was designed in 1991 for use in embedded chips in consumer electronic appliances. 
  • In 1995, renamed Java, it was redesigned for developing Web applications.
  • The Java programming language is well known for the following reason:
  • Java is Simple and easy to learn, 
  • Object oriented, 
  • Distributed,
  • Interpreted, 
  • Robust, 
  • Secure, 
  • Architecture neutral, 
  • Portable, 
  • High performance, 
  • Multi-threaded, and dynamic.
Java: A Beginner's Guide, Sixth Edition

11 October 2015

How to start & stop Apache httpd 2.4.* Web Server on linux


  • You can start & stop apache httpd version 2.4.* web server on linux using two simple linux command given bellow.
  • Step 1: Start Apache Command :
[root@webservr]#
apachectl start
  • Step 2: Stop Apache Command
[root@webservr]#
 apachectl stop
  • Step3: Its Done.
Apache HTTP Server 2.4 Reference Manual 3/3 (Volume 3)

Featured Post

How to Write PHP code and HTML code within a same file

A PHP file can have both PHP code and HTML code together. Any HTML code written outside of PHP <?php //php code here… ?> Code is ig...

Popular Posts