Package hec.gfx2d

Class ViewportLayout

java.lang.Object
hec.gfx2d.ViewportLayout

public class ViewportLayout extends Object

Title: Hec Java Development

Description:

Copyright: Copyright (c) 2003

Company:

  • Field Details

  • Constructor Details

    • ViewportLayout

      public ViewportLayout()
  • Method Details

    • setViewportLegendVisible

      public void setViewportLegendVisible(boolean b)
    • isViewportLegendVisible

      public boolean isViewportLegendVisible()
    • convertAxisType

      public int convertAxisType(String axis)
    • convertAxisType

      public String convertAxisType(int axis)
      Converts from hec.geometry.Axis int axis types to ViewportLayout String axis types.
      Parameters:
      axis - An hec.geometry.Axis axis type
      Returns:
      A ViewportLayout axis type
    • setAxisType

      public void setAxisType(String axis, String type)
      Sets the type of axis to use, i.e. Linear, Log, Time etc
      Parameters:
      axis - valid values are "X1", "X2", "Y1", "Y2". The are also defined by the constants X1, X2, Y1, Y2
      type - Sets the type of axis to use, valid values are AXIS_TYPE_LINEAR, AXIS_TYPE_LOG,AXIS_TYPE_TIME, AXIS_TYPE_PROBABILITY, AXIS_TYPE_SEASONAL
    • getAxisType

      public String getAxisType(String axis)
    • isAxisReversed

      public boolean isAxisReversed(String axis)
    • setAxisReversed

      public void setAxisReversed(String axis, boolean isReversed)
    • setAxisName

      public void setAxisName(String axis, String name)
    • getAxisName

      public String getAxisName(String axis)
    • setAxisLabel

      public void setAxisLabel(String axis, String label)
    • getAxisLabel

      public String getAxisLabel(String axis)
    • hasAutoRatedAxis

      public boolean hasAutoRatedAxis()
    • setAutoRatedAxis

      public void setAutoRatedAxis(boolean b)
    • setRatingFunction

      public void setRatingFunction(double[] b1, double[] r1)
    • getRatingFunction

      public double[][] getRatingFunction()
      Returns a reference to the rating function entered with the setRatingFunction() method. Position 0 "[0][]" is the base column and position 1 [1][] is the rated column.
    • hasY1Data

      public boolean hasY1Data(String axis)
    • hasY2Data

      public boolean hasY2Data(String axis)
    • addCurve

      public void addCurve(String axis, Object data)
      Adds a data curve to either the Y1 or Y2 axis. The data object must be of either type TimeSeriesContainer, PairedDataContainer, or G2dObject
      Parameters:
      axis - either "Y1" or "Y2"
      data - the data object to add
    • addCurve

      public void addCurve(String yaxis, Object data, G2dLineProperties properties)
      Adds a data curve to the X1 - Y1/Y2 axis. The data object must be of either type TimeSeriesContainer, PairedDataContainer, or G2dObject
      Parameters:
      yaxis - either "Y1" or "Y2"
      data - the data object to add
      properties - drawing properties for the data. Can be null. If null than default properties are used.
    • addCurve

      public void addCurve(String xaxis, String yaxis, Object data, G2dLineProperties properties)
      Adds a data curve to either the X1/X2 Y1/Y2 axis. The data object must be of either type TimeSeriesContainer, PairedDataContainer, or G2dObject
      Parameters:
      xaxis - either "X1" or "X2"
      yaxis - either "Y1" or "Y2"
      data - the data object to add
      properties - drawing properties for the data. Can be null. If null than default properties are used.
    • addCurve

      public void addCurve(String yaxis, Object data, List properties)
      Adds a data curve to either the Y1 or Y2 axis. The data object must be of either type TimeSeriesContainer, PairedDataContainer, or G2dObject
      Parameters:
      yaxis - either "Y1" or "Y2"
      data - the data object to add
      properties - of drawing properties for the data. Can be null. If null than default properties are used.
    • addCurve

      public void addCurve(String xaxis, String yaxis, Object data, List properties)
      Adds a data curve to either the Y1 or Y2 axis. The data object must be of either type TimeSeriesContainer, PairedDataContainer, or G2dObject
      Parameters:
      xaxis - either "X1" or "X2"
      yaxis - either "Y1" or "Y2"
      data - the data object to add
      properties - of drawing properties for the data. Can be null. If null than default properties are used.
    • getY1Data

      public List getY1Data(String xAxis)
      Returns the list of data on the Y1 axis for a given xAxis. The data is guaranteed to be of type G2dObject
      Parameters:
      xAxis - valid values are "X1" or "X2"
      Returns:
      returns a clone of the list.
    • getY1DataProperties

      public List getY1DataProperties(String xAxis)
      Returns the Y1 Data properties for all data tied to a given X-Axis
      Parameters:
      xAxis - valid values are "X1" or "X2"
    • getY2Data

      public List getY2Data(String xAxis)
      Returns the list of data on the Y2 axis. The data is guaranteed to be of type G2dObject
      Parameters:
      xAxis - valid values are "X1" or "X2"
      Returns:
      returns a clone of the list.
    • getY2DataProperties

      public List getY2DataProperties(String xAxis)
      Returns the Y2 Data properties for all data tied to a given X-Axis
      Parameters:
      xAxis - valid values are "X1" or "X2"
    • addMarkerLine

      public void addMarkerLine(String axis, double markerValue)
    • addMarkerLine

      public void addMarkerLine(String axis, double markerValue, G2dMarkerProperties properties)
      Parameters:
      axis -
      markerValue -
      properties -
    • getY1MarkerLines

      public List getY1MarkerLines()
      Returns:
    • getY1MarklineProps

      public List getY1MarklineProps()
    • getX1MarkerLines

      public List getX1MarkerLines()
      Returns:
    • getX1MarklineProps

      public List getX1MarklineProps()
    • addMarkerPoint

      public void addMarkerPoint(G2dMarkerPointProperties markerProps)
      Parameters:
      markerProps -
    • getMarkerPoints

      public List<G2dMarkerPointProperties> getMarkerPoints()
    • getViewportLayers

      public List<ViewportLayer> getViewportLayers()
      Returns:
    • addViewportTextLayer

      public ViewportTextLayer addViewportTextLayer()