Package org.ametys.web.site
Class SitesPopulationsGenerator
- java.lang.Object
-
- org.apache.avalon.framework.logger.AbstractLogEnabled
-
- org.apache.cocoon.xml.AbstractXMLProducer
-
- org.apache.cocoon.generation.AbstractGenerator
-
- org.apache.cocoon.generation.ServiceableGenerator
-
- org.ametys.web.site.SitesPopulationsGenerator
-
- All Implemented Interfaces:
Poolable
,Recyclable
,Disposable
,Component
,LogEnabled
,Serviceable
,Generator
,SitemapModelComponent
,XMLProducer
public class SitesPopulationsGenerator extends ServiceableGenerator
Sax the datasources files limited to datasources useful for front-office
-
-
Field Summary
Fields Modifier and Type Field Description private CredentialProviderFactory
_credentialProviderFactory
private LDAPDataSourceManager
_ldapDataSourceManager
private PopulationContextHelper
_populationContextHelper
private SiteManager
_siteManager
private SQLDataSourceManager
_sqlDataSourceManager
private UserDirectoryFactory
_userDirectoryFactory
private UserPopulationDAO
_userPopulationDAO
-
Fields inherited from class org.apache.cocoon.generation.ServiceableGenerator
manager
-
Fields inherited from class org.apache.cocoon.generation.AbstractGenerator
objectModel, parameters, resolver, source
-
Fields inherited from class org.apache.cocoon.xml.AbstractXMLProducer
contentHandler, EMPTY_CONTENT_HANDLER, lexicalHandler, xmlConsumer
-
-
Constructor Summary
Constructors Constructor Description SitesPopulationsGenerator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private void
_addDatasourceToModel(String modelId, String datasource, Map<String,Set<String>> datasourcesPerModel)
private Pair<Set<String>,Map<String,Set<String>>>
_getDatasourcesUsedByPopulations(Set<UserPopulation> usedPopulations)
private Set<UserPopulation>
_getPopulationsUsedBySites()
private String
_replaceDefaultIds(String datasourceId)
private void
_saxCaptchaInfo()
private void
_saxDatabasesFiles()
private void
_saxDatasourcesInUse(Set<UserPopulation> usedPopulations)
private void
_saxLDAPDatabaseFile()
private void
_saxMonitoringInfo()
private void
_saxPopulationFile()
private void
_saxPopulationsInUse(Set<UserPopulation> usedPopulations)
private void
_saxSQLDatabaseFile()
private void
_saxUsedStuff()
void
generate()
void
service(ServiceManager smanager)
-
Methods inherited from class org.apache.cocoon.generation.ServiceableGenerator
dispose
-
Methods inherited from class org.apache.cocoon.generation.AbstractGenerator
recycle, setup
-
Methods inherited from class org.apache.cocoon.xml.AbstractXMLProducer
setConsumer, setContentHandler, setLexicalHandler
-
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.cocoon.xml.XMLProducer
setConsumer
-
-
-
-
Field Detail
-
_siteManager
private SiteManager _siteManager
-
_populationContextHelper
private PopulationContextHelper _populationContextHelper
-
_userPopulationDAO
private UserPopulationDAO _userPopulationDAO
-
_userDirectoryFactory
private UserDirectoryFactory _userDirectoryFactory
-
_credentialProviderFactory
private CredentialProviderFactory _credentialProviderFactory
-
_sqlDataSourceManager
private SQLDataSourceManager _sqlDataSourceManager
-
_ldapDataSourceManager
private LDAPDataSourceManager _ldapDataSourceManager
-
-
Constructor Detail
-
SitesPopulationsGenerator
public SitesPopulationsGenerator()
-
-
Method Detail
-
service
public void service(ServiceManager smanager) throws ServiceException
- Specified by:
service
in interfaceServiceable
- Overrides:
service
in classServiceableGenerator
- Throws:
ServiceException
-
generate
public void generate() throws IOException, SAXException, ProcessingException
-
_saxMonitoringInfo
private void _saxMonitoringInfo() throws SAXException
- Throws:
SAXException
-
_saxCaptchaInfo
private void _saxCaptchaInfo() throws SAXException
- Throws:
SAXException
-
_saxDatabasesFiles
private void _saxDatabasesFiles() throws IOException, SAXException
- Throws:
IOException
SAXException
-
_saxLDAPDatabaseFile
private void _saxLDAPDatabaseFile() throws SAXException, IOException
- Throws:
SAXException
IOException
-
_saxSQLDatabaseFile
private void _saxSQLDatabaseFile() throws SAXException, IOException
- Throws:
SAXException
IOException
-
_saxPopulationFile
private void _saxPopulationFile() throws SAXException, IOException
- Throws:
SAXException
IOException
-
_saxUsedStuff
private void _saxUsedStuff() throws SAXException
- Throws:
SAXException
-
_saxDatasourcesInUse
private void _saxDatasourcesInUse(Set<UserPopulation> usedPopulations) throws SAXException
- Throws:
SAXException
-
_saxPopulationsInUse
private void _saxPopulationsInUse(Set<UserPopulation> usedPopulations) throws SAXException
- Throws:
SAXException
-
_replaceDefaultIds
private String _replaceDefaultIds(String datasourceId)
-
_getPopulationsUsedBySites
private Set<UserPopulation> _getPopulationsUsedBySites()
-
_getDatasourcesUsedByPopulations
private Pair<Set<String>,Map<String,Set<String>>> _getDatasourcesUsedByPopulations(Set<UserPopulation> usedPopulations)
-
-