The following document contains the results of PMD's CPD 7.0.0.
File | Project | Line |
---|---|---|
com/bloomreach/forge/versionhistory/core/DocumentHistoryCleanerTask.java | BloomReach Version History Cleaner Core | 60 |
com/bloomreach/forge/versionhistory/core/DocumentHistoryTruncaterTask.java | BloomReach Version History Cleaner Core | 41 |
public DocumentHistoryCleanerTask(final Session session, final Node documentNode) throws RepositoryException { super(session); if (documentNode == null) { throw new IllegalArgumentException("document node must be not null."); } if (!documentNode.isNodeType("mix:versionable")) { throw new IllegalArgumentException("document node must be of type, mix:versionable."); } if (!documentNode.getPath().startsWith("/content/")) { throw new IllegalArgumentException("document node must be under /content/."); } if (documentNode.getPrimaryNodeType().getName().startsWith("hst:") || documentNode.getPath().startsWith("/hippo:configuration/") || documentNode.getPath().equals("/hippo:namespaces") || documentNode.getPath().startsWith("/hippo:namespaces/")) { throw new IllegalArgumentException("Not a document node, but a configuration node."); } this.documentNode = documentNode; } |