Jump to content

Official Spam Topic


Maxtor

Recommended Posts

Java question that i will spam until someone answers me :)

 

 

I have this

class Parent{

bleh bleh..

}

Interface gg{

public void example();

}

class BallsofSteel extends Parent implements gg{

public void example(){

s.o.p("actually is setekh");

}

}

class mxc{

BallsofSteel e1=new BallsofSteel();

e1.example();

}

 

And here is the shit.

BallsofSteel considers 'example()' as Parent class extend, and gives compilation error on that, since it's not existant in parent(which i obviously dont want to implement, and it's not abstract)

 

So, can i make this shitty Interface thing work first, other than casting the object( something i get 2 options to to- BallsofSteel or the Interface gg)

 

 

if you have any experience over that :) the internetz wasnt very helpful( not many examples of combining both class and interface in another class, and my specific problem.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.




×
×
  • Create New...