Interface Syntax and Use
interface SomeName { function method1 (param1:datatype,...paramn:datatype):returnType; function method2 (param1:datatype,...paramn:datatype):returnType; ... function methodn (param1:datatype,...paramn:datatype):returnType; } class SomeName implements SomeInterface { } A class can legally implement more than one interface by separating interface names with commas. class SomeName implements SomeInterface, SomeOtherInterface { }
1. | Creating Interfaces | ||
2. | Extends an interface | ||
3. | Interface Inheritance | ||
4. | Implementing an Interface | ||
5. | Implement an Interface | ||
6. | Implement interface | ||
7. | Implement two interface |