User Interface plugin modules
Build Lifecycle plugin modules
Notification plugin modules
System plugin modules

Quick Filter Rule Type module

Available:

Bamboo 5.12.0 and later

Purpose of this Module Type

This plugin module allows creating custom types of rules used within Bamboo quick filters. For more details, see the quick filters documentation.

Configuration

The root element for the Quick Filter Rule Type module is quickFilterRuleType. It allows the following attributes and child elements for configuration:

Attributes

Name

Description

class

The class which implements this plugin module. The class you need to provide depends on the module type. For example, Confluence theme, layout and colour-scheme modules can use classes already provided in Confluence. So you can write a theme-plugin without any Java code. But for macro and listener modules you need to write your own implementing class and include it in your plugin. See the plugin framework guide to creating plugin module instances.

Required: yes

Default: N/A

key

The unique identifier of the plugin module. You refer to this key to use the resource from other contexts in your plugin, such as from the plugin Java code or JavaScript resources.

1
2
<component-import
key="appProps"
interface="com.atlassian.sal.api.ApplicationProperties"/>

In the example, appProps is the key for this particular module declaration, for component-import, in this case.

Required: yes

Default: N/A

Elements

Name

Description

resource

Using the "edit" attribute it is possible to provide a template for editing your rule type configuration.

Required: yes

Default: N/A

Interface

Quick Filter Rule Type modules must implement the QuickFilterRuleType interface. Modules may also extend AbstractQuickFilterRuleType for additional utilities. However, the latter is not part of Bamboo API and may change without notice.

Example

Plugin Descriptor

Here is an example atlassian-plugin.xml file containing a Quick Filter Rule Type module:

1
2
<atlassian-plugin name="Quick Filter Rule Type module test" key="quickFilter.ruleType.test"> 
  <plugin-info> 
    <description>Quick Filter Rule Type module test</description> 
    <vendor name="Atlassian Software Systems" url="http://www.atlassian.com"/> 
    <version>1.0</version> 
  </plugin-info> 

  <!-- rule type matching plan's name against a regular expression -->
  <quickFilterRuleType key="bamboo.quickFilter.rules.nameMatcher" class="com.atlassian.bamboo.quickfilter.rule.plugin.NameMatcherRuleType">
    <resource type="freemarker" name="edit" location="com/atlassian/bamboo/quickfilter/rule/editNameMatcherRule.ftl"/>
  </quickFilterRuleType>
</atlassian-plugin> 

Freemarker Edit Template

1
2
[@s.textfield labelKey='quick.filters.rules.plugin.nameMatcher.regex'
    name='quick.filters.rules.plugin.nameMatcher.regex'
    cssClass="long-field"
    required=true /]

Rate this page: