| 1 | |
|
| 2 | |
|
| 3 | |
|
| 4 | |
|
| 5 | |
|
| 6 | |
|
| 7 | |
|
| 8 | |
|
| 9 | |
|
| 10 | |
|
| 11 | |
|
| 12 | |
|
| 13 | |
package org.kuali.rice.kns.service; |
| 14 | |
|
| 15 | |
|
| 16 | |
import com.opensymphony.oscache.general.GeneralCacheAdministrator; |
| 17 | |
import org.kuali.rice.core.api.namespace.NamespaceService; |
| 18 | |
import org.kuali.rice.core.api.resourceloader.GlobalResourceLoader; |
| 19 | |
import org.kuali.rice.core.framework.persistence.platform.DatabasePlatform; |
| 20 | |
import org.kuali.rice.core.api.resourceloader.GlobalResourceLoader; |
| 21 | |
import org.kuali.rice.kns.dao.BusinessObjectDao; |
| 22 | |
import org.kuali.rice.kns.dao.DocumentDao; |
| 23 | |
import org.kuali.rice.kns.lookup.Lookupable; |
| 24 | |
import org.kuali.rice.kns.util.OjbCollectionHelper; |
| 25 | |
import org.kuali.rice.kns.util.cache.MethodCacheInterceptor; |
| 26 | |
import org.kuali.rice.kns.workflow.service.WorkflowAttributePropertyResolutionService; |
| 27 | |
import org.springframework.transaction.PlatformTransactionManager; |
| 28 | |
import org.springframework.transaction.support.TransactionTemplate; |
| 29 | |
|
| 30 | 0 | public class KNSServiceLocatorInternal { |
| 31 | |
|
| 32 | |
public static final String VALIDATION_COMPLETION_UTILS = "validationCompletionUtils"; |
| 33 | |
|
| 34 | |
public static <T extends Object> T getService(String serviceName) { |
| 35 | 0 | return GlobalResourceLoader.<T>getService(serviceName); |
| 36 | |
} |
| 37 | |
|
| 38 | |
|
| 39 | |
public static final String MAIL_SERVICE = "mailService"; |
| 40 | |
|
| 41 | |
public static final MailService getMailService() { |
| 42 | 0 | return (MailService) getService(MAIL_SERVICE); |
| 43 | |
} |
| 44 | |
|
| 45 | |
public static final String METHOD_CACHE_INTERCEPTOR = "methodCacheInterceptor"; |
| 46 | |
|
| 47 | |
public static MethodCacheInterceptor getMethodCacheInterceptor() { |
| 48 | 0 | return (MethodCacheInterceptor) getService(METHOD_CACHE_INTERCEPTOR); |
| 49 | |
} |
| 50 | |
|
| 51 | |
public static final String POST_PROCESSOR_SERVICE = "postProcessorService"; |
| 52 | |
|
| 53 | |
public static PostProcessorService getPostProcessorService() { |
| 54 | 0 | return (PostProcessorService) getService(POST_PROCESSOR_SERVICE); |
| 55 | |
} |
| 56 | |
|
| 57 | |
public static final String NAMESPACE_SERVICE = "namespaceService"; |
| 58 | |
|
| 59 | |
public static NamespaceService getNamespaceService() { |
| 60 | 0 | return (NamespaceService) getService(NAMESPACE_SERVICE); |
| 61 | |
} |
| 62 | |
|
| 63 | |
public static Lookupable getKualiLookupable() { |
| 64 | 0 | return (Lookupable) getService(KNSServiceLocatorWeb.KUALI_LOOKUPABLE); |
| 65 | |
} |
| 66 | |
|
| 67 | |
public static final String OJB_COLLECTION_HELPER = "ojbCollectionHelper"; |
| 68 | |
|
| 69 | |
public static OjbCollectionHelper getOjbCollectionHelper() { |
| 70 | 0 | return (OjbCollectionHelper) getService(OJB_COLLECTION_HELPER); |
| 71 | |
} |
| 72 | |
|
| 73 | |
public static final String PERSISTENCE_CACHE_ADMINISTRATOR = "persistenceCacheAdministrator"; |
| 74 | |
|
| 75 | |
public static final GeneralCacheAdministrator getPersistenceCacheAdministrator() { |
| 76 | 0 | return (GeneralCacheAdministrator) getService(PERSISTENCE_CACHE_ADMINISTRATOR); |
| 77 | |
} |
| 78 | |
|
| 79 | |
public static final String TRANSACTION_MANAGER = "transactionManager"; |
| 80 | |
|
| 81 | |
public static PlatformTransactionManager getTransactionManager() { |
| 82 | 0 | return (PlatformTransactionManager) getService(TRANSACTION_MANAGER); |
| 83 | |
} |
| 84 | |
|
| 85 | |
public static final String TRANSACTION_TEMPLATE = "transactionTemplate"; |
| 86 | |
|
| 87 | |
public static TransactionTemplate getTransactionTemplate() { |
| 88 | 0 | return (TransactionTemplate) getService(TRANSACTION_TEMPLATE); |
| 89 | |
} |
| 90 | |
|
| 91 | |
public static final String INACTIVATION_BLOCKING_DISPLAY_SERVICE = "inactivationBlockingDisplayService"; |
| 92 | |
|
| 93 | |
public static InactivationBlockingDisplayService getInactivationBlockingDisplayService() { |
| 94 | 0 | return (InactivationBlockingDisplayService) getService(INACTIVATION_BLOCKING_DISPLAY_SERVICE); |
| 95 | |
} |
| 96 | |
|
| 97 | |
|
| 98 | |
public static final String DOCUMENT_DAO = "documentDao"; |
| 99 | |
|
| 100 | |
public static DocumentDao getDocumentDao() { |
| 101 | 0 | return (DocumentDao) getService(DOCUMENT_DAO); |
| 102 | |
} |
| 103 | |
|
| 104 | |
public static final String BUSINESS_OBJECT_DAO = "businessObjectDao"; |
| 105 | |
|
| 106 | |
public static BusinessObjectDao getBusinessObjectDao() { |
| 107 | 0 | return (BusinessObjectDao) getService(BUSINESS_OBJECT_DAO); |
| 108 | |
} |
| 109 | |
|
| 110 | |
|
| 111 | |
public static final String DB_PLATFORM = "dbPlatform"; |
| 112 | |
|
| 113 | |
public static DatabasePlatform getDatabasePlatform() { |
| 114 | 0 | return (DatabasePlatform) getService(DB_PLATFORM); |
| 115 | |
} |
| 116 | |
|
| 117 | |
public static final String MAINTENANCE_DOCUMENT_AUTHORIZATION_SERVICE = "maintenanceDocumentAuthorizationService"; |
| 118 | |
|
| 119 | |
public static BusinessObjectAuthorizationService getMaintenanceDocumentAuthorizationService() { |
| 120 | 0 | return (BusinessObjectAuthorizationService) getService(MAINTENANCE_DOCUMENT_AUTHORIZATION_SERVICE); |
| 121 | |
} |
| 122 | |
|
| 123 | |
public static final String RICE_APPLICATION_CONFIGURATION_SERVICE = "riceApplicationConfigurationService"; |
| 124 | |
|
| 125 | |
public static RiceApplicationConfigurationService getRiceApplicationConfigurationService() { |
| 126 | 0 | return (RiceApplicationConfigurationService) getService(RICE_APPLICATION_CONFIGURATION_SERVICE); |
| 127 | |
} |
| 128 | |
|
| 129 | |
public static final String WORKFLOW_ATTRIBUTE_PROPERTY_RESOLUTION_SERVICE = "workflowAttributesPropertyResolutionService"; |
| 130 | |
|
| 131 | |
public static WorkflowAttributePropertyResolutionService getWorkflowAttributePropertyResolutionService() { |
| 132 | 0 | return (WorkflowAttributePropertyResolutionService) getService(WORKFLOW_ATTRIBUTE_PROPERTY_RESOLUTION_SERVICE); |
| 133 | |
} |
| 134 | |
|
| 135 | |
public static final String INACTIVATEABLE_FROM_TO_SERVICE = "inactivateableFromToService"; |
| 136 | |
|
| 137 | |
public static InactivateableFromToService getInactivateableFromToService() { |
| 138 | 0 | return (InactivateableFromToService) getService(INACTIVATEABLE_FROM_TO_SERVICE); |
| 139 | |
} |
| 140 | |
|
| 141 | |
} |