01: /*
02: * GeoTools - OpenSource mapping toolkit
03: * http://geotools.org
04: * (C) 2003-2006, GeoTools Project Managment Committee (PMC)
05: *
06: * This library is free software; you can redistribute it and/or
07: * modify it under the terms of the GNU Lesser General Public
08: * License as published by the Free Software Foundation;
09: * version 2.1 of the License.
10: *
11: * This library is distributed in the hope that it will be useful,
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14: * Lesser General Public License for more details.
15: */
16: package org.geotools.feature;
17:
18: import org.opengis.filter.Filter;
19:
20: /**
21: * Adds the ability to have restrictions on a particular data primitive
22: * in a declarative manner.
23: *
24: * Standard expectations include internal validation using the specified
25: * restrictions, and that the restrictions are immutable.
26: *
27: * @author dzwiers
28: * @source $URL: http://svn.geotools.org/geotools/tags/2.4.1/modules/library/api/src/main/java/org/geotools/feature/PrimativeAttributeType.java $
29: */
30: public interface PrimativeAttributeType extends AttributeType {
31: /**
32: * This provides access to the immutable restriction for this attribute
33: * type. This restriction should be applied when real data hits instances
34: * of this class. This mapps to the idea of a Facet in xml schema, or
35: * restrictions in a database.
36: *
37: * Examples may include Length <= 20 (VARCHAR 20)
38: *
39: * The Default value is Filter.EXCLUDE
40: *
41: * @return the restriction for applied to this attribute type, or
42: * Filter.EXCLUDE. Mat not be null.
43: *
44: * @see Filter
45: * @see Filter#ALL
46: */
47: Filter getRestriction();
48: }
|