Package org.gvsig.annotation
Interface AnnotationManager
public interface AnnotationManager
This class is responsible of the management of the library's business logic.
It is the library's main entry point, and provides all the services to manage
AnnotationCreationServices.- Version:
- $Id$
- Author:
- gvSIG team
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringName of the datastore attribute that contains the font color of the annotation.static final StringName of the datastore attribute that contains the font heigth of the annotation.static final StringName of the datastore attribute that contains the font rotation of the annotation.static final StringName of the datastore attribute that contains the font style of the annotation.static final StringName of the datastore attribute that contains the font type of the annotation.static final StringName of the datastore attribute that contains the text of the annotation. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddFontStyle(String fontStyle) It adds a new value for the font style field.voidaddFontType(String fontType) It adds a new value for the font type field.getAnnotationCreationService(org.gvsig.fmap.dal.feature.FeatureStore featureStore) Create an instance of aAnnotationCreationService.It returns an object that can be used to create the point where the annotation is displayed.It returns the defaultAnnotationPositionCalculator.intValue used like the default value for the font color field.doubleValue used like the default value for the font height field.doubleValue used like the default value for the font rotation field.Value used like the default value for the font style field.Value used like the default value for the font type field.Value used like the default value for the text field.voidregisterAnnotationPositionCalculator(String name, Class annotationPositionCalculatorClass) It registers a class that can be used to caclulate the position of an annotation.voidregisterDefaultAnnotationPositionCalculator(Class annotationPositionCalculatorClass) It registers the default implementation of anAnnotationPositionCalculatorclass.voidsetDefaultFontColor(int fontColor) Set the default value for the font color field.voidsetDefaultFontColor(Color fontColor) Set the default value for the font color field.voidsetDefaultFontHeight(double fontHeight) Set the default value for the font height field.voidsetDefaultFontRotation(double fontRotation) Set the default value for the font rotation field.voidsetDefaultFontStyle(String fontStyle) Set the default value for the font style field.voidsetDefaultFontType(String fontType) Set the default value for the font type field.voidsetDefaultTextValue(String textValue) Set the default value for the text field.
-
Field Details
-
TEXTVALUE_ATTRIBUTE_NAME
Name of the datastore attribute that contains the text of the annotation.- See Also:
-
FONTTYPE_ATTRIBUTE_NAME
Name of the datastore attribute that contains the font type of the annotation.- See Also:
-
FONTSTYLE_ATTRIBUTE_NAME
Name of the datastore attribute that contains the font style of the annotation.- See Also:
-
FONTCOLOR_ATTRIBUTE_NAME
Name of the datastore attribute that contains the font color of the annotation.- See Also:
-
FONTROTATION_ATTRIBUTE_NAME
Name of the datastore attribute that contains the font rotation of the annotation.- See Also:
-
FONTHEGTH_ATTRIBUTE_NAME
Name of the datastore attribute that contains the font heigth of the annotation.- See Also:
-
-
Method Details
-
getAnnotationCreationService
AnnotationCreationService getAnnotationCreationService(org.gvsig.fmap.dal.feature.FeatureStore featureStore) throws org.gvsig.tools.service.ServiceException Create an instance of aAnnotationCreationService.- Parameters:
the- feature store that is used like input.- Returns:
AnnotationCreationService- Throws:
org.gvsig.tools.service.ServiceException- if there is an error getting the service
-
registerAnnotationPositionCalculator
It registers a class that can be used to caclulate the position of an annotation.- Parameters:
name- The name used to register the class.annotationPositionCalculatorClass- The class that is able to calculate an annotation point.
-
registerDefaultAnnotationPositionCalculator
It registers the default implementation of anAnnotationPositionCalculatorclass. It will be used by default if the user don't specify any of them.- Parameters:
annotationPositionCalculatorClass- A class that is able to calculate an annotation point.
-
getAnnotationPositionCalculator
AnnotationPositionCalculator getAnnotationPositionCalculator(String name) throws AnnotationPositionCalculatorCreationException It returns an object that can be used to create the point where the annotation is displayed.- Parameters:
name- the name used to register the class.- Returns:
- a class that is able to calculate an annotation point.
- Throws:
AnnotationPositionCalculatorCreationException- if is not possible to create the object.
-
getDefaultAnnotationPositionCalculator
AnnotationPositionCalculator getDefaultAnnotationPositionCalculator() throws AnnotationPositionCalculatorCreationExceptionIt returns the defaultAnnotationPositionCalculator.- Returns:
- the default
AnnotationPositionCalculator. - Throws:
AnnotationPositionCalculatorCreationException- if is not possible to create the object.
-
getAnnotationPositionCalculatorList
- Returns:
- the list of the names used to register the
AnnotationPositionCalculatorclasses.
-
getDefaultTextValue
String getDefaultTextValue()Value used like the default value for the text field.- Returns:
- the default text value.
-
setDefaultTextValue
Set the default value for the text field.- Parameters:
textValue- the default text value.
-
getDefaultFontType
String getDefaultFontType()Value used like the default value for the font type field.- Returns:
- the default font type value.
-
setDefaultFontType
Set the default value for the font type field.- Parameters:
fontType- the default font type value.
-
getFontTypes
- Returns:
- the list of possible values for the font type field.
-
addFontType
It adds a new value for the font type field.- Parameters:
fontType- the new font type.
-
getDefaultFontStyle
String getDefaultFontStyle()Value used like the default value for the font style field.- Returns:
- the default font style value.
-
setDefaultFontStyle
Set the default value for the font style field.- Parameters:
fontStyle- the default font style value.
-
getFontStyles
- Returns:
- the list of possible values for the font style field.
-
addFontStyle
It adds a new value for the font style field.- Parameters:
fontStyle- the new font style.
-
getDefaultFontColor
int getDefaultFontColor()Value used like the default value for the font color field.- Returns:
- the default font color value.
-
setDefaultFontColor
void setDefaultFontColor(int fontColor) Set the default value for the font color field.- Parameters:
fontColor- the default font color value.
-
setDefaultFontColor
Set the default value for the font color field.- Parameters:
fontColor- the default font color value.
-
getDefaultFontHeight
double getDefaultFontHeight()Value used like the default value for the font height field.- Returns:
- the default font height value.
-
setDefaultFontHeight
void setDefaultFontHeight(double fontHeight) Set the default value for the font height field.- Parameters:
fontHeight- the default font height value.
-
getDefaultFontRotation
double getDefaultFontRotation()Value used like the default value for the font rotation field.- Returns:
- the default font rotation value.
-
setDefaultFontRotation
void setDefaultFontRotation(double fontRotation) Set the default value for the font rotation field.- Parameters:
fontRotation- the default font rotation value.
-