public class ExtractNameGenerator extends NameableNameGenerator<Extract>
Extract
items. The implementation use the NameableNameGenerator
but prefixes the node title with the name of the tag (if present).
Eg. cy3: My labeled extract
.Constructor and Description |
---|
ExtractNameGenerator(java.lang.String namePrefix,
java.lang.String titlePrefix)
Create a new name generator.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getNodeTitle(Extract item,
Node parentNode)
The base of the title is generated by the superclass.
|
getDeniedNodeName, getDeniedNodeTitle, getMissingNodeName, getMissingNodeTitle, getNodeName
public ExtractNameGenerator(java.lang.String namePrefix, java.lang.String titlePrefix)
namePrefix
- The prefix to use in node namestitlePrefix
- The prefix to use in node titlespublic java.lang.String getNodeTitle(Extract item, Node parentNode)
getNodeTitle
in interface NodeNameGenerator<Extract>
getNodeTitle
in class NameableNameGenerator<Extract>
item
- The item that is attached to the node (never null)parentNode
- The parent node of the new node