Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(5)  |  Call(2)  |  Derive(0)  |  Import(3)

src/s/e/seantis.plonetools-0.11/seantis/plonetools/scripts/install-memcached-sessions.py   seantis.plonetools(Download)
def main(app):
    try:
        from Products.BeakerSessionDataManager.sessiondata import (
            addBeakerSessionDataManager, BeakerSessionDataManager
        )
    dispatcher = app.manage_addProduct['BeakerSessionDataManager']
    addBeakerSessionDataManager(
        dispatcher, 'session_data_manager', 'Beaker Session Data Manager'
    )
    transaction.commit()

src/p/r/Products.BeakerSessionDataManager-1.1/Products/BeakerSessionDataManager/__init__.py   Products.BeakerSessionDataManager(Download)
def initialize(context):
 
    from Products.BeakerSessionDataManager.sessiondata import BeakerSessionDataManager
    from Products.BeakerSessionDataManager.sessiondata import addBeakerSessionDataManager
    from Products.BeakerSessionDataManager.sessiondata import addBeakerSessionDataManagerForm

src/p/r/Products.BeakerSessionDataManager-1.1/Products/BeakerSessionDataManager/tests/test_sessiondata.py   Products.BeakerSessionDataManager(Download)
    def test_factory(self):
        from Products.BeakerSessionDataManager.sessiondata import BeakerSessionDataManager
        from Products.BeakerSessionDataManager.sessiondata import addBeakerSessionDataManager
        class DummyDispatcher(object):
            def _setObject(self, id, ob):
                setattr(self, id, ob)
        dispatcher = DummyDispatcher()
        addBeakerSessionDataManager(dispatcher, 'sdm')