MySource Matrix Developer

Main Content

Files: asset.xml

This is the file where we specify our new asset details. These details described below. Use values specified in brackets.
  • package: (cms) Code name of the package this asset belongs to.
  • type_code: (better_user) Unique name for this asset.
  • version: (0.1) Asset's version. This version will be incremented when new attributes are added, or other major changes have been made. Note: 0.1 and 0.10 are two different versions.
  • name: (Better User) Name of the asset.
  • description: (A Simple asset to retrieve more information about a user) Short description about this asset. What is it for?
  • instantiable: (yes) Can we create this type of asset using Asset Map?
  • allowed_access: (backend_user) What type of user can access this asset?
  • parent_type: (user) The parent asset's type.
  • requirements: (user, version 0.1 see example below) Do we have any requirements like parent asset must be a specific version.
  • flash_menu_path: (Users) The location where this asset will appear in the Asset Map right click menu (create asset menu). This should be java_menu_path, the old Asset Map was flash and this attribute hasn't been changed since then. Why? Not telln'.
  • For this example, copy the following to asset.xml (note, each file in Matrix has a copyright header, they are not shown in this documentation).

<?xml version='1.0' encoding='UTF-8' ?>
<?xml-stylesheet href="../../asset.xsl" type="text/xsl"?>

<asset_info xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../asset.xsd">
        <package>cms</package>
        <type_code>better_user</type_code>
        <version>0.1</version>
        <name>Better User</name>
        <description>A Simple asset to retrieve more information about a user</description>
        <instantiable>yes</instantiable>
        <allowed_access>backend_user</allowed_access>
        <parent_type>user</parent_type>
        <requirements>
                <requirement type="asset">
                        <code>user</code>
                        <version>0.1</version>
                </requirement>
        </requirements>
        <flash_menu_path>Users</flash_menu_path>
</asset_info>