java - anonymous class extending an abstract class -
I'm looking to schedule a task at a specified time in startTime , and when it Time comes, I want to run it on a method
rrun (boolean param 1, object oboj) .
rrun () is a method in the class, say
SomeClass .
And, within
some class , I have a method
m1 () , which it does as part of its code: / P>
Timer start timer = new timer (); StartTimer.schedule {New timer Task (public) run from zero (cry (wrong, this);}}, starttime); To do this, get me the error
Incompatible type: & lt; anonymous timer task & gt; can not be converted to some class What am I doing in Wrong?
TIA
// ============================== =
Edit:
I am using JDK8 - the latest one
anonymous anonymous Inside the square, is a reference to this current timer task , not in the unknown class, not the enclosed class.
For, this :
public zero run (crying (wrong, some class.);}
Comments
Post a Comment