Moti Asayag has posted comments on this change.

Change subject: engine: Remove unused code
......................................................................


Patch Set 1:

(4 comments)

....................................................
File 
backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/utils/ValidationUtils.java
Line 22:     public static final String NO_SPECIAL_CHARACTERS = 
"[0-9a-zA-Z_-]+";
Line 23:     public static final String ONLY_I18N_ASCII_OR_NONE = 
"[\\p{ASCII}\\p{L}]*";
Line 24:     public static final String ONLY_ASCII_OR_NONE = "[\\p{ASCII}]*";
Line 25:     public static final String NO_SPECIAL_CHARACTERS_WITH_DOT = 
"[0-9a-zA-Z-_\\.]+";
Line 26:     public static final String DOMAIN_NAME_PATTERN =
Done
Line 27:             
"^([a-zA-Z0-9]([a-zA-Z0-9\\-]{0,61}[a-zA-Z0-9])?\\.)+[a-zA-Z]{2,6}$";
Line 28:     public static final String NO_WHITES_SPACE_PATTERN = "\\S+";
Line 29:     public static final String NO_TRIMMING_WHITE_SPACES_PATTERN = 
"^$|\\S.*\\S";
Line 30:     public static final String IP_PATTERN =


Line 24:     public static final String ONLY_ASCII_OR_NONE = "[\\p{ASCII}]*";
Line 25:     public static final String NO_SPECIAL_CHARACTERS_WITH_DOT = 
"[0-9a-zA-Z-_\\.]+";
Line 26:     public static final String DOMAIN_NAME_PATTERN =
Line 27:             
"^([a-zA-Z0-9]([a-zA-Z0-9\\-]{0,61}[a-zA-Z0-9])?\\.)+[a-zA-Z]{2,6}$";
Line 28:     public static final String NO_WHITES_SPACE_PATTERN = "\\S+";
Done
Line 29:     public static final String NO_TRIMMING_WHITE_SPACES_PATTERN = 
"^$|\\S.*\\S";
Line 30:     public static final String IP_PATTERN =
Line 31:             
"^\\b((25[0-5]|2[0-4]\\d|[01]\\d\\d|\\d?\\d)\\.){3}(25[0-5]|2[0-4]\\d|[01]\\d\\d|\\d?\\d)\\b$|^$";
Line 32:     /** NULLABLE_MAC_ADDRESS can be valid mac address: 
xx:xx:xx:xx:xx:xx or empty string,


Line 31:             
"^\\b((25[0-5]|2[0-4]\\d|[01]\\d\\d|\\d?\\d)\\.){3}(25[0-5]|2[0-4]\\d|[01]\\d\\d|\\d?\\d)\\b$|^$";
Line 32:     /** NULLABLE_MAC_ADDRESS can be valid mac address: 
xx:xx:xx:xx:xx:xx or empty string,
Line 33:      * We need it for VMs that is not sending custom MAC address and 
we provide MAC address from
Line 34:      * the MAC pool - this values came as empty string and we don't 
want the validation fail. */
Line 35:     public static final String NULLABLE_MAC_ADDRESS = 
"^((\\d|([a-f]|[A-F])){2}:){5}(\\d|([a-f]|[A-F])){2}$|^$";
Done
Line 36:     /** Invalid mac address (for now just checking 00:00:00:00:00:00 */
Line 37:     public static final String INVALID_NULLABLE_MAC_ADDRESS = 
"^(00:){5}00$";
Line 38:     /** the mask will be replaced with zero-padded number in the 
generated names of the VMs in the pool,
Line 39:      * see NameForVmInPoolGeneratorTest PoolNameValidationTest for 
valid and invalid expressions of this pattern */


Line 40:     public static final String POOL_NAME_PATTERN = "^[\\p{L}0-9._-]+[" 
+ VmPool.MASK_CHARACTER + "]*[\\p{L}0-9._-]*$|^[\\p{L}0-9._-]*[" + 
VmPool.MASK_CHARACTER + "]*[\\p{L}0-9._-]+$";
Line 41: 
Line 42:     private static final Validator validator = 
Validation.buildDefaultValidatorFactory().getValidator();
Line 43: 
Line 44:     public static boolean containsIlegalCharacters(String s) {
Done
Line 45:         return !Pattern.matches(NO_SPECIAL_CHARACTERS, s);
Line 46:     }
Line 47: 
Line 48:     /***


-- 
To view, visit http://gerrit.ovirt.org/18544
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Ic926cf9f2944bef43fc9e80d23ba80154b9f185b
Gerrit-PatchSet: 1
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Moti Asayag <masa...@redhat.com>
Gerrit-Reviewer: Mike Kolesnik <mkole...@redhat.com>
Gerrit-Reviewer: Moti Asayag <masa...@redhat.com>
Gerrit-Reviewer: oVirt Jenkins CI Server
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
Engine-patches@ovirt.org
http://lists.ovirt.org/mailman/listinfo/engine-patches

Reply via email to