All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.liferay.commerce.tax.service.http.CommerceTaxMethodServiceHttp Maven / Gradle / Ivy

The newest version!
/**
 * SPDX-FileCopyrightText: (c) 2000 Liferay, Inc. https://liferay.com
 * SPDX-License-Identifier: LGPL-2.1-or-later OR LicenseRef-Liferay-DXP-EULA-2.0.0-2023-06
 */

package com.liferay.commerce.tax.service.http;

import com.liferay.commerce.tax.service.CommerceTaxMethodServiceUtil;
import com.liferay.portal.kernel.log.Log;
import com.liferay.portal.kernel.log.LogFactoryUtil;
import com.liferay.portal.kernel.security.auth.HttpPrincipal;
import com.liferay.portal.kernel.service.http.TunnelUtil;
import com.liferay.portal.kernel.util.MethodHandler;
import com.liferay.portal.kernel.util.MethodKey;

/**
 * Provides the HTTP utility for the
 * CommerceTaxMethodServiceUtil service
 * utility. The
 * static methods of this class calls the same methods of the service utility.
 * However, the signatures are different because it requires an additional
 * HttpPrincipal parameter.
 *
 * 

* The benefits of using the HTTP utility is that it is fast and allows for * tunneling without the cost of serializing to text. The drawback is that it * only works with Java. *

* *

* Set the property tunnel.servlet.hosts.allowed in portal.properties to * configure security. *

* *

* The HTTP utility is only generated for remote services. *

* * @author Marco Leo * @generated */ public class CommerceTaxMethodServiceHttp { public static com.liferay.commerce.tax.model.CommerceTaxMethod addCommerceTaxMethod( HttpPrincipal httpPrincipal, long groupId, java.util.Map nameMap, java.util.Map descriptionMap, String engineKey, boolean percentage, boolean active) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "addCommerceTaxMethod", _addCommerceTaxMethodParameterTypes0); MethodHandler methodHandler = new MethodHandler( methodKey, groupId, nameMap, descriptionMap, engineKey, percentage, active); Object returnObj = null; try { returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } return (com.liferay.commerce.tax.model.CommerceTaxMethod)returnObj; } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } public static com.liferay.commerce.tax.model.CommerceTaxMethod addCommerceTaxMethod( HttpPrincipal httpPrincipal, java.util.Map nameMap, java.util.Map descriptionMap, String engineKey, boolean percentage, boolean active, com.liferay.portal.kernel.service.ServiceContext serviceContext) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "addCommerceTaxMethod", _addCommerceTaxMethodParameterTypes1); MethodHandler methodHandler = new MethodHandler( methodKey, nameMap, descriptionMap, engineKey, percentage, active, serviceContext); Object returnObj = null; try { returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } return (com.liferay.commerce.tax.model.CommerceTaxMethod)returnObj; } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } public static com.liferay.commerce.tax.model.CommerceTaxMethod createCommerceTaxMethod( HttpPrincipal httpPrincipal, long groupId, long commerceTaxMethodId) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "createCommerceTaxMethod", _createCommerceTaxMethodParameterTypes2); MethodHandler methodHandler = new MethodHandler( methodKey, groupId, commerceTaxMethodId); Object returnObj = null; try { returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } return (com.liferay.commerce.tax.model.CommerceTaxMethod)returnObj; } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } public static void deleteCommerceTaxMethod( HttpPrincipal httpPrincipal, long commerceTaxMethodId) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "deleteCommerceTaxMethod", _deleteCommerceTaxMethodParameterTypes3); MethodHandler methodHandler = new MethodHandler( methodKey, commerceTaxMethodId); try { TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } public static com.liferay.commerce.tax.model.CommerceTaxMethod fetchCommerceTaxMethod( HttpPrincipal httpPrincipal, long groupId, String engineKey) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "fetchCommerceTaxMethod", _fetchCommerceTaxMethodParameterTypes4); MethodHandler methodHandler = new MethodHandler( methodKey, groupId, engineKey); Object returnObj = null; try { returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } return (com.liferay.commerce.tax.model.CommerceTaxMethod)returnObj; } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } public static com.liferay.commerce.tax.model.CommerceTaxMethod getCommerceTaxMethod( HttpPrincipal httpPrincipal, long commerceTaxMethodId) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "getCommerceTaxMethod", _getCommerceTaxMethodParameterTypes5); MethodHandler methodHandler = new MethodHandler( methodKey, commerceTaxMethodId); Object returnObj = null; try { returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } return (com.liferay.commerce.tax.model.CommerceTaxMethod)returnObj; } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } public static java.util.List getCommerceTaxMethods(HttpPrincipal httpPrincipal, long groupId) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "getCommerceTaxMethods", _getCommerceTaxMethodsParameterTypes6); MethodHandler methodHandler = new MethodHandler(methodKey, groupId); Object returnObj = null; try { returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } return (java.util.List )returnObj; } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } public static java.util.List getCommerceTaxMethods( HttpPrincipal httpPrincipal, long groupId, boolean active) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "getCommerceTaxMethods", _getCommerceTaxMethodsParameterTypes7); MethodHandler methodHandler = new MethodHandler( methodKey, groupId, active); Object returnObj = null; try { returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } return (java.util.List )returnObj; } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } public static com.liferay.commerce.tax.model.CommerceTaxMethod setActive( HttpPrincipal httpPrincipal, long commerceTaxMethodId, boolean active) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "setActive", _setActiveParameterTypes8); MethodHandler methodHandler = new MethodHandler( methodKey, commerceTaxMethodId, active); Object returnObj = null; try { returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } return (com.liferay.commerce.tax.model.CommerceTaxMethod)returnObj; } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } public static com.liferay.commerce.tax.model.CommerceTaxMethod updateCommerceTaxMethod( HttpPrincipal httpPrincipal, long commerceTaxMethodId, java.util.Map nameMap, java.util.Map descriptionMap, boolean percentage, boolean active) throws com.liferay.portal.kernel.exception.PortalException { try { MethodKey methodKey = new MethodKey( CommerceTaxMethodServiceUtil.class, "updateCommerceTaxMethod", _updateCommerceTaxMethodParameterTypes9); MethodHandler methodHandler = new MethodHandler( methodKey, commerceTaxMethodId, nameMap, descriptionMap, percentage, active); Object returnObj = null; try { returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler); } catch (Exception exception) { if (exception instanceof com.liferay.portal.kernel.exception.PortalException) { throw (com.liferay.portal.kernel.exception.PortalException) exception; } throw new com.liferay.portal.kernel.exception.SystemException( exception); } return (com.liferay.commerce.tax.model.CommerceTaxMethod)returnObj; } catch (com.liferay.portal.kernel.exception.SystemException systemException) { _log.error(systemException, systemException); throw systemException; } } private static Log _log = LogFactoryUtil.getLog( CommerceTaxMethodServiceHttp.class); private static final Class[] _addCommerceTaxMethodParameterTypes0 = new Class[] { long.class, java.util.Map.class, java.util.Map.class, String.class, boolean.class, boolean.class }; private static final Class[] _addCommerceTaxMethodParameterTypes1 = new Class[] { java.util.Map.class, java.util.Map.class, String.class, boolean.class, boolean.class, com.liferay.portal.kernel.service.ServiceContext.class }; private static final Class[] _createCommerceTaxMethodParameterTypes2 = new Class[] {long.class, long.class}; private static final Class[] _deleteCommerceTaxMethodParameterTypes3 = new Class[] {long.class}; private static final Class[] _fetchCommerceTaxMethodParameterTypes4 = new Class[] {long.class, String.class}; private static final Class[] _getCommerceTaxMethodParameterTypes5 = new Class[] {long.class}; private static final Class[] _getCommerceTaxMethodsParameterTypes6 = new Class[] {long.class}; private static final Class[] _getCommerceTaxMethodsParameterTypes7 = new Class[] {long.class, boolean.class}; private static final Class[] _setActiveParameterTypes8 = new Class[] { long.class, boolean.class }; private static final Class[] _updateCommerceTaxMethodParameterTypes9 = new Class[] { long.class, java.util.Map.class, java.util.Map.class, boolean.class, boolean.class }; }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy