@Tom. You actually don't need static inside a class. If you want a variable to "survive" a method call you just define it on the class level. Something like
Class ViewTool
Private db as NotesDatabase
Private view as NotesView
Public sub new(theDB as NotesDatabase)
if theDB is nothing then
RaiseError ...
end if
set me.db = theDB
endSub
public function getUserDoc(userName as String) as NotesDocument
if me.view is nothing then
set me.view = me.db.getview("WhateverNameYouneed")
@Tom. You actually don't need static inside a class. If you want a variable to "survive" a method call you just define it on the class level. Something like
Class ViewTool
Private db as NotesDatabase
Private view as NotesView
Public sub new(theDB as NotesDatabase)
if theDB is nothing then
RaiseError ...
end if
set me.db = theDB
endSub
public function getUserDoc(userName as String) as NotesDocument
if me.view is nothing then
set me.view = me.db.getview("WhateverNameYouneed")
.... now the search ....
end function
End Class