001    /**
002     * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portlet.dynamicdatamapping.render;
016    
017    import com.liferay.portal.kernel.security.pacl.permission.PortalRuntimePermission;
018    
019    /**
020     * @author Pablo Carvalho
021     */
022    public class DDMFormFieldRendererRegistryUtil {
023    
024            public static DDMFormFieldRenderer getDDMFormFieldRenderer(
025                    String ddmFormFieldType) {
026    
027                    return getDDMFormFieldRendererRegistry().getDDMFormFieldRenderer(
028                            ddmFormFieldType);
029            }
030    
031            public static DDMFormFieldRendererRegistry
032                    getDDMFormFieldRendererRegistry() {
033    
034                    PortalRuntimePermission.checkGetBeanProperty(
035                            DDMFormFieldRendererRegistryUtil.class);
036    
037                    return _ddmFormFieldRendererRegistry;
038            }
039    
040            public void setDDMFormFieldRendererRegistry(
041                    DDMFormFieldRendererRegistry ddmFormFieldRendererRegistry) {
042    
043                    PortalRuntimePermission.checkGetBeanProperty(getClass());
044    
045                    _ddmFormFieldRendererRegistry = ddmFormFieldRendererRegistry;
046            }
047    
048            private static DDMFormFieldRendererRegistry _ddmFormFieldRendererRegistry;
049    
050    }