"prefixed with user/trusted/security/system, followed by a '.'");
} else if (prefixIndex == name.length() - 1) {
throw new HadoopIllegalArgumentException("XAttr name cannot be empty.");
}
NameSpace ns;
final String prefix = name.substring(0, prefixIndex).toLowerCase();
if (prefix.equals(NameSpace.USER.toString().toLowerCase())) {
ns = NameSpace.USER;
} else if (prefix.equals(NameSpace.TRUSTED.toString().toLowerCase())) {
ns = NameSpace.TRUSTED;