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

nl.vpro.domain.api.MediaSince Maven / Gradle / Ivy

Go to download

Contains the objects used by the Frontend API, like forms and result objects

There is a newer version: 8.3.3
Show newest version
package nl.vpro.domain.api;

import lombok.AccessLevel;
import lombok.AllArgsConstructor;
import lombok.Data;

import java.time.Instant;

/**
 * @author Michiel Meeuwissen
 * @since 5.5
 */
@Data
@AllArgsConstructor(access = AccessLevel.PRIVATE)
@lombok.Builder
public class MediaSince {

    private final Instant instant;

    private final String mid;


    static Instant instant(Instant explicit, MediaSince mediaSince) {
        if (explicit != null) {
            return explicit;
        }
        return mediaSince == null ? null : mediaSince.instant;
    }

    static String mid(String explicit, MediaSince mediaSince) {
        if (explicit != null) {
            return explicit;
        }
        return mediaSince == null ? null : mediaSince.mid;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy