Monday, November 08, 2010 at 12:03 AM.
system.verbs.builtins.io.client.initUser
on initUser (username) {
<<Changes
<<7/15/10; 10:52:05 AM by DW
<<Created.
local (adrdata = io.init ());
local (adruser = @adrdata^.client.buddies.users.[username]);
if not defined (adruser^) {
new (tabletype, adruser)};
bundle { //stats
if not defined (adruser^.stats) {
new (tabletype, @adruser^.stats)};
if not defined (adruser^.stats.flDirty) {
adruser^.stats.flDirty = true};
if not defined (adruser^.stats.ctUpdates) {
adruser^.stats.ctUpdates = 0};
if not defined (adruser^.stats.whenLastUpdate) {
adruser^.stats.whenLastUpdate = date (0)};
if not defined (adruser^.stats.whenCreated) {
adruser^.stats.whenCreated = clock.now ()};
if not defined (adrUser^.stats.ctTicksOutlineCompile) {
adrUser^.stats.ctTicksOutlineCompile = 0}};
return (adruser)};
bundle { //test code
initUser ("davewiner")}
This listing is for code that runs in the OPML Editor environment. I created these listings because I wanted the search engines to index it, so that when I want to look up something in my codebase I don't have to use the much slower search functionality in my object database. Dave Winer.