public class BambooPluginUtils extends Object
Modifier and Type | Class and Description |
---|---|
static class |
BambooPluginUtils.Callable<V> |
static class |
BambooPluginUtils.NoThrowCallable<V> |
static class |
BambooPluginUtils.Runnable |
Modifier and Type | Field and Description |
---|---|
static String |
BAMBOO_APPLICATION_KEY |
static String |
PLUGIN_DESCRIPTOR_FILENAME |
Modifier and Type | Method and Description |
---|---|
static <T> T |
callUnsafeCode(BambooPluginUtils.Callable<T> callable)
Calls call() method on the supplied callable.
|
static Iterable<TaskDefinition> |
filterEnabledTasks(BuildContext buildContext,
String pluginKey) |
static <T extends TaskDefinition> |
filterEnabledTasks(Iterable<T> taskDefinitions,
String pluginKey) |
static Iterable<TaskDefinition> |
filterTasks(BuildContext buildContext,
String pluginKey) |
static Iterable<TaskDefinition> |
filterTasks(ImmutableJob job,
String pluginKey) |
static <T extends TaskDefinition> |
filterTasks(Iterable<T> taskDefinitions,
com.google.common.base.Predicate<TaskDefinition>... predicates) |
static Iterable<TaskDefinition> |
filterTasks(Iterable<TaskDefinition> taskDefinitions,
String pluginKey) |
static com.google.common.collect.Ordering<com.atlassian.plugin.ModuleDescriptor<?>> |
getModuleDescriptorNameOrdering() |
static <T> T |
instantiateModule(com.atlassian.plugin.ModuleDescriptor<T> md) |
static Predicate<TaskProcessCommandDecoratorModuleDescriptor> |
isTaskProcessCommandDecoratorApplicableTo(TaskIdentifier taskIdentifier) |
static Predicate<PluginKeyProvider> |
pluginKeyEquals(String pluginKey) |
static String |
prepareSubModuleConfiguration(org.dom4j.Element element,
io.atlassian.util.concurrent.ResettableLazyReference<?> reference,
String elementName,
String key,
String name,
String pluginKey)
Prepares a sub-module by finding its class name and resetting its existing
ResettableLazyReference |
public static final String BAMBOO_APPLICATION_KEY
public static final String PLUGIN_DESCRIPTOR_FILENAME
@Nullable public static <T> T callUnsafeCode(BambooPluginUtils.Callable<T> callable)
T
- callable
- a callable wrapping unsafe plugin callspublic static <T> T instantiateModule(com.atlassian.plugin.ModuleDescriptor<T> md)
public static Predicate<TaskProcessCommandDecoratorModuleDescriptor> isTaskProcessCommandDecoratorApplicableTo(@NotNull TaskIdentifier taskIdentifier)
@NotNull public static com.google.common.collect.Ordering<com.atlassian.plugin.ModuleDescriptor<?>> getModuleDescriptorNameOrdering()
public static Iterable<TaskDefinition> filterTasks(BuildContext buildContext, String pluginKey)
public static Iterable<TaskDefinition> filterEnabledTasks(BuildContext buildContext, String pluginKey)
public static Iterable<TaskDefinition> filterTasks(Iterable<TaskDefinition> taskDefinitions, String pluginKey)
public static <T extends TaskDefinition> Iterable<T> filterTasks(Iterable<T> taskDefinitions, com.google.common.base.Predicate<TaskDefinition>... predicates)
public static <T extends TaskDefinition> Iterable<T> filterEnabledTasks(Iterable<T> taskDefinitions, String pluginKey)
public static Iterable<TaskDefinition> filterTasks(ImmutableJob job, String pluginKey)
public static String prepareSubModuleConfiguration(org.dom4j.Element element, io.atlassian.util.concurrent.ResettableLazyReference<?> reference, String elementName, String key, String name, String pluginKey)
ResettableLazyReference
element
- sub-element namereference
- of the sub-moduleelementName
- of the sub-modulekey
- name
- pluginKey
- public static Predicate<PluginKeyProvider> pluginKeyEquals(String pluginKey)
Copyright © 2020 Atlassian Software Systems Pty Ltd. All rights reserved.