Search
 
SCRIPT & CODE EXAMPLE
 

JAVA

abstraction in java

Abstraction is nothing but the quality of dealing with ideas rather than 
events. It basically deals with hiding the internal details and showing 
the essential things to the user.
Comment

Java Abstraction

abstract class Animal {
  public abstract void animalSound();
  public void sleep() {
    System.out.println("Zzz");
  }
}
Comment

what is abstraction in java

Sometimes we may come across a situation
where we cannot provide implementation to
all the methods in a class. We want to leave the 
implementation to a class that extends it.
  In that case we declare a class
as abstract by using abstract keyword on method
signature.In my framework I have created my
PageBase class as super
class of the all page classes. 
I have collected all common elements
and functions into PageBase class and
all other page classes extent PageBase class.
By doing so, I don't have to locate very
common WebElements and it provides
reusability in my framework.
Also
1)Abstract classes cannot be instantiated
2)An abstarct classes contains abstract method,
concrete methods or both.
3)Any class which extends abstarct class must
  override all methods of abstract class
4)An abstarct class can contain either
  0 or more abstract method.   
Comment

PREVIOUS NEXT
Code Example
Java :: what are method in java 
Java :: como crear un array list en java 
Java :: Compare integers java sort 
Java :: program to check if the given date is in in the format dd/mm/yyyy java 
Java :: boolean in java 
Java :: how to use map, filter and reduce in Java 
Java :: Spigot coding how to send a message to player after commadn 
Java :: power-hungry foobar solution in java 
Java :: launch java batch 
Java :: if checkbox checked java 
Java :: java date equals other date 
Java :: java run jar with args 
Java :: abstract method declaration 
Java :: how to declare jtextfield 
Java :: Design a class ‘Complex ‘with data members for real and imaginary part. Provide default and Parameterized constructors. Write a program to perform arithmetic operations of two complex numbers. 
Java :: java.lang.NoClassDefFoundError: 
Java :: java for loop with index 
Java :: android check free space programmatically 
Java :: mobile network ip address permission android 
Java :: mvn spring boot ends when closing vm 
Java :: minecraft fabric client message 
Java :: how to install clojure on linux 
Java :: app not showing in share menu android 
Java :: what are variables in java 
Java :: netbeans android sdk location 
Java :: arc() method from the processing library 
Java :: could not load main class java 
Java :: csv compare java 
Java :: android studio json parser 
Java :: arraylist replace 
ADD CONTENT
Topic
Content
Source link
Name
4+3 =