Subversion Repositories javautils

Rev

Rev 4 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 4 Rev 11
Line 318... Line 318...
318
                                //
318
                                //
319
                                // A zero-length element implies a period at the beginning or
319
                                // A zero-length element implies a period at the beginning or
320
                                // end of the
320
                                // end of the
321
                                // local part, or two periods together. Either way it's not
321
                                // local part, or two periods together. Either way it's not
322
                                // allowed.
322
                                // allowed.
323
                                if (element.equals("")) {
323
                                if (element.isEmpty()) {
324
                                        // Dots in wrong place
324
                                        // Dots in wrong place
325
                                        return EMailSyntaxDiagnosis.ISEMAIL_EMPTYELEMENT;
325
                                        return EMailSyntaxDiagnosis.ISEMAIL_EMPTYELEMENT;
326
                                }
326
                                }
327
 
327
 
328
                                // Any ASCII graphic (printing) character other than the
328
                                // Any ASCII graphic (printing) character other than the
Line 441... Line 441...
441
                        // }
441
                        // }
442
 
442
 
443
                        // Check for unmatched characters
443
                        // Check for unmatched characters
444
                        if (matchesIP6.length > 1) {
444
                        if (matchesIP6.length > 1) {
445
                                for (String s : matchesIP6[1]) {
445
                                for (String s : matchesIP6[1]) {
446
                                        if ((s != null) && (!s.equals(""))) {
446
                                        if ((s != null) && (!s.isEmpty())) {
447
                                                return EMailSyntaxDiagnosis.ISEMAIL_IPV6BADCHAR;
447
                                                return EMailSyntaxDiagnosis.ISEMAIL_IPV6BADCHAR;
448
                                        }
448
                                        }
449
                                }
449
                                }
450
                        } // else: Undefined state (should never be reached)
450
                        } // else: Undefined state (should never be reached)
451
 
451