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

poussecafe.doc.model.boundedcontextdoc.InternalBoundedContextDocDataAccess Maven / Gradle / Ivy

There is a newer version: 0.29.0
Show newest version
package poussecafe.doc.model.boundedcontextdoc;

import poussecafe.discovery.DataAccessImplementation;
import poussecafe.storage.internal.InternalDataAccess;
import poussecafe.storage.internal.InternalStorage;

@DataAccessImplementation(
    aggregateRoot = BoundedContextDoc.class,
    dataImplementation = BoundedContextDocData.class,
    storageName = InternalStorage.NAME
)
public class InternalBoundedContextDocDataAccess extends InternalDataAccess implements BoundedContextDocDataAccess {

    @Override
    public BoundedContextDocData findByPackageNamePrefixing(String packageName) {
        return findAll()
                .stream()
                .filter(data -> packageName.startsWith(data.identifier().value().stringValue()))
                .findFirst()
                .orElse(null);
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy