メインコンテンツ

slreportgen.report.Bus.customizeReporter

クラス: slreportgen.report.Bus
名前空間: slreportgen.report

slreportgen.report.Bus クラスのサブクラスを作成

R2021a 以降

構文

reporter = slreportgen.report.Bus.customizeReporter(classpath)

説明

reporter = slreportgen.report.Bus.customizeReporter(classpath) は、classpath で指定された場所に、slreportgen.report.Bus のサブクラスを定義するレポーター クラス定義ファイルを作成します。さらに、このメソッドは、既定のレポーター テンプレートをクラス定義ファイルが含まれるフォルダーの resources/templates サブフォルダーにコピーします。クラス定義ファイルを開始点として使用して、レポート用にカスタムの バス レポーター クラスを設計できます。

入力引数

すべて展開する

新しいクラス定義ファイルのパスと名前。文字ベクトルまたは string スカラーとして指定します。

説明
slreportgen.report.Bus.customizeReporter("myFolder/MyClass")現在のフォルダーのサブフォルダー myFolderMyClass.m を作成します。
slreportgen.report.Bus.customizeReporter("myFolder/@MyClass")

クラス名の前に @ 文字を付けて、レポーター クラスをクラス フォルダー内に作成します.m 拡張子は指定しないでください。

クラス定義を含むフォルダーを参照してください。

slreportgen.report.Bus.customizeReporter("+myOrg/@MyClass")フォルダー名の前に + 文字を付けて、レポーター クラスをクラス名前空間内に作成します。

メモ

相対パスまたは絶対パスを指定できます。

データ型: string | char

出力引数

すべて展開する

新しいレポーター クラスのパスとファイル名。string スカラーとして返されます。

すべて展開する

カスタム バス レポーター myBus とそれに関連する既定のテンプレートを現在の作業フォルダーのサブフォルダー MyFolder に作成します。

slreportgen.report.Bus.customizeReporter("MyFolder/myBus")
ans = 

    "MyFolder\myBus.m"

バージョン履歴

R2021a で導入