import org.argeo.slc.core.structure.tree.TreeSPath;\r
\r
/** Ant task that can be registered within a structure. */\r
-public abstract class SAwareTask extends AbstractSpringTask implements StructureElement {\r
+public abstract class SAwareTask extends AbstractSpringTask implements\r
+ StructureElement {\r
private TreeSPath path;\r
- //private final DefaultTreeSAware sAware = new DefaultTreeSAware();\r
private final List<AbstractSpringArg> sAwareArgs = new Vector<AbstractSpringArg>();\r
\r
@Override\r
}\r
}\r
\r
+ /**\r
+ * Includes this arg in the checks for propagation of sstructure related\r
+ * information.\r
+ */\r
protected void addSAwareArg(AbstractSpringArg arg) {\r
sAwareArgs.add(arg);\r
}\r
+ targetPath.listChildren(getRegistry()).size());\r
getRegistry().register(taskPath, this);\r
path = taskPath;\r
- \r
+\r
// notify registered args\r
for (AbstractSpringArg arg : sAwareArgs) {\r
Object obj = arg.getBeanInstance();\r
return projectPath.createChild(target.getName());\r
}\r
\r
+ /** Gets the path under which this task is registered. */\r
public TreeSPath getPath() {\r
return path;\r
}\r
@Override\r
public String getDescription() {\r
String description = super.getDescription();\r
- if(description==null){\r
+ if (description == null) {\r
return "<no task def>";\r
- }\r
- else{\r
+ } else {\r
return description;\r
}\r
}\r
- \r
- \r
+\r
}\r