Package org.apache.sling.hapi
Interface MicrodataAttributeHelper
-
@ProviderType public interface MicrodataAttributeHelper
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>>allItemPropMap()Get a map of maps with the HTMl attributes for each property of the type defined through a newMicrodataAttributeHelperjava.util.Map<java.lang.String,java.lang.String>allPropTypesMap()Get a map of types for each type property.java.lang.Stringitemprop(java.lang.String propName)Callsitemprop(String, boolean)with 'withType' truejava.lang.Stringitemprop(java.lang.String propName, boolean withType)CallsitempropMap(String, boolean)and normalizes the map into a String of the form 'attr1="val1" attr2="val2"'java.util.Map<java.lang.String,java.lang.String>itempropMap(java.lang.String propName, boolean withType)Get a map with the HTMl attributes for the given property of the type defined through a newMicrodataAttributeHelperjava.lang.Stringitemtype()CallsitemtypeMap()and normalizes the map into a String of the form 'attr1="val1" attr2="val2"'java.util.Map<java.lang.String,java.lang.String>itemtypeMap()Get a map with the HTMl attributes for a new item of the type defined through a newMicrodataAttributeHelperobject
-
-
-
Method Detail
-
itemtype
java.lang.String itemtype()
CallsitemtypeMap()and normalizes the map into a String of the form 'attr1="val1" attr2="val2"'- Returns:
-
itemtypeMap
java.util.Map<java.lang.String,java.lang.String> itemtypeMap()
Get a map with the HTMl attributes for a new item of the type defined through a newMicrodataAttributeHelperobjectThe key is the HTMl attribute name and the value is the HTML attribute value
- Returns:
-
itemprop
java.lang.String itemprop(java.lang.String propName)
Callsitemprop(String, boolean)with 'withType' true- Parameters:
propName-- Returns:
-
itemprop
java.lang.String itemprop(java.lang.String propName, boolean withType)CallsitempropMap(String, boolean)and normalizes the map into a String of the form 'attr1="val1" attr2="val2"'- Parameters:
propName-withType-- Returns:
-
itempropMap
java.util.Map<java.lang.String,java.lang.String> itempropMap(java.lang.String propName, boolean withType)Get a map with the HTMl attributes for the given property of the type defined through a newMicrodataAttributeHelperThe key is the HTMl attribute name and the value is the HTML attribute value
Will through a
HApiExceptionruntime exception if the property propName does not exist for the type- Parameters:
propName- the name of the propertywithType- whether to include the 'itemtype' attribute- Returns:
-
allItemPropMap
java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> allItemPropMap()
Get a map of maps with the HTMl attributes for each property of the type defined through a newMicrodataAttributeHelperThe key is the property name and the value is a map of attributes like the one returned by
itempropMap(String, boolean)- Returns:
-
allPropTypesMap
java.util.Map<java.lang.String,java.lang.String> allPropTypesMap()
Get a map of types for each type property.The key is the property name and the value is the type path identifier of that property
- Returns:
-
-