nl.vpro.domain.AbstractTextualObject Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of media-domain Show documentation
Show all versions of media-domain Show documentation
The basic domain classes for 'media', the core of POMS. Also, the 'update' XML bindings for it.
It also contains some closely related domain classes like the enum to contain NICAM kijkwijzer settings.
package nl.vpro.domain;
import lombok.Getter;
import org.meeuw.functional.TriFunction;
import nl.vpro.domain.media.support.OwnerType;
import nl.vpro.domain.media.support.TextualType;
/**
* @author Michiel Meeuwissen
* @since 5.3
*/
public abstract class AbstractTextualObject>
extends AbstractTextualObjectUpdate
implements TextualObject {
@Getter
private final TriFunction ownedTitleCreator;
@Getter
private final TriFunction ownedDescriptionCreator;
public AbstractTextualObject(
TriFunction ownedTitleCreator,
TriFunction ownedDescriptionCreator) {
super(
(t, s) -> ownedTitleCreator.apply(t, DEFAULT_OWNER, s),
(t, s) -> ownedDescriptionCreator.apply(t, DEFAULT_OWNER, s)
);
this.ownedTitleCreator = ownedTitleCreator;
this.ownedDescriptionCreator = ownedDescriptionCreator;
}
}