All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.dspace.ctask.general.NoOpCurationTask Maven / Gradle / Ivy

/**
 * The contents of this file are subject to the license and copyright
 * detailed in the LICENSE and NOTICE files at the root of the source
 * tree and available online at
 *
 * http://www.dspace.org/license/
 */
package org.dspace.ctask.general;

import org.dspace.content.DSpaceObject;
import org.dspace.content.Item;
import org.dspace.curate.AbstractCurationTask;
import org.dspace.curate.Curator;

import java.io.IOException;

public class NoOpCurationTask extends AbstractCurationTask
{

    private int status = Curator.CURATE_UNSET;
    private String result = null;

    @Override
    public int perform(DSpaceObject dso) throws IOException
    {

		if (dso instanceof Item)
        {
            Item item = (Item)dso;
            status = Curator.CURATE_SUCCESS;
            result = "No operation performed on " + item.getHandle();
            
            setResult(result);
            report(result);
		}
        
        return status;
    }


}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy