Here you can find the source of createDefaultGroup(String name, String prefabGroup, List
Parameter | Description |
---|---|
name | - group name |
prefabGroup | - group this should extend. Make sure it exists. |
nodes | - all commands or custom permissions |
public static void createDefaultGroup(String name, String prefabGroup, List<String> nodes)
//package com.java2s; //License from project: Open Source License import java.util.*; public class Main { /**//from ww w .j ava 2 s. c om * Map of default groups and those group permissions permissions. Used to build a new group set. */ public static final HashMap<String, List<String>> groupDefaultNodes = new LinkedHashMap<String, List<String>>(); /** * Map of default groups and the group it extends. Used to build a new group set. */ public static final HashMap<String, String> groupDefaultExtends = new LinkedHashMap<String, String>(); /** * Creates a default group for all machines to use. Only add a group if there is no option to * really manage the group's settings * * @param name - group name * @param prefabGroup - group this should extend. Make sure it exists. * @param nodes - all commands or custom permissions */ public static void createDefaultGroup(String name, String prefabGroup, List<String> nodes) { if (name != null) { groupDefaultNodes.put(name, nodes); groupDefaultExtends.put(name, prefabGroup); } } /** * Creates a default group for all machines to use. Only add a group if there is no option to * really manage the group's settings * * @param name - group name * @param prefabGroup - group this should extend. Make sure it exists. * @param nodes - all commands or custom permissions */ public static void createDefaultGroup(String name, String prefabGroup, String... nodes) { createDefaultGroup(name, prefabGroup, nodes != null ? Arrays.asList(nodes) : null); } }