Code: Select all
begintemplate ppspont
public pp, is_art, acell, connect_pre
create acell
objref pp
proc init() {
actemp()
}
proc actemp() {
acell pp = new MyNetStim(.5)
}
func is_art() {return 1}
proc connect_pre() {acell $o2 = new NetCon(pp, $o1)}
endtemplate ppspont
Code: Select all
{load_file("nrngui.hoc")}
{load_file("netparmpi.hoc")}
ncell=1
objref pnm, pc, nc, nil
proc parallelizer() {
pnm = new ParallelNetManager(ncell)
pc = pnm.pc
pnm.round_robin()
}
parallelizer()
pc.nhost // returns 1
objref mycell
mycell = new ppspont()
mycell.is_art() // works fine, returns 1
objref nc
mycell.connect_pre(nil, nc)
pc.cell(0, nc)
pc.gid_exists(0) // returns 1
objref thecell
thecell = pc.gid2cell(0)
thecell.is_art() // errors out with the error:
// is_art not a public member of MyNetStim
// nrniv: MyNetStim is_art