use of org.ovirt.engine.ui.uicommonweb.validation.AsciiNameValidation in project ovirt-engine by oVirt.
the class NewClusterPolicyModel method validate.
private boolean validate() {
getName().validateEntity(new IValidation[] { new NotEmptyValidation(), new LengthValidation(50), new AsciiNameValidation() });
getDescription().validateEntity(new IValidation[] { new LengthValidation(400), new AsciiOrNoneValidation() });
return getName().getIsValid() && getDescription().getIsValid() && getCustomPropertySheet().validate();
}
use of org.ovirt.engine.ui.uicommonweb.validation.AsciiNameValidation in project ovirt-engine by oVirt.
the class PosixStorageModel method validate.
@Override
public boolean validate() {
getPath().validateEntity(new IValidation[] { new NotEmptyValidation() });
getVfsType().validateEntity(new IValidation[] { new NotEmptyValidation(), new AsciiNameValidation() });
return getPath().getIsValid() && getVfsType().getIsValid();
}
use of org.ovirt.engine.ui.uicommonweb.validation.AsciiNameValidation in project ovirt-engine by oVirt.
the class ProviderModel method validate.
private boolean validate() {
getName().validateEntity(new IValidation[] { new NotEmptyValidation(), new AsciiNameValidation() });
getType().validateSelectedItem(new IValidation[] { new NotEmptyValidation() });
getNeutronAgentModel().validate();
getVmwarePropertiesModel().validate();
getKvmPropertiesModel().validate();
getXenPropertiesModel().validate();
boolean connectionSettingsValid = validateConnectionSettings();
return connectionSettingsValid && getName().getIsValid() && getType().getIsValid() && getNeutronAgentModel().getIsValid() && getKvmPropertiesModel().getIsValid() && getXenPropertiesModel().getIsValid() && getVmwarePropertiesModel().getIsValid();
}
use of org.ovirt.engine.ui.uicommonweb.validation.AsciiNameValidation in project ovirt-engine by oVirt.
the class DataCenterModel method validate.
public boolean validate() {
getName().validateEntity(new IValidation[] { new NotEmptyValidation(), new LengthValidation(40), new LengthValidation(getMaxNameLength()), new AsciiNameValidation() });
getVersion().validateSelectedItem(new IValidation[] { new NotEmptyValidation() });
getDescription().validateEntity(new IValidation[] { new AsciiOrNoneValidation() });
getComment().validateEntity(new IValidation[] { new SpecialAsciiI18NOrNoneValidation() });
boolean validationResult = getName().getIsValid() && getDescription().getIsValid() && getComment().getIsValid() && getVersion().getIsValid();
return validationResult;
}
use of org.ovirt.engine.ui.uicommonweb.validation.AsciiNameValidation in project ovirt-engine by oVirt.
the class VolumeModel method validate.
public boolean validate() {
if (!validateBrickCount()) {
setMessage(VolumeBrickModel.getValidationFailedMsg(getTypeList().getSelectedItem(), true));
return false;
}
getName().validateEntity(new IValidation[] { new NotEmptyValidation(), new LengthValidation(50), new AsciiNameValidation() });
setMessage(null);
boolean validTransportTypes = true;
if (!getTcpTransportType().getEntity() && !getRdmaTransportType().getEntity()) {
validTransportTypes = false;
setMessage(ConstantsManager.getInstance().getConstants().volumeTransportTypesValidationMsg());
}
return getName().getIsValid() && validTransportTypes;
}
Aggregations