Skip to content

Instantly share code, notes, and snippets.

@FoxInCloud
FoxInCloud / sessionfactory.prg
Last active June 22, 2016 10:48 — forked from StevenBlack/sessionfactory.prg
SessionFactory creates objects that are wrapped in a private data session. Note that the factory can die but its private datasession lives until all its products are out of scope.
*=======================================
DEFINE CLASS SessionFactory AS Session
*=======================================
DataSession = 2 && private
*==========================
FUNCTION Init()
SET CENTURY TO 20 ROLLOVER 50
SET CENTURY ON
SET DELETED ON