ACE Adding Resources to Meta Class

Table of Contents

Adding Resources to Meta Class

Javascript, CSS and image resources fall into two different categories:

  • Intrinsic resources, which are required for the component to properly function. These need to always be in the page when the component is in use, so we automate that dependency by adding @ResourceDependency annotations to the Meta class, which cause the resources to be loaded into the page whenever the component is in use. This can include Javascript files, as well as CSS files. The image resources would be referenced from the CSS files. This current page describes how to add intrinsic resources.
  • Skin resources, which might only be included in the page when that particular skin is currently being used. Since they're only conditionally used, they are not referenced from the Meta class, and are instead included via the standard skinning mechanism in your application. These would consist of CSS files, and the image files that they reference. For detailed information on how skins are made, review this page.


1. The intrinsic resources should be placed in the appropriate location

Intrinsic Resources

Using the TabSet component as an example

TabSet Intrinsic Resources

2. @ResourceDependency annotations, corresponding to the resources, should be added to the Meta class

TabSetMeta Class
public class TabSetMeta extends UIComponentBaseMeta { ... }

3. The build process places the resources in the META-INF directory of the JAR

Built Resources
Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.

© Copyright 2021 ICEsoft Technologies Canada Corp.