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

com.sap.cds.services.changeset.ChangeSetContextAccessor Maven / Gradle / Ivy

/**************************************************************************
 * (C) 2019-2024 SAP SE or an SAP affiliate company. All rights reserved. *
 **************************************************************************/
package com.sap.cds.services.changeset;

import com.sap.cds.services.runtime.ExtendedServiceLoader;

/**
 * Interface to access {@link ChangeSetContext} objects. It's preferred to use it via {@link ChangeSetContext#getCurrent()}.
 * The implementation of the factory is loaded via {@link ExtendedServiceLoader} and is therefore pluggable.
 */
public interface ChangeSetContextAccessor {

	/**
	 * @return true, if a {@link ChangeSetContext} is currently active
	 */
	boolean isActive();

	/**
	 * Gives access to the currently active {@link ChangeSetContext}.
	 * If no {@link ChangeSetContext} is currently opened this method will return null
	 *
	 * @return the currently active {@link ChangeSetContext} or null.
	 */
	ChangeSetContext getCurrent();

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy