public Versions(IEntryWithArchivedVersionsContract <TEntry, ArchivedObjectVersionContract> contract, IEnumTranslations translator) { ParamIs.NotNull(() => contract); Entry = contract.Entry; ArchivedVersions = contract.ArchivedVersions.Select(t => ArchivedObjectVersion.Create(t, translator)).ToArray(); }
public Versions(TEntry contract, IEnumerable <ArchivedObjectVersionContract> archivedVersions, IEnumTranslations translator) { ParamIs.NotNull(() => contract); Entry = contract; ArchivedVersions = archivedVersions.Select(t => ArchivedObjectVersion.Create(t, translator)).ToArray(); }
public ArchivedObjectVersion Version(ArchivedObjectVersionContract contract) { return(contract != null?ArchivedObjectVersion.Create(contract, EnumTranslations) : null); }