cancel
Showing results for 
Search instead for 
Did you mean: 

How to set up classpath

toltech
Champ in-the-making
Champ in-the-making
L.S.,
This might be a question often asked. I am trying to create a custom action, this is a class which extends ActionExecuterAbstractBase. My Eclipse environment is working for the SDK, however, I now need to compile this class and I have problems setting up the correct class path for my java file to compile.

Could someone give me a suggestion (or link) how to setup eclipse (or a proper classpath to compile manually) to be able to compile the code attached?
Also for the next step I could use some help: Where do I copy the class (when compiled) or how to incorporate it into alfresco.war?

This is the basic code (I only left the skeleton):

import java.util.List;
import org.alfresco.repo.action.ParameterDefinitionImpl;
import org.alfresco.service.cmr.action.Action;
import org.alfresco.service.cmr.action.ParameterDefinition;
import org.alfresco.service.cmr.dictionary.DataTypeDefinition;
import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.namespace.QName;

public class MoveReplacedActionExecuter extends ActionExecuterAbstractBase
{
    private NodeService nodeService;
   
   public void setNodeService(NodeService nodeService)
   {
      this.nodeService = nodeService;
   }

   @Override
   protected void addParameterDefinitions(List<ParameterDefinition> paramList)
   {
   }

    /**
     * @see org.alfresco.repo.action.executer.ActionExecuter#execute(org.alfresco.repo.ref.NodeRef, org.alfresco.repo.ref.NodeRef)
     */
    public void executeImpl(Action ruleAction, NodeRef actionedUponNodeRef)
    {   
    }
}
2 REPLIES 2

pmonks
Star Contributor
Star Contributor
This page should help you get started with the development process: http://wiki.alfresco.com/wiki/Alfresco_SDK.

For packaging and deploying your custom extensions, check out http://wiki.alfresco.com/wiki/AMP_Files and http://wiki.alfresco.com/wiki/Module_Management_Tool.

Cheers,
Peter

toltech
Champ in-the-making
Champ in-the-making
Thanks and apologies, the solution was staring me right in the face. I was having a late working night Smiley Happy,

I suddenly realised I need to use the embedded SDK samples, and in the "SDK CustomAction" the whole thing is spelled out. I now got my class compiled.
Sometimes you need a little side tour and a post from somebody else to get you on the right track again.

regards,
Robert