public ConnectionServiceImpl ( final Connection connection, final Integer autoReconnectController, final boolean lazyActivation ) { super ( autoReconnectController, lazyActivation ); // for now we are using the autoReconnectController timeout as lingering timeout ... this.connection = lazyActivation ? new LazyConnectionWrapper ( connection, autoReconnectController ) { @Override protected void performDisconnect () { setShouldConnect ( false ); } @Override protected void performConnect () { setShouldConnect ( true ); } } : connection; setConnection ( this.connection ); this.itemManager = new CountingItemManager ( new ItemManagerImpl ( this.connection ), this.statistics ); this.folderManager = new FolderManager ( this.connection ); this.statistics.setLabel ( ConnectionServiceImpl.GET_ON_IM, "getItemManager called" ); this.statistics.setLabel ( CountingItemManager.REGISTERED_ITEMS, "Registered items" ); }
public ConnectionServiceImpl ( final Connection connection, final Integer autoReconnectController, final boolean lazyActivation ) { super ( autoReconnectController, lazyActivation ); // for now we are using the autoReconnectController timeout as lingering timeout ... this.connection = lazyActivation ? new LazyConnectionWrapper ( connection, autoReconnectController ) { @Override protected void performDisconnect () { setShouldConnect ( false ); } @Override protected void performConnect () { setShouldConnect ( true ); } } : connection; setConnection ( this.connection ); this.itemManager = new CountingItemManager ( new ItemManagerImpl ( this.connection ), this.statistics ); this.folderManager = new FolderManager ( this.connection ); this.statistics.setLabel ( ConnectionServiceImpl.GET_ON_IM, "getItemManager called" ); this.statistics.setLabel ( CountingItemManager.REGISTERED_ITEMS, "Registered items" ); }