diff --git a/ccm-cms/src/com/arsdigita/cms/RelationAttributeResourceBundleControl.java b/ccm-cms/src/com/arsdigita/cms/RelationAttributeResourceBundleControl.java index 7ae375e65..ff10af2ec 100644 --- a/ccm-cms/src/com/arsdigita/cms/RelationAttributeResourceBundleControl.java +++ b/ccm-cms/src/com/arsdigita/cms/RelationAttributeResourceBundleControl.java @@ -1,17 +1,45 @@ /* - * To change this license header, choose License Headers in Project Properties. - * To change this template file, choose Tools | Templates - * and open the template in the editor. + * Copyright (c) 2014 Jens Pelzetter + * + * 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. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + * */ - package com.arsdigita.cms; +import com.arsdigita.cms.contenttypes.ui.GenericOrganizationalUnitPersonAddForm; +import com.arsdigita.globalization.GlobalizedMessage; import java.util.ListResourceBundle; import java.util.Locale; import java.util.ResourceBundle; /** - * + * This implementation of {@link ResourceBundle.Control} is intended to be used for showing + * RelationAttribute values (data base driven enum} values in Bebop Controls using + * {@link GlobalizedMessage}. Used it by creating a {@link GlobalizedMessage} like this: + * + *
+ * new GlobalizedMessage("attribute_key",
+ "attribute_name",
+ new RelationAttributeResourceBundleControl());
+ *
+ *
+ * Replace attribute_key with the key of the attribute value and
+ * attribute_name with the name of the relation attribute.
+ *
+ * To see this action, please refer for example to {@link GenericOrganizationalUnitPersonAddForm}.
+ *
* @author Jens Pelzetter