As per my understanding, if you want only some methods as unimplemented to define them in child classes as required, but need remaining of them to be implemented as they are in the parent class
Only the inheriting classes have those variables (k,l in Demo, x,y in Demo1). So those variables can be intialised only in those classes using the constructor. If you are asking why initialise in different places and just initialise everything inside the constructor of a single class? Well that is just a Design principle to avoid redundant code. For example: You could create a Abstract class for a Vehicle with params tireCount,seatsCount. The abstract class can be inherited by any type of Vehicle now. Like Car,Bike,Truck etc. and you don't need to add tireCount,seatsCount in every single class which avoids redundant code.
Hi Jyotshna, I have already added lambda concept to my recording schedule.. They will be published soon.. Thank you for the feedback,glad to know that you found these videos helpful.
Videos are nice, but please put only one ads.. In this video i got 3 times ads and in single time i am getting two ads so totally 6 ads for 12 min video....
Beacuse In abstract class, you can define as well as delcare many method. Now if you are not sure about some method implementation then you will ask other class to implement it own their own. Basically when there is need of partial implementation then you should go for abstract class. Yes you cant create Object. But you can extend this class to some other one and create object of that class.
This was very direct and easy to understand for me. I feel a lot better about abstract class constructors now. Thanks!
Thanks for the kind words 😊
thanks bro, i am come here for understand how to call constructor on abstract class, but i got many more.
Thank you for the clarification of the use of the term "super".It has always been a mystery to me.
Thanks abhilash.. You are explaining clearly 👏
Thank you, this was a very foggy topic for me appreciate the explanation!
sir, Please try to include some examples where these concepts are used in real applications.
Very nice tutorials...Too bad you do not have more of them.
Expained well with a simple example. Good video. Should do more videos👏
Can you please make a video on reflection class in java?
very Good
Simply extraordinary explains... Upload more videos...
Thanks, Bharat.
Super teaching sir plz upload all the java concepts sir
Felt very happy by seeing this.
Now I have a clear understanding about this. Many thanks to you :)
You are welcome, Hemanth.
Have a good time!!
Your channel name is Selenium express
But I didn’t find any selenium videos here 🧐
But your java videos are awesome 👏
prasad sardesai ha ha.. Thanks..
I always wait for your videos. Keep up the good work. 😀
Great
superb
Sir one correction .... Bydefault all the variables inside abstract class is static ...but u said non static..clear my doubt
Nice videos...
Superb explanation bro
very nice explanation ,thanks bro
What is the purpose of having variables inside abstract class. This creates the problem in extending classes. Correct me if I am wrong?
As per my understanding, if you want only some methods as unimplemented to define them in child classes as required, but need remaining of them to be implemented as they are in the parent class
Wow super
Nice one, keep it up
Thanks for the explanation !
But , why cant you initialize all the 6 variables in the abstract constructor though?
Only the inheriting classes have those variables (k,l in Demo, x,y in Demo1). So those variables can be intialised only in those classes using the constructor.
If you are asking why initialise in different places and just initialise everything inside the constructor of a single class?
Well that is just a Design principle to avoid redundant code.
For example:
You could create a Abstract class for a Vehicle with params tireCount,seatsCount. The abstract class can be inherited by any type of Vehicle now. Like Car,Bike,Truck etc. and you don't need to add tireCount,seatsCount in every single class which avoids redundant code.
Hi, Can you please explain on top of selenium web driver, how to create web driver instance using a constructor for every page?
Hi Avi, can you please upload videos on lamda expression ?? I am following your videos which are awesome and easy to understand .
Hi Jyotshna,
I have already added lambda concept to my recording schedule.. They will be published soon..
Thank you for the feedback,glad to know that you found these videos helpful.
@@SeleniumExpress still waiting those series bro.... lamda and streams api
Nice Explanation bro...
omg nice question and answer
What is the real time use of this concept?
Videos are nice, but please put only one ads.. In this video i got 3 times ads and in single time i am getting two ads so totally 6 ads for 12 min video....
you are amazing
very good explained! i wish my college instructor could explain things like this, he sucks!
Sir we are not able creating object of abstract class then what is purpose of abstract class.
Beacuse In abstract class, you can define as well as delcare many method. Now if you are not sure about some method implementation then you will ask other class to implement it own their own. Basically when there is need of partial implementation then you should go for abstract class. Yes you cant create Object. But you can extend this class to some other one and create object of that class.
Only one thing i want to tell you ..keep in your mind..once a bihari s alwYs a bihari...