svn-gvsig-desktop / tags / v1_0_2_Build_915 / libraries / libFMap / src / com / iver / cit / gvsig / fmap / rendering / VectorialLegend.java @ 12217
History | View | Annotate | Download (4.44 KB)
1 | 1100 | fjp | /* gvSIG. Sistema de Informaci?n Geogr?fica de la Generalitat Valenciana
|
---|---|---|---|
2 | *
|
||
3 | * Copyright (C) 2004 IVER T.I. and Generalitat Valenciana.
|
||
4 | *
|
||
5 | * This program is free software; you can redistribute it and/or
|
||
6 | * modify it under the terms of the GNU General Public License
|
||
7 | * as published by the Free Software Foundation; either version 2
|
||
8 | * of the License, or (at your option) any later version.
|
||
9 | *
|
||
10 | * This program is distributed in the hope that it will be useful,
|
||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
13 | * GNU General Public License for more details.
|
||
14 | *
|
||
15 | * You should have received a copy of the GNU General Public License
|
||
16 | * along with this program; if not, write to the Free Software
|
||
17 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,USA.
|
||
18 | *
|
||
19 | * For more information, contact:
|
||
20 | *
|
||
21 | * Generalitat Valenciana
|
||
22 | * Conselleria d'Infraestructures i Transport
|
||
23 | * Av. Blasco Ib??ez, 50
|
||
24 | * 46010 VALENCIA
|
||
25 | * SPAIN
|
||
26 | *
|
||
27 | * +34 963862235
|
||
28 | * gvsig@gva.es
|
||
29 | * www.gvsig.gva.es
|
||
30 | *
|
||
31 | * or
|
||
32 | *
|
||
33 | * IVER T.I. S.A
|
||
34 | * Salamanca 50
|
||
35 | * 46005 Valencia
|
||
36 | * Spain
|
||
37 | *
|
||
38 | * +34 963163400
|
||
39 | * dac@iver.es
|
||
40 | */
|
||
41 | 322 | fernando | package com.iver.cit.gvsig.fmap.rendering; |
42 | |||
43 | 470 | fjp | import com.hardcode.gdbms.engine.data.DataSource; |
44 | import com.hardcode.gdbms.engine.instruction.FieldNotFoundException; |
||
45 | 1034 | vcaballero | |
46 | 651 | fernando | import com.iver.cit.gvsig.fmap.DriverException; |
47 | 2183 | fernando | import com.iver.cit.gvsig.fmap.core.IFeature; |
48 | 8765 | jjdelcerro | import com.iver.cit.gvsig.fmap.core.ISymbol; |
49 | 1034 | vcaballero | |
50 | 435 | vcaballero | import com.iver.utiles.XMLEntity; |
51 | |||
52 | |||
53 | /**
|
||
54 | 1034 | vcaballero | * Interfaz de Leyenda Vectorial.
|
55 | 435 | vcaballero | *
|
56 | * @author Vicente Caballero Navarro
|
||
57 | */
|
||
58 | 563 | fernando | public interface VectorialLegend extends Legend { |
59 | 1034 | vcaballero | /**
|
60 | * Inserta el DataSource.
|
||
61 | *
|
||
62 | * @param ds DataSource.
|
||
63 | *
|
||
64 | * @throws FieldNotFoundException cuando el campo no se encuentre.
|
||
65 | * @throws DriverException Cuando falle el driver.
|
||
66 | */
|
||
67 | void setDataSource(DataSource ds) |
||
68 | throws FieldNotFoundException, DriverException;
|
||
69 | 435 | vcaballero | |
70 | 1034 | vcaballero | /**
|
71 | * Devuelve el s?mbolo asociado al objeto que se pasa como par?metro. Si se
|
||
72 | * pasa null se devuelve el s?mbolo por defecto. En un Legend de s?mbolo
|
||
73 | * ?nico siempre se devuelve dicho s?mbolo
|
||
74 | *
|
||
75 | * @param recordIndex ?ndice
|
||
76 | *
|
||
77 | * @return S?mbolo.
|
||
78 | *
|
||
79 | * @throws DriverException
|
||
80 | */
|
||
81 | 8765 | jjdelcerro | ISymbol getSymbol(int recordIndex) throws DriverException; |
82 | 2183 | fernando | |
83 | 8765 | jjdelcerro | ISymbol getSymbolByFeature(IFeature feat); |
84 | 322 | fernando | |
85 | 1034 | vcaballero | /**
|
86 | * Devuelve el tipo de shape.
|
||
87 | *
|
||
88 | * @return Devuelve el tipo de shapes para los que est? preparada la
|
||
89 | * leyenda
|
||
90 | */
|
||
91 | int getShapeType();
|
||
92 | 585 | fjp | |
93 | 1034 | vcaballero | /**
|
94 | * Inserta el tipo de shape.
|
||
95 | *
|
||
96 | * @param shapeType Tipo de shape.
|
||
97 | */
|
||
98 | void setShapeType(int shapeType); |
||
99 | 322 | fernando | |
100 | 1034 | vcaballero | /**
|
101 | * Establece el s?mbolo por defecto del Legend. En un Legend de s?mbolo
|
||
102 | * ?nico, el s?mbolo se establece invocando este m?todo
|
||
103 | *
|
||
104 | * @param s S?mbolo por defecto.
|
||
105 | */
|
||
106 | 8765 | jjdelcerro | void setDefaultSymbol(ISymbol s);
|
107 | 322 | fernando | |
108 | 1034 | vcaballero | /**
|
109 | * Establece el campo por el que se etiqueta. -1 quita el etiquetado
|
||
110 | *
|
||
111 | * @param fieldName Nombre del campo.
|
||
112 | */
|
||
113 | void setLabelField(String fieldName); |
||
114 | 3035 | fjp | |
115 | /**
|
||
116 | * @param fieldName
|
||
117 | */
|
||
118 | void setLabelHeightField(String fieldName); |
||
119 | /**
|
||
120 | * @param fieldName
|
||
121 | */
|
||
122 | void setLabelRotationField(String fieldName); |
||
123 | 1034 | vcaballero | |
124 | /**
|
||
125 | * Obtiene el ?ndice del campo que sirve de etiquetado o -1 si no ha sido
|
||
126 | * etiquetado
|
||
127 | *
|
||
128 | * @return nombre del campo.
|
||
129 | */
|
||
130 | String getLabelField();
|
||
131 | |||
132 | /**
|
||
133 | * Devuelve el alto de campo.
|
||
134 | *
|
||
135 | * @return alto.
|
||
136 | */
|
||
137 | String getLabelHeightField();
|
||
138 | |||
139 | /**
|
||
140 | * Devuelve la rotaci?n.
|
||
141 | *
|
||
142 | * @return Rotaci?n.
|
||
143 | */
|
||
144 | String getLabelRotationField();
|
||
145 | |||
146 | /**
|
||
147 | * Devuelve el XMLEntity.
|
||
148 | *
|
||
149 | * @return XMLEntity.
|
||
150 | */
|
||
151 | XMLEntity getXMLEntity(); |
||
152 | |||
153 | /**
|
||
154 | * Inserta el XMLEntity.
|
||
155 | *
|
||
156 | * @param xml XMLEntity.
|
||
157 | */
|
||
158 | void setXMLEntity(XMLEntity xml);
|
||
159 | |||
160 | 2183 | fernando | /**
|
161 | * Inserta el XMLEntity.
|
||
162 | *
|
||
163 | * @param xml XMLEntity.
|
||
164 | */
|
||
165 | void setXMLEntity03(XMLEntity xml);
|
||
166 | |||
167 | 2414 | caballero | void useDefaultSymbol(boolean b); |
168 | 3035 | fjp | /* public boolean isBWithHeightText();
|
169 | public void setBWithHeightText(boolean withHeightText); */
|
||
170 | 1034 | vcaballero | /*
|
171 | * supplierCardinality 0..*
|
||
172 | *
|
||
173 | /*# FInterval lnkFInterval; */
|
||
174 | /*supplierCardinality 0..*
|
||
175 | *
|
||
176 | private LegendListener[] listeners;*/
|
||
177 | 2296 | fjp | |
178 | /**
|
||
179 | * Se usa para saber antes de dibujar, los campos que vamos
|
||
180 | * a necesitar leer, y leer solo estos. Acelera el dibujado
|
||
181 | * bastante, sobre todo en bases de datos espaciales.
|
||
182 | 3268 | fjp | * @return el array con los nombres de los campos usados.
|
183 | * (Por ejemplo para el etiquetado, el campo de clasificaci?n, etc)
|
||
184 | 2296 | fjp | */
|
185 | 3268 | fjp | String[] getUsedFields(); |
186 | 322 | fernando | } |