Open mpgirro opened 3 years ago
We can also extend this by providing creation methods in the companion for convenience:
const val SELF_REL = "self"
fun createSelfRelation(
val href: String,
val hrefLang: String? = null,
val hrefResolved: String? = null,
val length: String? = null,
val title: String? = null,
val type: MediaType? = null
) = Link(href, hrefLang, hrefResolved, length, title, SELF_REL, title, type)
76 already proposes accessor methods for Atom link elements for RFC 5005 support. There are more link relations encountered in feeds (most are IANA registered), so I propose to extend the concept to other
rel
values relevant for podcast feeds. These are the link relations I know of right now:self
alternate
first
last
previous
next
prev-archive
next-archive
current
payment
hub
http://podlove.org/simple-chapters
http://podlove.org/deep-link
replies
search
related
Accessor methods should be exposed in the Atom
Link
companion object. The feed history companion can then simply delegate to the Atom methods.I'll also add this to the scrapper to find out if there are more link relations around.