Find Intersections

Land Desktop Map 3D Samples

 
Find Intersections
 
 
 

This method takes six arguments: an MgFeatureService object, an MgResourceIdentifier object, a schema name, a class name, a tolerance, and a limit. A limit value of 0 means find all intersections. It returns an MgBatchPropertyCollection object, which contains a collection of MgPropertyCollection objects. Each MgPropertyCollection object represents an intersection between the end point of a LineString geometry and other LineString geometries in the layer. It does the following:

  1. Uses the MgFeatureService, MgResourceIdentifier, schema name and class name arguments to get the MgClassDefinition object for the class.
  2. Gets the default geometry property name from the MgClassDefinition object
  3. Uses the MgClassDefinition object to get an MgPropertyDefinitionCollection object containing the identity properties.
  4. Continues only if there is exactly one identity property in the MgPropertyDefinitionCollection object.
  5. Makes a qualifed feature class name from the schema and class name arguments.
  6. Creates an MgBatchPropertyCollection object.
  7. Determines that the caller wants all intersections to be found and queries the feature source for intersections. This is described in topic Query the Feature Source for Intersections. Return the MgBatchPropertyCollection object modified by the operation in the referenced topic.
  8. Alternatively, determines that there is a limit on the number of intersections to be found. Uses an MgFeatureService object to count the number of features in the feature source. Uses the total feature count, the limit on the number of intersections, and a step value of 100 together with the count of features and identity number returned by the Query the Feature Source for Intersections method to create a loop expression to govern the set of features in the feature source examined for intersections. Return the MgBatchPropertyCollection object modified by the operation in the referenced topic.