TilesContextFactory contextFactory = createContextFactory(context);
TilesApplicationContext applicationContext = contextFactory
.createApplicationContext(context);
container.setContextFactory(contextFactory);
container.setApplicationContext(applicationContext);
LocaleResolver resolver = createLocaleResolver(context,
applicationContext, contextFactory);
container.setDefinitionsFactory(createDefinitionsFactory(context,
applicationContext, contextFactory, resolver));
AttributeEvaluator evaluator = createEvaluator(context,
applicationContext, contextFactory, resolver);