Main Content

partrepo.collection.build

Create MLDATX file from Simscape part files

Since R2026a

    Description

    partrepo.collection.build(inputFolder,) builds a sharable MLDATX file from the JSON data sets and collection information stored in the Datasets/ subfolder, inputFolder.

    example

    partrepo.collection.build(inputFolder,filePath) builds a sharable MLDATX file at the location specified.

    example

    Examples

    collapse all

    This example shows how build a collection that contains resistor part files. The MyResistors folder is an unbuilt collection that contains three part files for the Foundation Library Resistor block. The part files are in the Datasets folder. Build the MyResistors collection using partrepo.collection.build.

    partrepo.collection.build("MyResistors/",pwd)

    The function creates a new folder inside of the MyResistors folder called Build. The Build folder contains an MLDATX file that you can use to share or install the three resistor parts.

    Copyright 2024 The MathWorks, Inc.

    Input Arguments

    collapse all

    Location of the JSON part files to build, specified as a string scalar or character vector. The Datasets subfolder must contain at least one JSON part file and a file called CollectionInfo.json that contains the catalog ID, version, author, and description.

    Location to output the collection MLDATX file, specified as a string scalar or character vector. You can only specify this file with an .mldatx extension.

    Version History

    Introduced in R2026a