예제 #1
0
 private static IEnumerable <AtomLink> ReplacePreviousLink(
     IEnumerable <AtomLink> links,
     UuidIri previousId)
 {
     return(links
            .Where(l => !AtomEventStream.IsPreviousFeedLink(l))
            .Concat(new[]
     {
         AtomEventStream.CreatePreviousLinkFrom(previousId)
     }));
 }
예제 #2
0
 private static AtomFeed CreatePreviousPageFrom(
     AtomFeed index,
     UuidIri previousId,
     DateTimeOffset now)
 {
     return(new AtomFeed(
                previousId,
                "Partial event stream",
                now,
                new AtomAuthor("Grean"),
                index.Entries,
                index.Links
                .Where(AtomEventStream.IsPreviousFeedLink)
                .Concat(new[]
     {
         AtomEventStream.CreateSelfLinkFrom(previousId)
     })));
 }