diff options
author | Jonathan Bauer | 2016-09-09 15:33:38 +0200 |
---|---|---|
committer | Jonathan Bauer | 2016-09-09 15:33:38 +0200 |
commit | cbbb0dd4e9ca35c7d7ce6ba08c703614a6ba9493 (patch) | |
tree | f7197542db4607e8881121e85e8249dfa3b1c089 /dozentenmodul/src/main/java/org/openslx/dozmod/gui/control/NetrulesConfigurator.java | |
parent | [client] minor: update commentaries of NetrulesConfigurator (diff) | |
download | tutor-module-cbbb0dd4e9ca35c7d7ce6ba08c703614a6ba9493.tar.gz tutor-module-cbbb0dd4e9ca35c7d7ce6ba08c703614a6ba9493.tar.xz tutor-module-cbbb0dd4e9ca35c7d7ce6ba08c703614a6ba9493.zip |
[client] minor commentaries
Diffstat (limited to 'dozentenmodul/src/main/java/org/openslx/dozmod/gui/control/NetrulesConfigurator.java')
-rw-r--r-- | dozentenmodul/src/main/java/org/openslx/dozmod/gui/control/NetrulesConfigurator.java | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/control/NetrulesConfigurator.java b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/control/NetrulesConfigurator.java index 793e6e4a..d471349f 100644 --- a/dozentenmodul/src/main/java/org/openslx/dozmod/gui/control/NetrulesConfigurator.java +++ b/dozentenmodul/src/main/java/org/openslx/dozmod/gui/control/NetrulesConfigurator.java @@ -57,7 +57,6 @@ public class NetrulesConfigurator extends NetrulesConfiguratorLayout { } }; tpNetworkRules.getDocument().addDocumentListener(docListener); - } @@ -66,8 +65,8 @@ public class NetrulesConfigurator extends NetrulesConfiguratorLayout { } /** - * Gets the state of the widget as a list of netrules. Internally it first transforms - * the input text in a list of netrules. + * Gets the state of the widget as a list of netrules. Internally it first + * transforms the input text in a list of netrules. * * @return the list of rules as parsed by parseNetRules() */ @@ -78,11 +77,11 @@ public class NetrulesConfigurator extends NetrulesConfiguratorLayout { } /** - * Sets the state of this widget to the given list of netrules. This will internally - * transform the list to its string representation + * Sets the state of this widget to the given list of netrules. This will + * internally transform the list to its string representation * - * @param config - * AdvancedConfiguration to set the state to + * @param netrules + * as a list of NetRule to set the state to */ public void setState(final List<NetRule> netrules) { // setText() blanks the text area if null is given, so no null checks @@ -128,7 +127,8 @@ public class NetrulesConfigurator extends NetrulesConfiguratorLayout { * * @param rawNetRules * the raw text to be parsed - * @return list of netrules if successful. If any errors occured while parsing, null is returned. + * @return list of netrules if successful. If any errors occured while + * parsing, null is returned. */ public List<NetRule> parseNetRules(final String rawNetRules) { if (rawNetRules == null) @@ -332,8 +332,8 @@ public class NetrulesConfigurator extends NetrulesConfiguratorLayout { } /** - * Custom event mechanism to detect changes to the netrules list (Mostly needed - * for the reactToChange() stuff in LectureDetailsWindow) + * Custom event mechanism to detect changes to the netrules list (Mostly + * needed for the reactToChange() stuff in LectureDetailsWindow) */ protected EventListenerList listenerList = new EventListenerList(); @@ -384,7 +384,7 @@ class NetrulesConfiguratorLayout extends JPanel { private final static String txtNetworkOptionsTitle = "Netzwerk Einstellungen"; private final static String txtNetworkOptionsDesc = "Wenn Sie den Internetzugriff deaktiviert haben, können Sie hier Ausnahmen definieren (Whitelist). Bitte definieren Sie Ihre Regeln im Format <host> <port> <in|out>."; private final static String txtNetworkRulesTitle = "Netzwerkregeln"; - + private final JPanel pnlNetworkOptions; protected final JTextPane tpNetworkRules; @@ -400,7 +400,6 @@ class NetrulesConfiguratorLayout extends JPanel { pnlNetworkOptions.setBorder(BorderFactory .createTitledBorder(txtNetworkOptionsTitle)); tpNetworkRules = new JTextPane(); - JScrollPane scpNetworkRules = new JScrollPane(tpNetworkRules, JScrollPane.VERTICAL_SCROLLBAR_AS_NEEDED, @@ -414,7 +413,7 @@ class NetrulesConfiguratorLayout extends JPanel { gridNetworkOptions.add(scpNetworkRules).fill(true, true) .expand(true, true); gridNetworkOptions.finish(false); - + // build the final grid grid.add(pnlNetworkOptions).fill(true, true).expand(true, true); grid.finish(false); |