Questions tagged [implements]

`implements` is a keyword in several programming languages used to denote implementation of an interface.

implements is a keyword in several programming languages which support OOP (such as Java or PHP) used to denote interface implementation (as opposed to extends used to denote implementation inheritance).

Related

404 questions
0
votes
1 answer

How make a generic type in java?

I want make my List. But I dont know how to write generic type in java. public interface myListInt >{} public class myList> extends LinkedList{} When I am doing that, it gives an error.How should ı…
o_O
  • 51
  • 7
0
votes
1 answer

setResult not working in a java class implementing onClickListener

In my project I have some buttons, with their own View.OnClickListener. What I want is to "externalize" all this onClickListener into a java calss that implements the interface, and handle all the click events, here. But I found a problem, that I…
Shudy
  • 7,806
  • 19
  • 63
  • 98
0
votes
1 answer

How do i declare button on Click listen in a fragment to switch to an activity?

I tried but i am getting errors "Onclick listener can't be applied here" Please help me guys Here is my Fragment.java public class Fragment extends Fragment { public Fragment() { // Required empty public constructor } …
0
votes
1 answer

Motorola EMDK implements DataListener crash | Android Studio

I want to implement the DataListener from the Motorola EMDK to my class. If I implement the DataListener my App crashes. My android Manifest looks like this:
juli0n_
  • 81
  • 2
  • 7
0
votes
1 answer

implements TopSectionFragment Cannot resolve symbol android studio

public class MainActivity extends AppCompatActivity implements TopSectionFragment.TopSectionListener { When I try to implement the TopSectionFragment the writing goes red and, then it says Cannot resolve symbol when my mouse goes over it. This…
Dan Hunter
  • 1
  • 1
  • 1
0
votes
1 answer

Class implements Interface that extends another Interface

I want to implement an interface in my class that extends from another interface, but I get the follow error: Class1 is not abstract and does not override abstract method method2(param1,param2) in Interface2 public class Class1 implements…
0
votes
2 answers

Java Interface Implement

I am studying Java, Spring and POI. I see https://poi.apache.org/spreadsheet/quick-guide.html and follow it. At "New WorkBook", next code exists. Workbook wb = new XSSFWorkbook(); FileOutputStream fileOut = new…
blank_popup
  • 261
  • 1
  • 2
  • 13
0
votes
1 answer

comparable interface separated sorting for instances

The procedure: 1) I want to show all bus first, and then taxi. 2) Then i would like to sort all bus or taxi by model ,brand, price by alphabetical order or ascending order. Question: 1) How can i show the bus records first and taxi records behind.…
Kindess
  • 49
  • 6
0
votes
3 answers

java call method from parent on object from implemented class

I am sure that this is an easy one. I have a java class called vInteger, which extends the class Integer (containing only int value, constructor, getter) and implements class Comparing. That one has an abstract method compare(Comparing obj); and I…
Applecow
  • 796
  • 3
  • 13
  • 35
0
votes
0 answers

Java set Data to implemented interface

How can I fill my implemented interface width the Object it brings width. public class MegaPlayer implements Player{ public MegaPlayer(Player player){ (?here do I need help?) = player; I like to set the data for the object Player width one…
Noel Schenk
  • 724
  • 1
  • 8
  • 19
0
votes
1 answer

AppWarp Implementation

I am trying to implement AppWarp into a game I am making. I followed a tutorial exactly as it was written but I am getting about a dozen errors at "NetworkPeer implements". Some of the errors are: Error: Interface method onConnectDone in namespace…
0
votes
2 answers

Cannot Implement or extend - java

I have a class C with lots of members(say 10 members) + members that are only in C I have two more classes A and B which has exactly those above mentioned 10 members. (A and B each does not have those 10 members. Those 10 members are distributed…
Exuberant
  • 189
  • 2
  • 13
0
votes
1 answer

Spring MVC: how to implement DAO from custom interface

My purpose is to implement custom DAO interface and that's what I do, but it seems does not work. My interface is: public interface AbstractDAO { void add(T object); T load(Integer ID); List list(); void update(T object); …
WildDev
  • 2,250
  • 5
  • 35
  • 67
0
votes
1 answer

golang exception to rule "interface pointer can't implement interface"

In golang.org's official FAQ, under pointers there is this quote: "The insight is that although a pointer to a concrete type can satisfy an interface, with one exception a pointer to an interface can never satisfy an interface" Out of curiosity,…
Javier Zunzunegui
  • 363
  • 1
  • 3
  • 10
0
votes
1 answer

Song Class, Using abstract class and interface

What I'am trying to do with this program is output the information of a song using the toString on Song class. When I output it, everything is fine except the SongType/genre. It is still outputting UNDETERMINED. abstract class Song implements…