public interface EditingProvider extends Provider
Modifier and Type | Method and Description |
---|---|
void |
activate()
Activete the provider
|
Geometry |
finish()
Finalizes provider.
|
void |
finishAndStore()
Finalizes provider and stores the result to
FeatureStore of this
provider. |
EditableFeature |
getDefaultFeatureValues() |
DrawingStatus |
getDrawingStatus(Point mousePosition)
Gets state of drawing.
|
java.lang.String |
getName()
Gets provider name.
|
java.util.List<EditingServiceParameter> |
getParameters()
Gets a
List with all parameters of provider. |
java.lang.Object |
getValue(EditingServiceParameter parameter)
Return parameter's value
|
java.lang.Object |
getValue(EditingServiceParameter parameter,
EditingServiceParameter.TYPE type)
Return parameter's value of type
|
void |
initDefaultValues() |
boolean |
isEnabled(EditingServiceParameter parameter)
Return true if the parameter is enabled
|
boolean |
isShowPreviewSymbol() |
boolean |
mustRestartAtFinish() |
EditingServiceParameter |
next()
Gets next parameter needed by provider.
|
void |
restart()
Restarts provider.
|
void |
setDefaultFeatureValues(EditableFeature feature) |
void |
setShowPreviewSymbol(boolean showPreviewSymbol) |
void |
setValue(EditingServiceParameter parameter,
java.lang.Object value)
Sets value into a paremeter of the provider.The value will be put in the parameter of this provider.
|
void |
setValue(java.lang.Object value)
Sets value to provider.
|
void |
start()
Starts provider.
|
void |
stop()
Stops provider.
|
setProviderServices
EditingServiceParameter next()
null
if all
parameters have values.EditingServiceParameter
object that represents the
next parameter.DrawingStatus getDrawingStatus(Point mousePosition) throws DrawServiceException
DrawingStatus
. List of
geometries of drawing status object can be different from final
geometries. Use this method to get a draft status information while user
is drawing.mousePosition
- Mouse position to draw geometries.DrawingStatus
object with a list of geometries and
information.DrawServiceException
- if there are some error creating geometries.void stop() throws StopServiceException
StopServiceException
- Stops provider initializing necessary parameters of provider.
This method is called when user cancels provider.java.util.List<EditingServiceParameter> getParameters()
List
with all parameters of provider. Each parameter
has name, description and types. See EditingServiceParameter
.EditingServiceParameter
objects.void setValue(java.lang.Object value) throws InvalidEntryException
value
- Object to be set to next EditingServiceParameter
InvalidEntryException
- If the next parameter needed does not accept this value.void setValue(EditingServiceParameter parameter, java.lang.Object value) throws InvalidEntryException
parameter
- EditingServiceParameter
value
- Object to be set to EditingServiceParameter
InvalidEntryException
- If the next parameter needed does not accept this value.boolean isEnabled(EditingServiceParameter parameter)
parameter
- Geometry finish() throws FinishServiceException
FeatureStore
. Make sure that provider has all required
values.FinishServiceException
- if there are some error getting values,
creating geometries.void finishAndStore() throws FinishServiceException
FeatureStore
of this
provider. Use this method to store the result of this service. Make sure
that service has all required values.FinishServiceException
- if there are some error getting values,
creating geometries or inserting/updating/removing geometries
from feature store.void start() throws StartServiceException, InvalidEntryException
StartServiceException
- if there are some error starting service.InvalidEntryException
- if the entry of provider is not validjava.lang.String getName()
void activate()
java.lang.Object getValue(EditingServiceParameter parameter)
parameter
- java.lang.Object getValue(EditingServiceParameter parameter, EditingServiceParameter.TYPE type)
parameter
- type
- void setDefaultFeatureValues(EditableFeature feature)
EditableFeature getDefaultFeatureValues()
void setShowPreviewSymbol(boolean showPreviewSymbol)
boolean isShowPreviewSymbol()
void restart() throws StartServiceException, InvalidEntryException, StopServiceException
StartServiceException
- if there are some error starting service.InvalidEntryException
- if the entry of provider is not validStopServiceException
void initDefaultValues()
boolean mustRestartAtFinish()