DataSeriesAxis (クラス)
public abstract DataSeriesAxis {inherits ChartAxis, Observer}
パッケージ: CURL.GUI.CHARTS
直接継承しているサブクラス: GenericDataSeriesAxis, NumericDataSeriesAxis-of, BooleanDataSeriesAxis, SimpleDateTimeAxis

1 つ以上の ChartDataSeries に基づく ChartAxis の抽象実装。

説明

このクラスを直接使用する必要があったとしても、それはまれです。ほとんどの場合は、そのサブクラス NumericDataSeriesAxis-ofGenericDataSeriesAxis、および EnumeratedBarChartAxis とやりとりします。

注意事項

1 つの DataSeriesAxis のすべての ChartDataSeries は、同じ Domain オブジェクトを (つまり、データ型も同じものを) 共有しなければなりません。

コンストラクタ
default:新しい DataSeriesAxis を初期化します。
コンストラクタ protected {DataSeriesAxis.default
label-group:ChartLabelGroup = {ChartLabelGroup},
axis-group:Shape = {ShapeGroup},
axis-line-group:Shape = {ShapeGroup},
major-tick-group:Shape = {ShapeGroup},
minor-tick-group:Shape = {ShapeGroup},
...
}

プロパティ
data:この軸を定義する ChartDataSeries を含む配列。
フィールド public constant DataSeriesAxis.data:ChartDataSeriesArray
maximum:DataSeriesAxis.data 内のすべてのデータ系列の中の最大の値。
フィールド public-get protected-set DataSeriesAxis.maximum:any
minimum:DataSeriesAxis.data 内のすべてのデータ系列の中の最低値。
フィールド public-get protected-set DataSeriesAxis.minimum:any
プロパティ 継承 ChartAxis: axis-group, axis-label, axis-line-group, chart, label-group, length, major-tick-factory, major-tick-group, minor-tick-factory, minor-tick-group, position, style-element, tick-label-factory, x-axis?, y-axis?
プロパティ 継承 ShapeGroup: clonable-class?
プロパティ 継承 Shape: as-Shape, border-color, color, draw-operation, graphical-parent, option-parent, possibly-displayed?, selection-context, shape-parent, shape-selectable, stroke-thickness, transformation, visible?
プロパティ 継承 ShapeContainerBase: as-ShapeRoot, shape-children
プロパティ 継承 Visual: _style-element, completely-clonable-children?, cursor, data-source, display-context, dragee, font-size, has-key-focus?, input-method-enabled?, input-method-keyboard-mode, name, options, style-class, style-manager, style-options, test-child?, test-description, test-name, test-parent?, test-type-name, test-visible?, tooltip, user-data, visual-parent
プロパティ 継承 DataBindingTarget: data-binding-context, data-bindings
プロパティ 継承 EventTarget: event-handlers
プロパティ 継承 OptionListInterface: option-register-proc, options-present-here, registered-option-keys

メソッド
generate-axis-label:この ChartAxis に適切な軸ラベルを生成します。
public {DataSeriesAxis.generate-axis-label}:#Shape
generate-tick-label:指定の目盛りの目盛りラベルを生成します。
public {DataSeriesAxis.generate-tick-label
tick:ChartTick,
tick-rotation:Angle
}:#Shape
get-data-type:ChartAxis の定義方法を記述します。
public {DataSeriesAxis.get-data-type}:(type:AxisDataType, value:any)
handle-observer-message:監視対象のオブジェクトがメッセージを送信するときにこのメソッドを呼び出します。Observer はこのメソッドを実装して、変更が発生したときに処理を実行する必要があります。
protected {DataSeriesAxis.handle-observer-message
sender:Observable,
message:any
}:void
non-keyword-init-arg: InitRestArgParser.process-rest-args で非キーワード引数が検出されると、呼び出されます。
public {DataSeriesAxis.non-keyword-init-arg arg:any}:void
note-min-max-computation-changed:LayeredChart.compute-data-min-max によって返される値に影響を与える要素において、変更があったことをこの ChartAxis に通知します。
public {DataSeriesAxis.note-min-max-computation-changed}:void
メソッド 継承 ChartAxis: clear-shapes, detach, generate-axis-line, generate-major-tick, generate-major-ticks, generate-minor-tick, generate-minor-ticks, get-axis-label, get-major-ticks-Iterator, get-minor-ticks-Iterator, get-position, get-position-at-zero, get-relative-position, get-tick-label, get-tick-label-alignment, get-value, get-value-relative, regenerate-shapes, transform-from-chart, transform-to-chart, update-layout
メソッド 継承 Observer: observe, stop-observing
メソッド 継承 ShapeGroup: clone-appearance-helper, draw, get-own-bounds, get-own-bounds-in-shape-root, self-contains-point?, self-intersects-polygon?
メソッド 継承 Shape: apply-rotation, apply-scale, apply-transformation, apply-translation, apply-translation-in-parent, constrain-own-layout-bounds, constrain-shape-layout-bounds, contains-point?, find-graphical-ancestor, fire-crossing-event, fire-in-child, get-display-context, get-down-orientation-in-shape-parent, get-graphical-root, get-gui-path, get-gui-path-to-child, get-local-device-pixel-size, get-origin-in-graphical-ancestor, get-origin-in-root, get-origin-in-shape-parent, get-origin-in-shape-root, get-own-layout-bounds, get-right-orientation-in-shape-parent, get-shape-bounds, get-shape-bounds-in-shape-root, get-shape-layout-bounds, get-top-left-in-ancestor, get-transformation-to-shape-root, keyword-init-arg, option-change-notify, overdraw-for-selection, quantize-line-thickness, request-draw, request-draw-self, reset-transformation, set-rotation, set-scale, set-transformation, set-translation-in-parent, to-Graphic, transform-from-display-coordinates, transform-from-graphical-root-coordinates, transform-point-from-shape-root, transform-point-to-shape-root, transform-to-display-coordinates, transform-to-graphical-root-coordinates, transform-vector-from-shape-root, transform-vector-to-shape-root, transformation-changed, transformation-changing
メソッド 継承 ShapeContainerBase: add, clear, clone-children, draw-shape-child, draw-shape-children, get-all-children-at-point, get-child-at-point, get-leaf-at-point, get-shape-root, note-attached, note-detaching, notify-option-children, on-drag-enter, on-pointer-enter, on-pointer-envelope-event, register-options, remove, set-shape-index, set-shape-index-after, set-shape-index-before, shape-container-fire-inferior-crossing-event, shape-container-handle-crossing, shape-container-pick-child, shape-container-pointer-enter-occurred, shape-container-pointer-leave-occurred
メソッド 継承 Visual: add-from-init-args, animate, change-cursor, clonable-appearance?, clone-appearance, find-test-children, get-focus-manager, get-layout-context, get-test-parent, get-test-property, get-text, get-view, maybe-fire-attach-event, maybe-fire-detach-event, note-caret-position, on-drag-leave, on-pointer-leave, pop-cursor, prepare-test-object, prepare-test-parent, push-cursor, quantize-width, refresh-style-options, release-key-focus, request-key-focus, scroll-to-include, test-record, test-run, xy-offset-to
メソッド 継承 GraphicOptions: any-to-Distance
メソッド 継承 GuiEventTarget: handle-delegate-event, handle-event, on-action, on-cancel-mode, on-command-changed, on-commit, on-composition-change-event, on-composition-result-event, on-context-menu-event, on-current-record-change-request, on-current-record-changed, on-destroy-notify, on-destroy-requested, on-drag-over, on-drag-pointer, on-drag-started, on-drop, on-end-composition-event, on-focus-event, on-focus-in, on-focus-out, on-gesture, on-gesture-begin, on-gesture-end, on-gesture-magnify, on-gesture-pan, on-gesture-rotate, on-gesture-swipe, on-gesture-tap, on-gesture-touch, on-grab-release, on-gui-event, on-input-method-event, on-inspection, on-key-event, on-key-press, on-pointer-button, on-pointer-crossing, on-pointer-event, on-pointer-motion, on-pointer-press, on-pointer-release, on-pointer-scroll, on-raw-key-event, on-raw-key-press, on-raw-key-release, on-reset, on-selectable-added, on-selectable-removed, on-selection-changed, on-selection-context-activated, on-selection-context-deactivated, on-selection-event, on-start-composition-event, on-start-event, on-stop-event, on-view-activate, on-view-deactivate, on-window-close, remove-event-handlers-for-event-class
メソッド 継承 DataBindingTarget: add-data-binding, get-data-binding, refresh-data-binding, remove-data-binding, unset-property, update-data-binding, validate-data-binding
メソッド 継承 EventTarget: accepts-event-class?, add-event-handler, event-handler-present?, remove-event-handler, verify-event
メソッド 継承 OptionListInterface: add-option, add-style-option, change-option-parent-notify, clone-options, get-option, get-option-by-name, local-add-notify, local-remove-notify, name-to-option-key, new-option-item, option-changed, option-lookup, option-lookup-here, option-propagate-notify, option-set?, propagate-option-change, remove-option, remove-style-option, remove-styles, set-option-by-name, set-style-option-by-name, unset-option-by-name, unset-style-option-by-name
メソッド 継承 BasicEventTarget: enqueue-event
メソッド 継承 InitRestArgParser: process-rest-args
メソッド 継承 Object: object-describe, object-describe-for-debugging, object-serialize



コンストラクタ詳細
default (コンストラクタ)
protected {DataSeriesAxis.default
label-group:ChartLabelGroup = {ChartLabelGroup},
axis-group:Shape = {ShapeGroup},
axis-line-group:Shape = {ShapeGroup},
major-tick-group:Shape = {ShapeGroup},
minor-tick-group:Shape = {ShapeGroup},
...
}

新しい DataSeriesAxis を初期化します。

label-group: ChartAxis.label-group の初期値。
axis-group: ChartAxis.axis-group の初期値。
axis-line-group: ChartAxis.axis-line-group の初期値。
major-tick-group: ChartAxis.major-tick-group の初期値。
minor-tick-group: ChartAxis.minor-tick-group の初期値。
...: 非キーワード引数は、この軸への追加用に ChartDataSeries とすることができます。そうでない場合、残余引数は、Shape が受け取るいずれかの引数とすることができます。これらは主に、オプションの初期化を表すキーワード引数です。

注意事項

... には少なくとも 1 つの ChartDataSeries が含まれている必要があり、含まれるすべてのデータ系列は同じ Domain と同じデータ型を使用する必要があります。



プロパティ詳細
data (フィールド)
public constant DataSeriesAxis.data:ChartDataSeriesArray

この軸を定義する ChartDataSeries を含む配列。

説明

この配列は変更しないでください。軸に関連した ChartDataSeries は、一度作成されると変更はできません。(ただしデータ自体は変更できます。)代わりに、新しい軸オブジェクトを作成します。


maximum (フィールド)
public-get protected-set DataSeriesAxis.maximum:any

DataSeriesAxis.data 内のすべてのデータ系列の中の最大の値。

説明

データが変更されると、常に Domain.compare を使用してこれが計算されます。非 null 値がデータに存在しない場合は、この値が null であることに注意してください。


minimum (フィールド)
public-get protected-set DataSeriesAxis.minimum:any

DataSeriesAxis.data 内のすべてのデータ系列の中の最低値。

説明

データが変更されると、常に Domain.compare を使用してこれが計算されます。非 null 値がデータに存在しない場合は、この値が null であることに注意してください。





メソッド詳細
generate-axis-label (メソッド)
public {DataSeriesAxis.generate-axis-label}:#Shape

この ChartAxis に適切な軸ラベルを生成します。

戻り値

ラベルを表す Shape、または null (ラベルを表示しない場合)。

説明

ChartAxis サブクラスはこのメソッドを定義する必要があります。既存の ChartAxis クラスをサブクラス化しようとする場合、このメソッドをオーバーライドすることもできます。軸ラベルの外観の制御については、ChartAxis.get-axis-label を参照してください。
作成される Shape は位置決めの必要がありません。ChartLabelGroup が、適宜その位置を軸の位置に合わせて直接に設定するからです。この位置に関するオフセットを指定したい場合、ラベル形状に必要な変換を適用して、それを ShapeGroup 内に組み込むことができます。ShapeGroup は、ChartLabelGroup で位置付けられるオブジェクトになり、組み込んだ子 Shape は、これと共に配置されます。スケーリングを使用した場合にこれを示す例については、axis-label を参照してください。
生成されたオブジェクトがその原点に対して適切に位置付けられることに注意する必要があります。原点は、軸の中央に沿って、軸自体の近くに配置され、オブジェクトの回転角度は、水平軸、垂直軸それぞれで 0 度、 -90 度になります。こうした理由で、生成した形状が意図した位置になるように (たとえば、軸および目盛りが重ならないように)、その形状を注意して位置付ける必要があります。
TextShape などのオブジェクトに関する halignhoriginなどのオプションを使用して、このことを確実にする方法については、axis-label を参照してください。

注意事項

これは通常、軸を制御するデータに依存するように実装されます。たとえば、DataSeriesAxis およびサブクラスは、そこに含まれるすべての RecordFieldRecordField.caption 値を含む TextShape が返します。


generate-tick-label (メソッド)
public {DataSeriesAxis.generate-tick-label
tick:ChartTick,
tick-rotation:Angle
}:#Shape

指定の目盛りの目盛りラベルを生成します。

tick: ラベルが作成される ChartTick
tick-rotation: 目盛りを配置する Angle。これは通常、tick-label-rotation で制御します。

戻り値

ラベルを表す Shape、または null (この値では目盛りラベルを表示しない場合)。

説明

既存の ChartAxis クラスをサブクラス化しようとする場合、このメソッドをオーバーライドできます。目盛りラベルの外観の制御については、ChartAxis.get-tick-label を参照してください。
作成される Shape は位置決めの必要がありません。ChartLabelGroup が、適宜その位置を軸の位置に合わせて直接に設定するためです。(回転とスケールは影響を受けません。)この位置に関するオフセットを指定したい場合、ラベル形状に必要な変換を適用して、それを ShapeGroup 内に組み込むことができます。ShapeGroup は、ChartLabelGroup で位置付けられるオブジェクトになり、組み込んだ子 Shape は、これと共に配置されます。軸ラベルのスケーリングを使用する同様の手法を示す例については、axis-label を参照してください。
生成されたオブジェクトがその原点に対して適切に位置付けられることに注意する必要があります。原点は、目盛りが示す方向の axis-label-group-spacing で示されたオフセットの目盛りに位置付けられるように配置されます。生成した形状が意図した位置になるように (たとえば、軸および目盛りが重ならないように)、注意して位置付ける必要があります。
TextShape などのオブジェクトに関する halignhoriginなどのオプションを使用して、このことを確実にする方法については、tick-label-factory を参照してください。

注意事項

これは通常、単に TextShape 内の ChartTick.value を表示するために実装されます。DataSeriesAxis は、Domain.format を使用して、適切な String 表現が使用されるようにするために、このメソッドをオーバーライドします。


get-data-type (メソッド)
public {DataSeriesAxis.get-data-type}:(type:AxisDataType, value:any)

ChartAxis の定義方法を記述します。

戻り値

この軸に関連するデータまたはメトリックを記述する AxisDataType およびそのメトリックを記述する値。

説明

このメソッドは、軸とデータを一致させる LayeredChart システムによって使用されます。たとえば、この軸が ChartDataSeries と直接関連付けられている場合は、これを該当するデータ系列のプロットに関連付けるのは適切です。そのため、このメソッドでは、軸内で使用されたデータ系列と一緒に AxisDataType.data-series が返されます。
次の表では、可能なそれぞれの AxisDataType について返されることが想定される値の型について説明しています。
AxisDataTypevalue記述の種類
AxisDataType.data-series{Array-of ChartDataSeries}この軸は 1 つ以上の ChartDataSeries に直接関連付けられ、その系列は返される配列に含まれます。すべてのデータ系列は同じ Domain オブジェクトを共有する必要があります。(これは、最も一般的に使用される軸のタイプです。)
AxisDataType.record-field{Array-of RecordField}この軸は、1 つ以上の RecordField に直接関連付けられます。すべてのフィールドは、同じ Domain を共有する必要があります。同じフィールドを使用していれば、データは軸に一致します。使用された RecordField が配列に返されます。
AxisDataType.field-name{Array-of String}AxisDataType.record-field と非常によく似た方法で、この軸は、名前によってレコードの 1 つ以上のレコード フィールドと関連付けられます。同じ名前のフィールドを使用していれば、データはこの軸に一致します。使用されたフィールド名が配列に返されます。
AxisDataType.typeType軸は、一定の Type を計測するものとして自身を定義します。NumericAxis-of は、このタイプの軸の例です。よりよい一致がないと、同じタイプを使用するデータがこの軸と比較されます。
AxisDataType.record-indexなし (null)この軸は、データを無視して、Record を順に配置します。このタイプの軸は、X 軸にのみ適しています。どのデータとも比較されますが、優先度が最も低い一致の種類です。DefaultChartAxis および DefaultBarChartAxis はこの種の軸の例です。


handle-observer-message (メソッド)
protected {DataSeriesAxis.handle-observer-message
sender:Observable,
message:any
}:void

監視対象のオブジェクトがメッセージを送信するときにこのメソッドを呼び出します。Observer はこのメソッドを実装して、変更が発生したときに処理を実行する必要があります。

sender: 変更があった Observable オブジェクトです。
message: これは、Observer からの変更に関する詳細情報が含まれています。詳細情報がない場合は NULL になります。


non-keyword-init-arg (メソッド)
public {DataSeriesAxis.non-keyword-init-arg arg:any}:void

InitRestArgParser.process-rest-args で非キーワード引数が検出されると、呼び出されます。

説明

Visual によるこのメソッドの実装では、最初にこのメソッドへの入力値をオブジェクトに関連するメタデータとして解釈を試みます。たとえば、オブジェクトに関連する EventHandlerDataBinding を認識してから、これらをアタッチするための適切な手順を実行することになります。
メタデータとして認識不可能な入力値は、Visual に追加される内容であると解釈され、Visual.add-from-init-args に渡されます。

オーバーライド

オブジェクトに関連付けられた追加のメタデータも受け入れるようにするには、このメソッドをオーバーライドします。実装では通常、解釈に失敗した入力値でスーパー実装が呼び出されるようにします。


note-min-max-computation-changed (メソッド)
public {DataSeriesAxis.note-min-max-computation-changed}:void

LayeredChart.compute-data-min-max によって返される値に影響を与える要素において、変更があったことをこの ChartAxis に通知します。

説明

一般的に、LayeredChart.compute-data-min-max に頼っている実装ではそれらの最小値と最大値を再計算し、レイアウトが無効にされていることを確認したくなりますが、DataSeriesAxis やそのサブクラス全てでこれを自動的に行います。その為、このメソッドを直接呼び出す必要はありません。LayeredChart.note-min-max-computation-changed から呼び出されます。
このメソッドは、データ自身が変更した場合には呼び出され ない ことに注意してください。その為、ChartDataSeries 上で Observer.observe を使用してください。
導入: バージョン 6.0