Databases Reference
In-Depth Information
Custom Attributes
Custom attributes allow you to configure options that can be referenced in your plug-in callback code.
Custom attributes are already present in standard APEX objects. For example, if you create a password
page item (see Figure 2-18), its attributes are “Submit when Enter pressed” and “Does not save state”.
Figure 2-18. Password item custom attributes
There are two types of custom attributes. The following list describes them along with their
differences.
Application : Application attributes are attributes that are global for the plug-in
across the entire application. They can be configured only in the edit plug-in
page. For example, if you created a plug-in that uses a color attribute that
should be consistent across the application, you would create an application
attribute to store the color.
Component : Component attributes are attributes that are specific for an
instance of the plug-in. The password example that was previously discussed is
a good example of component attributes.
You can choose to have APEX automatically replace substitution strings if they are used in the
custom attribute value by setting the Substitute Attribute Values to Yes. For example, if a developer
entered in &APP_ID. as a value and Substitute Attribute Values was set to Yes, then the value would be
100 (assuming the application ID was 100). If you set Substitute Attribute Values to No, then you must
manually do string substitutions using apex_plugin_util.replace_substitutions .
To create either an application or component attribute, click the Add Attribute button, as shown in
Figure 2-19. Attributes are stored as type VARCHAR2 in the database, so you will need to do explicit
conversions if required. There's a limit of 15 attributes for each application and component attribute.
The following subsections describe the available options for attributes.
Figure 2-19. Custom Attributes section
 
Search WWH ::




Custom Search