source: main/trunk/gli/src/org/greenstone/gatherer/cdm/FacetManager.java@ 36250

Last change on this file since 36250 was 36250, checked in by kjdon, 22 months ago

added keys for add all button

File size: 2.6 KB
Line 
1/**
2 *#########################################################################
3 *
4 * A component of the Gatherer application, part of the Greenstone digital
5 * library suite from the New Zealand Digital Library Project at the
6 * University of Waikato, New Zealand.
7 *
8 * Copyright (C) 2022 New Zealand Digital Library Project
9 *
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
19 *
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23 *########################################################################
24 */
25package org.greenstone.gatherer.cdm;
26
27import org.greenstone.gatherer.util.StaticStrings;
28import org.w3c.dom.*;
29
30/** Handles facets for solr collections */
31public class FacetManager extends BaseIndexManager {
32
33
34 public FacetManager(Element facets, String current_build_type) {
35 super(facets, current_build_type, StaticStrings.FACET_ELEMENT, null, new Facet());
36 this.controls_title_key = "CDM.FacetManager.Title";
37 this.new_button_tooltip_key = "CDM.FacetManager.New_Button_Tooltip";
38 this.edit_button_tooltip_key = "CDM.FacetManager.Edit_Button_Tooltip";
39 this.remove_button_tooltip_key = "CDM.FacetManager.Remove_Button_Tooltip";
40 this.nip_new_index_key = "CDM.FacetManager.New";
41 this.nip_edit_index_key = "CDM.FacetManager.Edit";
42 this.nip_source_label_key = "CDM.FacetManager.Source";
43 this.nip_source_tooltip_key = "CDM.FacetManager.Source_Tooltip";
44
45 this.nip_add_index_button_key = "CDM.FacetManager.Add";
46 this.nip_add_index_tooltip_key = "CDM.FacetManager.Add_Tooltip";
47 this.nip_replace_index_button_key = "CDM.FacetManager.Replace";
48 this.nip_replace_index_tooltip_key = "CDM.FacetManager.Replace_Tooltip";
49 this.nip_add_all_index_button_key = "CDM.IndexManager.AddAll";
50 this.nip_add_all_index_tooltip_key = "CDM.FacetManager.AddAll_Tooltip";
51
52 }
53
54 public void buildTypeChanged(String new_build_type) {
55 if (new_build_type.equals(BuildTypeManager.BUILD_TYPE_SOLR)) {
56 // activate
57 setAssigned(true);
58 } else {
59 // deactivate
60 setAssigned(false);
61 }
62 }
63
64}
Note: See TracBrowser for help on using the repository browser.