Загрузка...

Object Oriented Programming Explained | Java OOP Interview Questions

#object-oriented #java #programming #oop #data #objects #howto #tutorial #class #inheritance #fundotech Object oriented programming or OOPS is a programming paradigm based on the concept of objects, class, abstraction, polymorphism, inheritance and encapsulation programming languages such as C++, Object Pascal, Java, Python uses object-oriented programming to a greater or lesser degree A feature of objects is that an object's procedures can access and often modify the data fields of the object with which they are associated. In OOP, computer programs are designed by making them out of objects that interact with one another. • Classes – the definitions for the data format and available procedures for a given type or class of object; may also contain data and procedures (known as class methods) themselves, i.e. classes contain the data members and member functions • Objects – instances of classes Object oriented programming or OOPS is a programming paradigm based on the concept of "objects", which may contain data, in the form of fields, often known as attributes; and code, in the form of procedures, often known as methods.  A feature of objects is that an object's procedures can access and often modify the data fields of the object with which they are associated. In OOP, computer programs are designed by making them out of objects that interact with one another. Objects and classes ************* Objects sometimes correspond to things found in the real world. For example, a graphics program may have objects such as "circle", "square", "menu". An online shopping system might have objects such as "shopping cart", "customer", and "product" Sometimes objects represent more abstract entities, like an object that represents an open file, or an object that provides the service of translating measurements from U.S. customary to metric. Each object is said to be an instance of a particular class (for example, an object with its name field set to "Mary" might be an instance of class Employee). Procedures in object-oriented programming are known as methods; variables are also known as fields, members, attributes, or properties. Variables - • Class variables – belong to the class as a whole; there is only one copy of each one • Instance variables or attributes – data that belongs to individual objects; every object has its own copy of each one • Member variables – refers to both the class and instance variables that are defined by a particular class • Class methods – belong to the class as a whole and have access only to class variables and inputs from the procedure call • Instance methods – belong to individual objects, and have access to instance variables for the specific object they are called on, inputs, and class variables Objects are accessed somewhat like variables with complex internal structure, and in many languages are effectively pointers, serving as actual references to a single instance of said object in memory within a heap or stack. They provide a layer of abstraction which can be used to separate internal from external code. External code can use an object by calling a specific instance method with a certain set of input parameters, read an instance variable, or write to an instance variable. Objects are created by calling a special type of method in the class known as a constructor. A program may create many instances of the same class as it runs, which operate independently. This is an easy way for the same procedures to be used on different sets of data. Object-oriented programming that uses classes is sometimes called class-based programming, while prototype-based programming does not typically use classes. As a result, a significantly different yet analogous terminology is used to define the concepts of object and instance. In some languages classes and objects can be composed using other concepts like traits and mixing. —————————— Like, Share, Support, Subscribe ?? ————————— ✔ FUNDOTECH - https://www.youtube.com/channel/UC20UQGc_nSoen6lCRMpLQYA ✔ FACEBOOK - https://www.facebook.com/JagrukIndian ✔ TWITTER - https://twitter.com/kunal_saxena ✔ INSTAGRAM - https://www.instagram.com/thejagrukindian/ ✔ LINKEDIN - https://www.linkedin.com/in/kunalsaxena/ ✔ TECHIE KUNAL BLOG - https://techiekunal.blogspot.com —————————— Recommended Playlist —————————— AWS https://www.youtube.com/playlist?list=PL6xaYiRPflAvO7Y1wfQRQnuY2_1gRX9dU Java https://www.youtube.com/playlist?list=PL6xaYiRPflAsw3knfUY4iajm5bTlDUixs How Tos https://www.youtube.com/playlist?list=PL6xaYiRPflAvHf4KE8g-41TT0g2hxy1tp Design Pattern https://www.youtube.com/playlist?list=PL6xaYiRPflAuUS5tXZdS-b2eazy5JkV48

Видео Object Oriented Programming Explained | Java OOP Interview Questions автора Java для Начинающих
Страницу в закладки Мои закладки
Все заметки Новая заметка Страницу в заметки