Search Results for

    Show / Hide Table of Contents

    Interface IDeleteFeatures

    Defines a command that deletes one or more features in a Feature Source based on some filtering criteria

    Inherited Members
    IFeatureCommand.FeatureSourceId
    IFeatureCommand.ClassName
    ICommand.Parent
    Namespace: OSGeo.MapGuide.MaestroAPI.Commands
    Assembly: OSGeo.MapGuide.MaestroAPI.dll
    Syntax
    public interface IDeleteFeatures : IFeatureCommand, ICommand
    Remarks

    This command is only supported on certain implementations of IServerConnection You can find out if the connection supports this command through the Capabilities

    Examples

    How to update all features matching a given filter to the given value

        IServerConnection conn = ...;
        IDeleteFeatures deleteCmd = (IDeleteFeatures)conn.CreateCommand((int)CommandType.DeleteFeatures);
        deleteCmd.FeatureSourceId = "Library://My.FeatureSource";
        deleteCmd.ClassName = "MyFeatureClass";
        deleteCmd.Filter = "Name = 'Bar'";
        int deleted = deleteCmd.Execute();

    Properties

    | Improve this Doc View Source

    Filter

    Gets or sets the filter that determines what features will be deleted. If empty, this will delete all features

    Declaration
    string Filter { get; set; }
    Property Value
    Type Description
    System.String

    Methods

    | Improve this Doc View Source

    Execute()

    Executes the command.

    Declaration
    int Execute()
    Returns
    Type Description
    System.Int32

    The number of features deleted

    • Improve this Doc
    • View Source
    In This Article
    Back to top Copyright © 2009 - 2022 Jackie Ng