IWorksheetContent - Cells content manager

IWorksheetContent - interface to manage cells content.

IWorksheetContent depends on IWorksheet instance. IWorksheet set content into cells, change cells styles, comments and hyperlinks.

Source string will be recognized and added as value with corresponding format:

import com.intechcore.scomponents.scell.api.spreadsheet.model.IWorksheet;
import com.intechcore.scomponents.scell.api.spreadsheet.service.content.IWorksheetContent;
import com.intechcore.scomponents.scell.api.spreadsheet.service.util.IRangeAddressBuilder;

public class CustomerExamples {
    private static final CompletableFuture<Optional<IScellApiResolver>> apiResolverFuture = ScellApiProvider.getApiResolverAsync();

    public static void main(String[] args) {
        apiResolverFuture.thenAccept(apiResolverOpt -> apiResolverOpt.ifPresent(apiResolver -> {
            ISpreadsheetApiProvider coreApiProvider = apiResolver.resolve(ISpreadsheetApiProvider.class); // core API entry point
            IWorkbook newWorkbook = coreApiProvider.createNew().join();                                   // new spreadsheet
            IWorksheet worksheet = newWorkbook.all().findFirst().get();                                   // getting first worksheet
            
            IRangeAddressBuilder addressBuilder = apiResolver.resolve(IRangeAddressBuilder.class);        // getting IRangeAddressBuilder to make content calls

            IWorksheetContent worksheetContent = worksheet.getContent();                                   // getting cells content manager

            worksheetContent.inputContent(addressBuilder.setTopLeft(1, 1).buildCell(), "2022-12-12").join();// set content into A1 cell
            
        })).join();
    }
}

Other methods:

Next (Working with images)