+ String enteredName = inputDialog.getValue();
+
+ final String legalChars = "ABCDEFGHIJKLMNOPQRSTUVWXZY0123456789_";
+ char[] arr = enteredName.toUpperCase().toCharArray();
+ int count = 0;
+ for (int i = 0; i < arr.length; i++) {
+ if (legalChars.indexOf(arr[i]) == -1)
+ count = count + 7;
+ else
+ count++;
+ }
+
+ if (log.isDebugEnabled())
+ log.debug("Count " + count);
+
+ if (count > 60) {
+ ErrorFeedback.show("Workspace name '" + enteredName
+ + "' is too long or contains"
+ + " too many special characters such as '.' or '-'.");
+ return null;
+ }
+
+ String workspaceName = enteredName;