190 likes | 293 Views
DLM Status Update. Topics. Channel Parameters Fragment Manager Parameter Processing Pipe Schedule. Channel Parameters. ChannelStaticData setParameter(key, value) setParameters(Map) Store() Persists in user’s Layout, honors user overridable settings. Fragment Manager. Two Phases 1 st
E N D
Topics • Channel Parameters • Fragment Manager • Parameter Processing Pipe • Schedule
Channel Parameters • ChannelStaticData • setParameter(key, value) • setParameters(Map) • Store() • Persists in user’s Layout, honors user overridable settings
Fragment Manager • Two Phases • 1st • Replaces dlm.xml • Still edit fragment layouts via separate accounts • Pushed/Subscribed fragment • Disable/Enable • Audience Determination using Groups Manager • Localizable • Granular Permissions • Migration (dlm.xml to up_dlm_fragments)
Fragment Manager • Two Phases • 2nd • In-session Fragment Layout editing • Integrated Modes
Parameter Processing Pipe • History • UserInstance Refactoring • processUserLayoutParameters() • LM processLayoutParameters() • I/M Initial work (Tension) • LM must remain oblivious to the structure and theme • But Structure rules for “Add Channel” very simple
Parameter Processing Pipe Current Call Flow UserInstance LayoutManager processLayoutParameters() getUserLayout() SAX event stream
Parameter Processing Pipe • History • I/M Initial work (Tension) • LM must remain oblivious to the structure and theme • But layout rules often much simpler than can be expressed in a general, non-structure layer • Parameter Processing Pipe
Parameter Processing Pipe New Call Flow UserInstance DistributedLayoutManager processLayoutParameters() ProcessingPipe getUserLayout() SAX event stream
Parameter Processing Pipe New Call Flow UserInstance DistributedLayoutManager processLayoutParameters() IParameterProcessor IOptionalParameterProcessor getUserLayout() ISAXProcessor SAX event stream
Parameter Processing Pipe • Package: org.jasig.portal.layout.dlm.processing • IParameterProcessor • processParameters(UserPreferences, HttpServletRequest) • setResources(IPerson, DistributedLayoutManager) • IOptionalProcessor • isFinished()
Parameter Processing Pipe • Package: org.jasig.portal.layout.dlm.processing • ISaxProcessor • Content Handler methods • getCacheKey()
Parameter Processing Pipe • Package: org.jasig.portal.layout.dlm.processing • ProcessingPipe Class • Implements IParameterProcessor • Methods for acquiring “Entry Point” and “ExitP Point” Content Handlers • getCacheKey() indicative of which Sax processors participated in the Sax event stream processing. • getEntryContentHandler() ContentHandler • setExitContentHandler(ConentHandler)
Parameter Processing Pipe • DistributedLayoutManager • processLayoutParameters(…) • processingPipe.processParameters(userPrefs, request); • getUserlayout(Node n, ContentHandler ch) • processingPipe.setExitContentHandler(ch); • ch = processingPipe.getEntryContentHandler(); • xfrmr.transform(new DOMSource(n), new SAXResult(ch)); • getCacheKey() • processingPipe.getCacheKey() + ":" + this.cacheKey;
Parameter Processing Pipe • Spring Configured (dlmContext.xml) • Fixed Processors List • OptionalProcessors Map • OptionalProcessor selectable via request parameter uP_dlmPrc=<key>, persists until replaced or asserts isFinished() • Can participate in Parameter Processing and/or SAX processing
Parameter Processing Pipe • Example Processors • IParameterProcessor example: • ExampleStickyTabEnforcer : sets “activeTab” parameter in StructureStylesheet UserPreferences to tab with title, “Sticky Tab”. • ISaxProcessor example: • ExampleBookmarksRemover : strips all SAX events related to Bookmarks channel.
Parameter Processing Pipe • Pluggable: • Structure/Theme Specific Processing • Flexible: • custom request parameter processing • injection of structure and theme stylesheet parameters, channel and folder attributes, etc. • Injection or removal of layout content • Uses? • Integrate Modes, Drag and Drop, etc.
Schedule • Channel Parameters (fall 05) • Fragment Manager (post Luminis 4.0) • Parameter Processing Pipe (this week) • I/M (post Luminis 4.0+)