Commentary: About the interface

What is [interface]? ・ Has meanings such as boundary surface, contact point, liaison, bridge, etc. ・ The part where something comes into contact with something, or in between ・ One of the methods included in the class -Define only method types and variables -The specific processing content of the method is not described. -It is possible to describe the processing content just before using the method. -It is also possible to inherit multiple interfaces and create a new interface (it seems to be called multiple inheritance)

(Example) Interface declaration / implementation

"Declaration" → interface Interface name {}

"Implementation" → class class name implements interface name {}


What is [abstract]? ・ Abstract: means abstract -A class that has one or more abstract methods -Methods that declare only definitions (method names, arguments, etc.) -Methods that do not describe specific processing details ・ Method can be overridden

(Example) Abstract class / abstract method declaration

"Abstract class" → abstract class class name {}

"Abstract method" → abstract Return type method name (argument type argument name);

The advantage of abstract classes is

"By overriding an abstract method, it is possible to declare in advance" a method whose insertion location is not decided but will be needed in the future "at the time of implementation.

···It seems. I can only imagine softly with words, so I will make this area an issue.

Recommended Posts

Commentary: About the interface
About Java interface
About the method
[Java] About interface
About interface, java interface
About the package
About Java functional interface
About the StringBuilder class
About the asset pipeline
About the function double-java
About the ternary operator
About the length method
About the Kernel module
About the authenticate method.
About the map method
About the ancestors method
[Output] About the database
About the [ruby] operator
About the to_s method.
About the handling of Null
About specifying the JAXRS path
Output about the method Part 1
about the where method (rails)
A note about the scope
About the description of Docker-compose.yml
About the File :: Stat class
About the same and equivalent
About the Android life cycle
About the explanation about functional type
About the programming language Crystal
Consideration about the times method
Traps brought about by the default implementation of the Java 8 interface
[Java] I thought about the merits and uses of "interface"
About the behavior of ruby Hash # ==
Access the network interface in Java
About the language to be learned
About the basics of Android development
Until the interface implementation becomes lambda
[Rails] About the Punk List function
About the equals () and hashcode () methods
About the symbol <%%> in Rails erb
[Java beginner] About abstraction and interface
About the information sharing app band
interface
About the current development environment (Java 8)
A murmur about the utility class
About the role of the initialize method
Think about the 7 rules of Optional
About =
Summary about the introduction of Device
About the log level of java.util.logging.Logger
About the version of Docker's Node.js image
Guess about the 2017 Java Persistence Framework (3) Reladomo
Check once again about the OpenSSL command
What is testing? ・ About the importance of testing
About the procedure for java to work
About the new Java release model @ Seki Java (2018/07/20)
About the operation of next () and nextLine ()
About the initial display of Spring Framework
About the error message Invalid redeclaration of'***'
About the treatment of BigDecimal (with reflection)