The compiler sees an object of type Interface which does not support the
method you are trying to call. Either use:
var tmp:ConcreteClass = new ConcreteClass();
or
var tmp:Interface = new ConcreteClass();
ConcreteClass(tmp).bar();
grtz
JC
On 6/14/06, Mark Lapasa <[EMAIL PROTECTED]> wrote:
//
Hello :)
you must use "Transtype" if you use a method defined in your class but not
in the interface :)
[code]
import ConcreteClass;
import Interface;
var tmp:Interface = new ConcreteClass();
tmp.foo(); // Works
ConcreteClass(tmp).bar(); // Works with methods not implemented in
interface.
[
///
// Inside "Interface.as" //
///
interface Interface
{
public function foo():Void;
}
///
// Inside "ConcreteClass.as" //
///
import Interface;
class ConcreteClass implements Interf
3 matches
Mail list logo