Package org.pentaho.di.imp.rules
Class BaseImportRule
java.lang.Object
org.pentaho.di.imp.rules.BaseImportRule
- All Implemented Interfaces:
Cloneable
,ImportRuleInterface
- Direct Known Subclasses:
DatabaseConfigurationImportRule
,JobHasANoteImportRule
,JobHasDescriptionImportRule
,JobHasJobLogConfiguredImportRule
,JobHasNoDisabledHopsImportRule
,TransformationHasANoteImportRule
,TransformationHasDescriptionImportRule
,TransformationHasNoDisabledHopsImportRule
,TransformationHasTransLogConfiguredImportRule
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionclone()
This returns the expected name for the composite that allows a base import rule to be edited.getId()
getXML()
boolean
boolean
isUnique()
void
void
setEnabled
(boolean enabled) void
toString()
abstract List<ImportValidationFeedback>
verifyRule
(Object subject) Validate the rule against a subject (transformation, job, database, ...)
-
Field Details
-
XML_TAG
-
-
Constructor Details
-
BaseImportRule
public BaseImportRule()
-
-
Method Details
-
clone
- Specified by:
clone
in interfaceImportRuleInterface
- Overrides:
clone
in classObject
-
isUnique
public boolean isUnique()- Specified by:
isUnique
in interfaceImportRuleInterface
- Returns:
- true if only one rule is needed in a whole set of rules. Adding another would not help. Returns false in case you can add this rule multiple times with different settings.
-
verifyRule
Description copied from interface:ImportRuleInterface
Validate the rule against a subject (transformation, job, database, ...)- Specified by:
verifyRule
in interfaceImportRuleInterface
- Parameters:
subject
- The subject to validate against- Returns:
- The feedback list consists of a series of approvals and/or warnings and/or errors.
-
getXML
- Specified by:
getXML
in interfaceImportRuleInterface
-
loadXML
- Specified by:
loadXML
in interfaceImportRuleInterface
- Throws:
org.pentaho.di.core.exception.KettleException
-
toString
-
isEnabled
public boolean isEnabled()- Specified by:
isEnabled
in interfaceImportRuleInterface
- Returns:
- the enabled
-
setEnabled
public void setEnabled(boolean enabled) - Specified by:
setEnabled
in interfaceImportRuleInterface
- Parameters:
enabled
- the enabled to set
-
getId
- Specified by:
getId
in interfaceImportRuleInterface
- Returns:
- the id
-
setId
- Specified by:
setId
in interfaceImportRuleInterface
- Parameters:
id
- the id to set
-
getCompositeClassName
This returns the expected name for the composite that allows a base import rule to be edited. The expected name is in the org.pentaho.di.ui tree and has a class name that is the name of the job entry with 'Composite' added to the end. e.g. if the import rule class name is: "org.pentaho.di.imp.rules.DatabaseConfigurationImportRule" the composite then the composite class name would be: "org.pentaho.di.ui.imp.rules.DatabaseConfigurationImportRuleComposite" If the composite class for a job entry does not match this pattern it should override this method and return the appropriate class name- Specified by:
getCompositeClassName
in interfaceImportRuleInterface
- Returns:
- full class name of the composite class
-