func init // adds using namespace sys.add_use('System.Security.Principal') // initialize instance params = this.props('Constructor').value if(params == 'Constructor') params = '' elseif(params == 'Constructor2') params = '' + sys.get_typed_field(0, 'Capacity', 1) end sys.add_object(this.codename, 'IdentityReferenceCollection', params) // makes implementation methods for properties sys._prop_init('Count', 1, 0, 1) sys._prop_init('IsReadOnly', 1, 0, 104) // makes implementation of methods as properties sys._mtd_as_prop_init('GetEnumerator()') sys._mtd_as_prop_init('IdentityReferenceCollection') // makes implementation of simple methods sys._method_init('Clear') end func doConstructor() blk.println(this.codename, ' = new IdentityReferenceCollection();') end func doConstructor2(data) blk.println(this.codename, ' = new IdentityReferenceCollection(', d("capacity"), ');') end func doAdd(data) blk.println(this.codename, '.Add(', d("Identity"), ');') end func doContains(data) if(linked("onContains")) event("onContains", this.codename + '.Contains(' + d("Identity") + ')') else blk.println(this.codename, '.Contains(', d("Identity"), ');') end end func doCopyTo(data) blk.println(this.codename, '.CopyTo(', d("array"), ', ', d("offset"), ');') end func doRemove(data) if(linked("onRemove")) event("onRemove", this.codename + '.Remove(' + d("Identity") + ')') else blk.println(this.codename, '.Remove(', d("Identity"), ');') end end func doTranslate(data) if(linked("onTranslate")) event("onTranslate", this.codename + '.Translate(' + sys.get_typed_field(data, 'TargetType', 20) + ')') else blk.println(this.codename, '.Translate(', sys.get_typed_field(data, 'TargetType', 20), ');') end end func doTranslate2(data) if(linked("onTranslate")) event("onTranslate", this.codename + '.Translate(' + sys.get_typed_field(data, 'TargetType', 20) + ', ' + d("forceSuccess") + ')') else blk.println(this.codename, '.Translate(', sys.get_typed_field(data, 'TargetType', 20), ', ', d("forceSuccess"), ');') end end func Item return(this.codename && '[' && d('index') && ']') end func doItem(data) blk.println(this.codename, '[', d('index'), '] = ', d("Identity"), ';') end