public abstract class AbstractMappingRule extends java.lang.Object implements IMappingRule
Constructor and Description |
---|
AbstractMappingRule(java.io.File repository,
java.util.Map<java.lang.String,java.lang.String> attributes)
Construct a mapping rule from a GIT repository and a set of attributes
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getAttr(java.lang.String name)
Returns the value of the mapping rule attribute
|
java.lang.String |
getAttr(java.lang.String name,
java.lang.String defaultValue)
Returns the value of the mapping rule attribute
|
boolean |
getBooleanAttr(java.lang.String name)
Returns the
boolean value of the
mapping rule attribute |
boolean |
getBooleanAttr(java.lang.String name,
boolean defaultValue)
Returns the
boolean value of the
mapping rule attribute |
java.io.File |
getFileAttr(java.lang.String name) |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
generateMapping
public AbstractMappingRule(java.io.File repository, java.util.Map<java.lang.String,java.lang.String> attributes)
repository
- the name of the repositoryattributes
- the value of the attributepublic java.lang.String getAttr(java.lang.String name)
name
- the name of the attribute to look upnull
if not foundpublic java.lang.String getAttr(java.lang.String name, java.lang.String defaultValue)
name
- the name of the attribute to look updefaultValue
- the default value if the attribute is not foundnull
if not foundpublic boolean getBooleanAttr(java.lang.String name)
boolean
value of the
mapping rule attributename
- the name of the attribute to look upfalse
if not foundpublic boolean getBooleanAttr(java.lang.String name, boolean defaultValue)
boolean
value of the
mapping rule attributename
- the name of the attribute to look updefaultValue
- the default value to be returned if attribute is not foundfalse
if not foundpublic java.io.File getFileAttr(java.lang.String name)
<IBM Copyright © 2018 IBM Corp. All Rights Reserved.