Class TLcdSLDPointPlacement.Builder<T>

java.lang.Object
com.luciad.ogc.sld.model.TLcdSLDPointPlacement.Builder<T>
Enclosing class:
TLcdSLDPointPlacement

public static class TLcdSLDPointPlacement.Builder<T> extends Object
A builder for SLD an point placement. Can only be created from a text symbolizer builder: TLcdSLDTextSymbolizer.Builder.pointPlacement()
Since:
2012.1
  • Method Details

    • displacement

      public TLcdSLDPointPlacement.Builder<T> displacement(double aX, double aY)

      Sets the displacement for the point placement. The displacement defines the offset in the X and Y direction of the label with respect to the geometry. By default there is no displacement.

      It is not allowed to call this method if you have already called displacement(TLcdSLDDisplacement).

      Parameters:
      aX - An offset along the X axis in pixels.
      aY - An offset along the Y axis in pixels.
      Returns:
      This builder
    • displacement

      public TLcdSLDPointPlacement.Builder<T> displacement(TLcdSLDDisplacement aDisplacement)

      Sets the displacement for the point placement. The displacement defines the offset in the X and Y direction of the label with respect to the geometry.

      It is not allowed to call this method if you have already called displacement(double, double).

      Parameters:
      aDisplacement - The displacement. Must not be null
      Returns:
      This builder
    • anchorPoint

      public TLcdSLDPointPlacement.Builder<T> anchorPoint(double aX, double aY)

      Sets the anchor point for the point placement. An "AnchorPoint" identifies the location inside of a text label to use an an 'anchor' for positioning it relative to a point geometry. By default it is set to (0,0.5), which aligns the left side of the label horizontally, and centers the label vertically.

      It is not allowed to call this method if you have already called anchorPoint(TLcdSLDAnchorPoint).

      Parameters:
      aX - An offset along the X axis in pixels.
      aY - An offset along the Y axis in pixels.
      Returns:
      This builder
    • anchorPoint

      public TLcdSLDPointPlacement.Builder<T> anchorPoint(TLcdSLDAnchorPoint aAnchorPoint)

      Sets the anchor point for the point placement. An "AnchorPoint" identifies the location inside of a text label to use an an 'anchor' for positioning it relative to a point geometry.

      Parameters:
      aAnchorPoint - The anchor point. Must not be null
      Returns:
      This builder
    • rotation

      public TLcdSLDPointPlacement.Builder<T> rotation(double aRotation)
      Sets a label rotation in degrees. By default the rotation is equal to 0, so the label is not rotated.
      Parameters:
      aRotation - A rotation in degrees.
      Returns:
      This builder.
    • build

      public T build()

      Builds the point placement with the set parameters.

      This method can only be called once. When you used the builder to build an instance, the builder is no longer valid and should be thrown away.

      Returns:
      the resulting point placement