com.liferay.portal.kernel.cache.SingleVMPoolUtil Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of com.liferay.portal.kernel Show documentation
Show all versions of com.liferay.portal.kernel Show documentation
Contains interfaces for the portal services. Interfaces are only loaded by the global class loader and are shared by all plugins.
/**
* Copyright (c) 2000-present Liferay, Inc. All rights reserved.
*
* This library is free software; you can redistribute it and/or modify it under
* the terms of the GNU Lesser General Public License as published by the Free
* Software Foundation; either version 2.1 of the License, or (at your option)
* any later version.
*
* This library is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
* FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
* details.
*/
package com.liferay.portal.kernel.cache;
import com.liferay.portal.kernel.spring.osgi.OSGiBeanProperties;
import com.liferay.portal.kernel.util.ProxyFactory;
import java.io.Serializable;
/**
* @author Brian Wing Shun Chan
* @author Michael Young
*/
@OSGiBeanProperties(service = SingleVMPoolUtil.class)
public class SingleVMPoolUtil {
public static void clear() {
_singleVMPool.clear();
}
/**
* @deprecated As of 7.0.0, replaced by {@link #getPortalCache(String)}
*/
@Deprecated
public static PortalCache getCache(
String portalCacheName) {
return getPortalCache(portalCacheName);
}
/**
* @deprecated As of 7.0.0, replaced by {@link #getPortalCache(String,
* boolean)}
*/
@Deprecated
public static PortalCache getCache(
String portalCacheName, boolean blocking) {
return getPortalCache(portalCacheName, blocking);
}
/**
* @deprecated As of 7.0.0, replaced by {@link #getPortalCacheManager()}
*/
@Deprecated
public static PortalCacheManager
getCacheManager() {
return getPortalCacheManager();
}
public static PortalCache getPortalCache(
String portalCacheName) {
return (PortalCache)_singleVMPool.getPortalCache(portalCacheName);
}
public static PortalCache getPortalCache(
String portalCacheName, boolean blocking) {
return (PortalCache)_singleVMPool.getPortalCache(
portalCacheName, blocking);
}
public static PortalCacheManager
getPortalCacheManager() {
return (PortalCacheManager)_singleVMPool.getPortalCacheManager();
}
/**
* @deprecated As of 7.0.0, replaced by {@link #removePortalCache(String)}
*/
@Deprecated
public static void removeCache(String portalCacheName) {
removePortalCache(portalCacheName);
}
public static void removePortalCache(String portalCacheName) {
_singleVMPool.removePortalCache(portalCacheName);
}
private static final SingleVMPool _singleVMPool =
ProxyFactory.newServiceTrackedInstance(SingleVMPool.class);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy