Skip to content

MarkerStyle

Namespace: ThinkGeo.UI.Blazor

Represents the base class for all classes that defines the styles applies to markers.

public abstract class MarkerStyle

Inheritance ObjectMarkerStyle

Properties

IsActive

This property gets and sets the active status of the style.

public bool IsActive { get; set; }

Property Value

Boolean
This property gets the active status of the style.

Remarks:

If the style is not active then it will not draw.

RequiredColumnNames

This property gets the collection of fields that are required for the style.

public Collection<string> RequiredColumnNames { get; }

Property Value

Collection<String>

        This property gets the collection of fields that are required for the
        style.

Remarks:

This property gets the collection of fields that are required for the style. These are in addition to any other columns you specify in styles that inherit from this one. For example, if you have use a ValueStyle and it requires a column name for the value comparison, then that column does not need to be in this collection. You only use the RequiredColumnNames for columns you need beyond those required by specific inherited styles.

Methods

GetRequiredColumnNames()

This method returns the column data for each feature that is required for the style to properly draw.

public Collection<string> GetRequiredColumnNames()

Returns

Collection<String>
This method returns a collection of column names that the style needs.

Remarks:

This method is the concrete wrapper for the abstract method GetRequiredColumnNamesCore. In this method, we return the column names that are required for the style to draw the feature properly. For example, if you have a style that colors areas blue when a certain column value is over 100, then you need to be sure you include that column name. This will ensure that the column data is returned to you in the feature when it is ready to draw.

In many of the styles, we add properties to allow the user to specify which field they need; then, in the GetRequiredColumnNamesCore we read that property and add it to the collection.


As this is a concrete public method that wraps a Core method, we reserve the right to add events and other logic to pre- or post-process data returned by the Core version of the method. In this way, we leave our framework open on our end, but also allow you the developer to extend our logic to suit your needs. If you have questions about this, please contact our support team as we would be happy to work with you on extending our framework.

GetRequiredColumnNamesCore()

This method returns the column data for each feature that is required for the style to properly draw.

protected Collection<string> GetRequiredColumnNamesCore()

Returns

Collection<String>
This method returns a collection of column names that the style needs.

Remarks:

This abstract method is called from the concrete public method GetRequiredFieldNames. In this method, we return the column names that are required for the style to draw the feature properly. For example, if you have a style that colors areas blue when a certain column value is over 100, then you need to be sure you include that column name. This will ensure that the column data is returned to you in the feature when it is ready to draw.

In many of the styles, we add properties to allow the user to specify which field they need; then, in the GetRequiredColumnNamesCore we read that property and add it to the collection.

GetMarkers(IEnumerable<Feature>)

The abstract method returns a collection of markers from the features specified.

public abstract Collection<Marker> GetMarkers(IEnumerable<Feature> features)

Parameters

features IEnumerable<Feature>
A collection of features that the markers will be created from.

Returns

Collection<Marker>