boxless mxj object
can anyone tell me if it's possible, and if so, how to create a
boxless java object (similar to class_new() in the c max api)? if
not, can I enter a feature request?
best,
r.
Couldn't you just manually construct one?
MyMXJClass x = new MyMXJClass();
Calling any methods on the thing that cause
an outlet or make any other assumptions about
it having a context in a patch may be a bad idea though.
Topher
ok, so far I've managed to create and instantiate a hidden MaxObject
and attach to it from multiple boxed objects. in my notifyDelete()
method of the boxed objects I detach from the hidden object which
seems to work fine. what isn't working so well is destroying the
hidden object when the last boxed object is deleted. any suggestions
as to how I might go about doing this? or do I have to assume that it
will live forever as some mxj internal is keeping a reference to it,
thereby preventing it from being garbage collected.
my other alternative is to call a "reset" message on it, which
reinitializes its internal state when the last object is being
deleted. then when the first new object goes to connect and expects
to create a fresh object, it just gets the old one back, but cleaned
up. does this have something to do with zap()?
best,
r.