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

com.nhl.link.move.DeleteBuilder Maven / Gradle / Ivy

There is a newer version: 3.0.M6
Show newest version
package com.nhl.link.move;

import com.nhl.link.move.extractor.model.ExtractorName;
import org.apache.cayenne.exp.Expression;

import com.nhl.link.move.mapper.Mapper;
import org.apache.cayenne.exp.property.Property;

/**
 * since 1.3
 */
public interface DeleteBuilder {

    /**
     * Creates a new task that will delete target objects not found in the source.
     */
    LmTask task() throws IllegalStateException;

    DeleteBuilder targetFilter(Expression filter);

    default DeleteBuilder sourceMatchExtractor(String location) {
        return sourceMatchExtractor(location, ExtractorName.DEFAULT_NAME);
    }

    /**
     * Defines the location and name of the target data extractor.
     *
     * @param location extractor configuration location, relative to some root known to LinkMove.
     * @param name     extractor name within configuration.
     * @return this builder instance
     * @since 3.0
     */
    DeleteBuilder sourceMatchExtractor(String location, String name);

    DeleteBuilder matchBy(Mapper mapper);

    DeleteBuilder matchBy(String... keyAttributes);

    DeleteBuilder matchBy(Property... keyAttributes);

    DeleteBuilder matchById();

    DeleteBuilder batchSize(int batchSize);

    DeleteBuilder stageListener(Object listener);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy