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

com.sap.cds.services.pdf.PdfExportEventContext Maven / Gradle / Ivy

There is a newer version: 3.4.1
Show newest version
/**************************************************************************
 * (C) 2019-2024 SAP SE or an SAP affiliate company. All rights reserved. *
 **************************************************************************/
package com.sap.cds.services.pdf;

import java.io.OutputStream;
import java.util.Map;

import com.sap.cds.services.EventContext;
import com.sap.cds.services.EventName;

/**
 * The {@link EventContext} used for the {@link PdfService#EVENT_EXPORT} event.
 */
@EventName(PdfService.EVENT_EXPORT)
public interface PdfExportEventContext extends EventContext {

	/**
	 * Creates an {@link EventContext} already overlayed with this interface. The
	 * event is set to be {@link PdfService#EVENT_EXPORT}
	 * 
	 * @return the {@link PdfExportEventContext}
	 */
	static PdfExportEventContext create() {
		return EventContext.create(PdfExportEventContext.class, null);
	}

	/**
	 * @return data to be exported
	 */
	Iterable> getData();

	/**
	 * @param data data to be exported
	 */
	void setData(Iterable> data);

	/**
	 * @return PDF document description
	 */
	PdfDocumentDescription getDocumentDescription();

	/**
	 * @param desc PDF document description
	 */
	void setDocumentDescription(PdfDocumentDescription desc);

	/**
	 * @return output stream to wrtie to
	 */
	OutputStream getOutputStream();

	/**
	 * @param out output stream to wrtie to
	 */
	void setOutputStream(OutputStream out);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy