I have the following two CFCs:
component extends="Controller" displayName="foo" {
public void function minifoo() {
}
}
component extends="Foo" displayName="bar" {
public void function minibar() {
}
}
I know that any functions present in Foo.cfc will be available to Bar.cfc. But it seems that the reverse is not true. Can I make functions in Bar.cfc also available to Foo.cfc? Or does inheritance only work one way?
no, inheritance does not work that way.
Try Dependancy Injection, basically...
f = new Foo();
b = new Bar();
f.setBar(b);
b.setFoo(f);
And framework like ColdSpring or Lightwire or Wirebox can help you with that if you need.
Then they can talk to each other, but you should think HARD if that's really what you want. Maybe you would like to design them differently.