001 /*
002 * SpacesTable.java Copyright (c) 1998-2008, The University of Sheffield.
003 *
004 * This code is from the GATE project (http://gate.ac.uk/) and is free software
005 * licenced under the GNU General Public License version 3. It is distributed
006 * without any warranty. For more details see COPYING.txt in the top level
007 * directory (or at http://gatewiki.sf.net/COPYING.txt).
008 */
009 package gate.yam.format;
010
011 /**
012 * A class to store desired min, max, norm spaces before and after the unit
013 * annotation type.
014 *
015 * @author Niraj Aswani
016 */
017 public class SpacesTable {
018 /**
019 * Minimum spaces before the annotation
020 */
021 int minSpacesBefore;
022
023 /**
024 * Maximum spaces before the annotation
025 */
026 int maxSpacesBefore;
027
028 /**
029 * Normal spaces before the annotation
030 */
031 int normSpacesBefore;
032
033 /**
034 * Minimum spaces after the annotation
035 */
036 int minSpacesAfter;
037
038 /**
039 * Maximum spaces after the annotation
040 */
041 int maxSpacesAfter;
042
043 /**
044 * Normal spaces after the annotation
045 */
046 int normSpacesAfter;
047
048 /**
049 * Constructor
050 *
051 * @param minSpacesBefore
052 * @param maxSpacesBefore
053 * @param normSpacesBefore
054 * @param minSpacesAfter
055 * @param maxSpacesAfter
056 * @param normSpacesAfter
057 */
058 public SpacesTable(int minSpacesBefore, int maxSpacesBefore,
059 int normSpacesBefore, int minSpacesAfter, int maxSpacesAfter,
060 int normSpacesAfter) {
061 super();
062 this.minSpacesBefore = minSpacesBefore;
063 this.maxSpacesBefore = maxSpacesBefore;
064 this.normSpacesBefore = normSpacesBefore;
065 this.minSpacesAfter = minSpacesAfter;
066 this.maxSpacesAfter = maxSpacesAfter;
067 this.normSpacesAfter = normSpacesAfter;
068 }
069
070 /**
071 * Returns the minimum number of desired spaces before the annotation
072 *
073 * @return
074 */
075 public int getMinSpacesBefore() {
076 return minSpacesBefore;
077 }
078
079 /**
080 * Returns the maximum number of desired spaces before the annotation
081 *
082 * @return
083 */
084 public int getMaxSpacesBefore() {
085 return maxSpacesBefore;
086 }
087
088 /**
089 * Returns the normal number of desired spaces before the annotation
090 *
091 * @return
092 */
093 public int getNormSpacesBefore() {
094 return normSpacesBefore;
095 }
096
097 /**
098 * Returns the minimum number of desired spaces after the annotation
099 *
100 * @return
101 */
102 public int getMinSpacesAfter() {
103 return minSpacesAfter;
104 }
105
106 /**
107 * Returns the maximum number of desired spaces after the annotation
108 *
109 * @return
110 */
111 public int getMaxSpacesAfter() {
112 return maxSpacesAfter;
113 }
114
115 /**
116 * Returns the normal number of desired spaces after the annotation
117 *
118 * @return
119 */
120 public int getNormSpacesAfter() {
121 return normSpacesAfter;
122 }
123 } // SpacesTable class
|