OOPS CONCEPTS - JAVA PROGRAMMING

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Music] hello friends welcome back to our channel so in the previous session we have seen the Java buzzwords so that we call it as a features in this session let us have a look on the whoops concepts so what are the hopes concepts object gas affection and cancellation inheritance polymorphism so this we call as oops concepts now let us see one by one first what is meant by object so an object is defined as a real-world entity so whatever the thing we are seeing in the real world that can be treated as an object so this object is a real good entity and this object consists of so properties and the tasks performed by us perform by this object so whatever the real world entity which is having these properties in the past some tasks to be performed those we call as an object let us take an example human human being is also an entity and it's an also an object so human consists of properties like name the color height and etc so these are the properties so what is lumen can do task one of the past can be done by this would be one the right exactly so these are the tasks can be performed by this human so we can consider this human as it object hope you understood so object is a real world entity which is having the properties and some tasks that get that it can be performed right no what about the class s is a group that objects object follows the object follows so it is a blueprint that an object follows so without the class object is not there so this class consists of L number of objects number of objects consists of number of objects and the object can be defined as instance of a class instance of a class so the base object will follow the prototype defined by this class example let us take a student student in a class student in a classroom so what are the properties so properties all variables you can say them as so properties of the student 1 screen name to get Holdenville and student date of drawing they'd of joy right so this is a gas and all the objects which are defined by this gas should follow this prototype so that for example a student in a class there are n number of students every student can be considered as an object which follows the same for prepare and one of the hostage to be performed by the student read write play right so every student can have three properties rail right in play every student will be having the three company's name roll number and some date of joy so whatever the objects created through this class will follow the same structure but face objects so student consists of a number of objects so student class comes yourself some ABC the name of a student here we see some deal some change so ABC will be having name whole number date of joining name whole temple gate of joy similarly GHI so here the abcdefgh a of the mains name of a student let it be like something sandy and some fish roe remember and they don't work and for every student will follow some properties some rain write and play so these three properties can be done I mean invoked by this legacy and this properties can be applied for BEF and this properties can be done by GHI so I am object is an instance of a class and a class is a blueprint that the object shoof all right so I can consists of n number of objects many number of objects hope you ever saw this object in class because our channel programming completely deals with these two things tasin object for everything we will create a chasm we will create an object so a casts cannot crisis the methods of another gas directly so one can methods cannot be invoked by the another another gas so in order to access the methods of another class one can should create its own object so simply we can say a classes cannot communicate with each other but in order to communicate with each other objects should be read so for every communication objects should be created so if Cassie and Kashmir wants to communicate so here the communication means invoking the methods of one class by another gas so every class is having the methods right so tasks so invoking those methods or tasks from one class to another class is called a communication and this cannot be done between two classes and this can be done only between objects so in order to communicate two classes first the instances should be generated and through those instances though the two classes will be communicated so hope you understood this thing the castle object next abstraction a fraction means showing only essential parts only essential parts and hiding the implementation details this is called abstraction this can be achieved in this Java programming just the best example so if you download an Android application from the Play Store so we mitigated dot the apk file right not apk file or you can download a software so that we can get gone exe file and if you run this exe file we can get the software and we can use the software but here we can't see the packages or our methods or a functions which are used to create this exe file that means all the implementation part is hide you and only the essential part is visible right so this is the best example so similarly if you download an application from Android Play Store you will hear a dot etheta file but you will not get the method sort of packages or any functions which I have written to generate this dot apk file so all the implementation details will be hidden right so this type of applications can be done in Java programming that we call it as an abstraction or a data hiding I hope you understood this abstraction next one so object class instruction now and capsulation encapsulation so this means binding variables and the methods under single entity binding the variables and methods under single entity so see for it understanding will write here so class is having three parts what is the name of a class so this is a case here we will write the variables and here we will write the methods similarly object is also having the name variables and methods sim simply we can say student is a class having the variables name whole number and a date of joining and the methods read/write okay thanks so this is a cache so here we are writing the variables and these are all variables and this we call as methods right these are core variables these are core methods so here we are binding these variables and methods in a single entity we call it as class or object so object is also having the same structure that means one class will be having in whole number character name and similarly the real method right method so one cast consists of variables and the methods right so this is called encapsulation so hope you understood this one next travel to the next concept in radians inheritance so what is between Higgins acquiring the properties of one class to another class acquiring the properties of one class to another class simply with let's say it does parent class and it changes so chain casts will acquire the properties of parent class right changes will be having acquiring the properties of painting class so this week on it has this class or we can call it this change has will be called as day right so an herbal class is a class which is there are from the base class there are yes or you can call this parent as superclass and this change classes sometimes right so acquiring the properties of one cast to another dress so here acquiring the properties of parent class to the changes so this this concept we call it as inheritance so here there are different types of inheritance right so we will have a single inheritance multi-level in evidence hi lyrical ingredients so let us see the basic interaction then we will move on by one by one right so we will see one by one concept in the depth now in this session let us cover the interaction of all these object-oriented concepts so we can have these three types of in hidden single multi-level and character so this is called inheritance concept next coming to the polymorphism so performing the same tasks same task in different ways in different ways that is called as a polymorphism here tasks means a method method so in working the metal in different ways for example if we are having a program or addict of two numbers we can write and simply we can call ahead without any parameters we can call ad with into a comma in to be right so two methods so both will perform the same task but implementation is different here we are not passing any arguments and here we are passing only I mean two arguments right then this type of implementation we call it as a polymer let it be one more example I will explain so I am having the method called drop polygon drop polygon so this drop one hand can be anyone so we can draw circle as I say it's a polygon so we can draw square we can draw rectangle we can draw a triangle right so both all the three are the polygons all the three are polygons so here just I am implementing properly done and that drop polygon can be square rectangular finding that means implementing this task in different ways this is called polymorphism so this can be achieved in Java by eg by every building method overloading method right and method overriding so the conversations we'll see what what is meant by this method overloading and methylome right so with this we can implement thump I thanked by polymorphism and with this one-time polymerase so we can achieve the compiled them our polymorphism by implementing method overloading and we can achieve this runtime polymorphism by implementing method overriding okay so we will see one by one in the further sessions hope you understood the basic concept of this polymorphism right so these are the concepts of object-oriented programming so object casts abstraction encapsulation inheritance and polymorphism so if you are having any doubts regarding this oops concepts feel free to post your thoughts in the comment section so that I will definitely try to clarify all your doubts and if you really understood my sessions share my sessions with your friends and like my sessions and don't forget to subscribe to our Channel thanks for listening thank you very much
Info
Channel: Sundeep Saradhi Kanthety
Views: 1,130,312
Rating: undefined out of 5
Keywords: sundeep, saradhi, kanthety, java programming, java basics, java fundamentals, beginners, programming fundamentals, java faq, jdk, jre, jvm, java introduction, source code, object oriented, oops, oop concepts, set classpath, abstraction, inheritance, polymorphism, encapsulation, class, object, secure, virtual machine, java compiler, platform independent, portable, robust, multithreading, method overloading, method overriding, strong typed, javac, class file, os dependent, oops example
Id: -HafzawNlUo
Channel Id: undefined
Length: 20min 24sec (1224 seconds)
Published: Wed Dec 05 2018
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.