Package com.luciad.edit.features
Class FeatureEditConfigurationBuilder
java.lang.Object
com.luciad.edit.features.FeatureEditConfigurationBuilder
- All Implemented Interfaces:
AutoCloseable
This builder can be used to configure editing for a layer.
See FeatureLayer.Builder#editConfiguration.
See the related guide for more configuration options.
-
Method Summary
Modifier and TypeMethodDescriptionvoidclose()protected voidfinalize()handlesProvider(IFeatureHandlesProvider handlesProvider) Configures the handles provider that is used to provide theedit handlesfor a feature.voidDisable editing for the current feature.voidsubmit()Submits the information to this builder, and confirm that the current feature can be edited.updateMode(ModelUpdateMode updateMode) This setting gives more control over when and how often the model is updated during interactive editing.
-
Method Details
-
finalize
protected void finalize() -
close
public void close()- Specified by:
closein interfaceAutoCloseable
-
handlesProvider
@NotNull public FeatureEditConfigurationBuilder handlesProvider(@NotNull IFeatureHandlesProvider handlesProvider) throws NullPointerException Configures the handles provider that is used to provide theedit handlesfor a feature.Calling this method is optional. If this method is not called, a default implementation will be configured. See
CompositeFeatureHandlesProvider#createDefault().- Parameters:
handlesProvider- a handles provider for Features, cannot benull- Returns:
- this
- Throws:
NullPointerException- whennullis passed.
-
updateMode
This setting gives more control over when and how often the model is updated during interactive editing.It is useful to make sure that the model is updated less often when model updates are expensive, for example for models with a database backend, or other models that don't keep
Featurestate in memory.The default is
ModelUpdateMode#OnAnyChange.- Parameters:
updateMode- the update mode- Returns:
- this
-
notEditable
public void notEditable()Disable editing for the current feature.Either this method, or the
submit()method must be called.Note: you can disable editing for all features of a layer by not
configuringanIFeatureEditConfiguration. -
submit
Submits the information to this builder, and confirm that the current feature can be edited.Either this method, or the
notEditablemethod must be called.- Throws:
IllegalStateException- on an illegal state, e.g. when already submitted.
-