GLMapVectorLayer

Objective-C


@interface GLMapVectorLayer : GLMapDrawable

Swift

class GLMapVectorLayer : GLMapDrawable

GLMapVectorLayer is used to draw multiple vector objects on the map.

  • Initializes an empty vector layer that will be displayed with the given drawOrder.

    Declaration

    Objective-C

    - (instancetype _Nonnull)initWithDrawOrder:(int32_t)drawOrder;

    Swift

    init(drawOrder: Int32)

    Parameters

    drawOrder

    The draw order of the object.

  • Initializes an image that will be injected into the map tile data (for example, you can set a vector object that can be displayed under map elements).

    Declaration

    Objective-C

    - (instancetype _Nonnull)init;

    Swift

    init()
  • Sets the vector object to draw.

    Declaration

    Objective-C

    - (void)setVectorObject:(GLMapVectorObject *_Nonnull)object
                  withStyle:(GLMapVectorCascadeStyle *_Nonnull)style
                 completion:(dispatch_block_t _Nullable)completion;

    Swift

    func setVectorObject(_ object: GLMapVectorObject, with style: GLMapVectorCascadeStyle) async

    Parameters

    object

    The object to draw.

    style

    The style of the object.

    completion

    A block called when the object is ready to draw.

  • Sets the vector objects to draw.

    Declaration

    Objective-C

    - (void)setVectorObjects:(GLMapVectorObjectArray *_Nonnull)objects
                   withStyle:(GLMapVectorCascadeStyle *_Nonnull)style
                  completion:(dispatch_block_t _Nullable)completion;

    Swift

    func setVectorObjects(_ objects: GLMapVectorObjectArray, with style: GLMapVectorCascadeStyle) async

    Parameters

    objects

    The objects to draw.

    style

    The style of the objects.

    completion

    A block called when the objects are ready to draw.