1.1 --- a/src/main/java/de/uapcore/lightpit/Menu.java Sat May 09 15:19:21 2020 +0200 1.2 +++ b/src/main/java/de/uapcore/lightpit/Menu.java Sat May 09 17:01:29 2020 +0200 1.3 @@ -1,8 +1,8 @@ 1.4 /* 1.5 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 1.6 - * 1.7 + * 1.8 * Copyright 2018 Mike Becker. All rights reserved. 1.9 - * 1.10 + * 1.11 * Redistribution and use in source and binary forms, with or without 1.12 * modification, are permitted provided that the following conditions are met: 1.13 * 1.14 @@ -24,7 +24,7 @@ 1.15 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 1.16 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 1.17 * POSSIBILITY OF SUCH DAMAGE. 1.18 - * 1.19 + * 1.20 */ 1.21 package de.uapcore.lightpit; 1.22 1.23 @@ -35,30 +35,30 @@ 1.24 /** 1.25 * Maps a resource key for the menu label to the path name for the underlying 1.26 * site. 1.27 - * 1.28 + * <p> 1.29 * Objects of this class are internally instantiated by the 1.30 * {@link ModuleManager}. 1.31 */ 1.32 public class Menu extends MenuEntry { 1.33 - 1.34 + 1.35 private final List<MenuEntry> entries = new ArrayList<>(); 1.36 private final List<MenuEntry> immutableEntries = Collections.unmodifiableList(entries); 1.37 - 1.38 + 1.39 /** 1.40 * Class name of the module for which this menu is built. 1.41 */ 1.42 private String moduleClassName; 1.43 - 1.44 - 1.45 + 1.46 + 1.47 public Menu() { 1.48 super(); 1.49 } 1.50 - 1.51 + 1.52 public Menu(String moduleClassName, ResourceKey resourceKey, String pathName) { 1.53 super(resourceKey, pathName); 1.54 this.moduleClassName = moduleClassName; 1.55 } 1.56 - 1.57 + 1.58 public void setModuleClassName(String moduleClassName) { 1.59 this.moduleClassName = moduleClassName; 1.60 } 1.61 @@ -69,7 +69,7 @@ 1.62 1.63 /** 1.64 * Sets a new list of menu entries for this menu. 1.65 - * 1.66 + * 1.67 * @param entries the list of new menu entries 1.68 */ 1.69 public void setEntries(List<MenuEntry> entries) { 1.70 @@ -80,15 +80,16 @@ 1.71 1.72 /** 1.73 * Retrieves an immutable list of menu entries for this menu. 1.74 - * 1.75 + * 1.76 * @return the list of menu entries 1.77 */ 1.78 public List<MenuEntry> getEntries() { 1.79 return immutableEntries; 1.80 } 1.81 - 1.82 + 1.83 /** 1.84 * Adds a new menu entry to this menu. 1.85 + * 1.86 * @param entry the menu entry to add 1.87 */ 1.88 public void addMenuEntry(MenuEntry entry) {