Package com.atlassian.adf.model.node
Class BlockCard.Datasource
- java.lang.Object
-
- com.atlassian.adf.model.node.BlockCard.CardAttributes
-
- com.atlassian.adf.model.node.BlockCard.Datasource
-
- All Implemented Interfaces:
Fold3<String,Map<String,?>,BlockCard.Datasource>
- Enclosing class:
- BlockCard
public static class BlockCard.Datasource extends BlockCard.CardAttributes
AblockCardnode withtype=datasourceis not really a normal block card. It probably should have gotten its own dedicated node type instead. Whatever the wisdom of the decision, that is not what happened, so we also have these block cards that do not act like normal block cards.
-
-
Method Summary
-
-
-
Method Detail
-
fold
public <T> T fold(Function<? super String,? extends T> ifUrl, Function<? super Map<String,?>,? extends T> ifData, Function<? super BlockCard.Datasource,? extends T> ifDatasource)
Description copied from class:BlockCard.CardAttributesTransforms the link data into a desired resulting output form. This method provides theurlvalue as a raw string without verifying that it is a valid URI.- Specified by:
foldin interfaceFold3<String,Map<String,?>,BlockCard.Datasource>- Specified by:
foldin classBlockCard.CardAttributes- Type Parameters:
T- the inferred output data type of the mappings- Parameters:
ifUrl- the mapping to be applied if the link data is in the URI format.ifData- the mapping to be applied if the link data is in JSON-LD format.ifDatasource- the mapping to be applied if the link data is in datasource format.- Returns:
- the result of applying the appropriate mapping function
-
accept
public void accept(Consumer<? super String> ifUrl, Consumer<? super Map<String,?>> ifData, Consumer<? super BlockCard.Datasource> ifDatasource)
Description copied from class:BlockCard.CardAttributesDo something with either the URI or JSON-LD data, as appropriate. This method provides theurlvalue as a raw string without verifying that it is a valid URI.- Specified by:
acceptin interfaceFold3<String,Map<String,?>,BlockCard.Datasource>- Specified by:
acceptin classBlockCard.CardAttributes- Parameters:
ifUrl- what to do with the URI if that is the form the link was provided in.ifData- what to do with the JSON-LD if that is the form the link was provided in.ifDatasource- what to do with the datasource if that is the form the link was provided in.
-
url
public BlockCard.Datasource url(@Nullable String url)
-
url
public BlockCard.Datasource url(@Nullable URL url)
-
url
public BlockCard.Datasource url(@Nullable URI url)
-
width
public BlockCard.Datasource width(@Nullable Number width)
-
layout
public Optional<RichMedia.Layout> layout()
-
layout
public BlockCard.Datasource layout(@Nullable String layout)
-
layout
public BlockCard.Datasource layout(@Nullable RichMedia.Layout layout)
-
id
public String id()
-
id
public BlockCard.Datasource id(String id)
-
parameters
public BlockCard.Datasource parameters(Map<String,?> parameters)
-
views
public List<BlockCard.View> views()
-
views
public BlockCard.Datasource views(List<BlockCard.View> views)
-
-