java.lang.Object | |
↳ | com.sap.cloud.mobile.fiori.maps.LegendItem |
Class representing an item in the legend.
Nested Classes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
enum | LegendItem.LegendType |
Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
protected Drawable | mDrawable | ||||||||||
protected LegendItem.LegendType | mLegendType | ||||||||||
protected String | mTitle |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
LegendItem(String title, Drawable drawable)
Construct a legend item.
| |||||||||||
LegendItem(String title, Drawable drawable, LegendItem.LegendType legendType)
Construct a legend item.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
static boolean | canMerge(String title1, LegendItem.LegendType legendType1, String title2, LegendItem.LegendType legendType2) | ||||||||||
Drawable |
getDrawable()
Drawable for this legend item.
| ||||||||||
LegendItem.LegendType |
getLegendType()
Returns the legend type
| ||||||||||
String |
getTitle()
Title for this legend item.
| ||||||||||
boolean |
merge(LegendItem item1, Context context)
Merges the given legend item with the current item if possible, which is, titles are equal
and one type is POINT and another is LINE.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Construct a legend item.
title | The title for the legend item. |
---|---|
drawable | The drawable for the legend item. |
Construct a legend item.
title | The title for the legend item. |
---|---|
drawable | The drawable for the legend item. |
Merges the given legend item with the current item if possible, which is, titles are equal and one type is POINT and another is LINE. The current item's drawable will be updated after the merge. The LINE drawable must be a 2dp high drawable or an InsetDrawable which wraps a 2dp drawable.
item1 | legend item to be merged |
---|