I want to set the length for a String type field,but i see the Source code:
value is reset after a call to {@link #add(String, Class)}
What is the significance of a method?How can i set the length for a String type field?anyone could help me
/**
* Sets a restriction on the field length of the next attribute added to the feature type.
*
* <p>This method is the same as adding a restriction based on length( value ) < length This
* value is reset after a call to {@link #add(String, Class)}
*
* @return length Used to limit the length of the next attribute created
*/
public SimpleFeatureTypeBuilder length(int length) {
attributeBuilder.setLength(length);
return this;
}