Resumed JAVA learning that was skipped recently It seems to be stressful if you don't do what you have to do. Then talk about focusing ...
If you translate it literally, it's a boundary surface and a point of contact. I think it's an image of something that connects things at the boundary between things.
Programmatically speaking It is a mechanism that provides functions to classes that have no inheritance relationship. The difference from the class is that only constants and abstract methods can be members.
I can't use the interface as it is
At the time of class generation
implements
I have to implement the function with.
Contents of processing~~~~~
* Only constants and methods can be members
}```
## Implementation
```class a implements interface name{
public(Override with this) ~~ () {
}
}```
By the way, any number of implementations can be implemented.
Don't forget to add "," when writing continuously.
Recommended Posts