本文整理汇总了Java中org.alfresco.util.ApplicationContextHelper.setUseLazyLoading方法的典型用法代码示例。如果您正苦于以下问题:Java ApplicationContextHelper.setUseLazyLoading方法的具体用法?Java ApplicationContextHelper.setUseLazyLoading怎么用?Java ApplicationContextHelper.setUseLazyLoading使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.alfresco.util.ApplicationContextHelper
的用法示例。
在下文中一共展示了ApplicationContextHelper.setUseLazyLoading方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: init
import org.alfresco.util.ApplicationContextHelper; //导入方法依赖的package包/类
@BeforeClass
public static void init()
{
ApplicationContextHelper.setUseLazyLoading(false);
ApplicationContextHelper.setNoAutoStart(true);
ctx = ApplicationContextHelper.getApplicationContext(CONFIG_LOCATIONS);
}
示例2: getContext
import org.alfresco.util.ApplicationContextHelper; //导入方法依赖的package包/类
public static ApplicationContext getContext()
{
ApplicationContextHelper.setUseLazyLoading(false);
ApplicationContextHelper.setNoAutoStart(true);
return ApplicationContextHelper.getApplicationContext(
new String[] { "classpath:alfresco/minimal-context.xml" }
);
}
示例3: init
import org.alfresco.util.ApplicationContextHelper; //导入方法依赖的package包/类
@BeforeClass
public static void init()
{
ApplicationContextHelper.setUseLazyLoading(false);
ApplicationContextHelper.setNoAutoStart(true);
ctx = ApplicationContextHelper.getApplicationContext();
}
示例4: getMinimalContext
import org.alfresco.util.ApplicationContextHelper; //导入方法依赖的package包/类
/**
* Asks {@link ApplicationContextHelper} to give us a
* suitable, perhaps cached context for use in our tests
*/
public static ApplicationContext getMinimalContext() {
ApplicationContextHelper.setUseLazyLoading(false);
ApplicationContextHelper.setNoAutoStart(true);
return ApplicationContextHelper.getApplicationContext(
new String[] { "classpath:alfresco/minimal-context.xml" }
);
}
示例5: getMinimalContext
import org.alfresco.util.ApplicationContextHelper; //导入方法依赖的package包/类
private ApplicationContext getMinimalContext() {
ApplicationContextHelper.setUseLazyLoading(false);
ApplicationContextHelper.setNoAutoStart(true);
return ApplicationContextHelper.getApplicationContext(
new String[] { "classpath:alfresco/minimal-context.xml" }
);
}
示例6: getFullContext
import org.alfresco.util.ApplicationContextHelper; //导入方法依赖的package包/类
private ApplicationContext getFullContext() {
ApplicationContextHelper.setUseLazyLoading(false);
ApplicationContextHelper.setNoAutoStart(false);
return ApplicationContextHelper.getApplicationContext(
new String[] { "classpath:alfresco/application-context.xml" }
);
}
示例7: before
import org.alfresco.util.ApplicationContextHelper; //导入方法依赖的package包/类
@Before
public void before() throws Exception
{
ApplicationContextHelper.setUseLazyLoading(false);
//ApplicationContextHelper.setNoAutoStart(true);
ctx = ApplicationContextHelper.getApplicationContext();
this.personService = (PersonService) ctx.getBean("personService");
this.transactionService = (TransactionService) ctx.getBean("transactionService");
this.nodeService = (NodeService) ctx.getBean("nodeService");
this.authenticationContext = (AuthenticationContext) ctx.getBean("authenticationContext");
// cannot get bean from context directly because of side affects from passthruServers.afterPropertiesSet
this.cifsAuthenticator = new PassthruCifsAuthenticator();
this.cifsAuthenticator.setTransactionService(transactionService);
// passthru-authentication-context.xml : NTLMAuthenticationComponentImpl is used for passthru
AbstractAuthenticationComponent ac = new org.alfresco.repo.security.authentication.ntlm.NTLMAuthenticationComponentImpl();
ac.setPersonService(personService);
ac.setTransactionService(transactionService);
ac.setNodeService(nodeService);
ac.setAuthenticationContext(authenticationContext);
this.cifsAuthenticator.setAuthenticationComponent(ac);
this.cifsAuthenticator.setAuthenticationService(mock(org.alfresco.repo.security.authentication.AuthenticationServiceImpl.class));
// create only user1 in local repository
transactionService.getRetryingTransactionHelper().doInTransaction(new RetryingTransactionHelper.RetryingTransactionCallback<Void>()
{
@SuppressWarnings("synthetic-access")
public Void execute() throws Throwable
{
AuthenticationUtil.pushAuthentication();
AuthenticationUtil.setFullyAuthenticatedUser(AuthenticationUtil.getAdminUserName());
// create person properties
PropertyMap personProps = new PropertyMap();
personProps.put(ContentModel.PROP_USERNAME, userExistingLocal);
personProps.put(ContentModel.PROP_FIRSTNAME, userExistingLocal);
personProps.put(ContentModel.PROP_LASTNAME, userExistingLocal);
personProps.put(ContentModel.PROP_EMAIL, userExistingLocal + "@email.com");
personService.createPerson(personProps);
AuthenticationUtil.popAuthentication();
return null;
}
}, false, true);
}