Library
Module
Module type
Parameter
Class
Class type
Implementation of the ATOM specification, documented here: specs.
Types that briefly describe the Atom specification.
A Text construct contains human-readable text, usually in small quantities. The content of Text constructs is Language-Sensitive.
Define the kind of a link. Formally the rel
attribute.
Defines a reference from an entry or feed to a Web resource. This specification assigns no meaning to the content (if any) of this element.
If an entry is copied from one feed into another feed, then the source feed's metadata (all child elements of feed other than the atom:entry elements) MAY be preserved within the copied entry by adding an source child element, if it is not already present in the entry, and including some or all of the source feed's Metadata elements as the source element's children. Such metadata SHOULD be preserved if the source feed contains any of the child elements author, contributor, rights, or category and those child elements are not present in the source entry.
The content element either contains or links to the content of the entry. The content of atom:content is Language-Sensitive.
The "entry" element represents an individual entry, acting as a container for metadata and data associated with the entry. This element can appear as a child of the feed element, or it can appear as the document (i.e., top-level) element of a stand-alone Atom Entry Document.
A Text construct contains human-readable text, usually in small quantities. The content of Text constructs is Language-Sensitive.
val text : string -> text_construct
text s
constructs an element of type text_construct
textual.
val html : string -> text_construct
html s
constructs an element of type text_construct
HTML.
val xhtml : ?need_prefix:bool -> Xml.node -> text_construct
xhtml ?need_prefix s
constructs an element of type text_construct
XHTML. If need_prefix
is true
, every children of the given node will be prefixed by the xhtml
namespace.
Defines a reference from an entry or feed to a Web resource. This specification assigns no meaning to the content (if any) of this element.
val link :
?rel:link_rel ->
?media_type:Media_type.t ->
?hreflang:string ->
?length:int ->
?title:string ->
string ->
link
Constructs a link (an external source).
val alternate :
?media_type:Media_type.t ->
?hreflang:string ->
?length:int ->
?title:string ->
string ->
link
alternate
is link ~rel:Alternate
.
related
is link ~rel:related
.
val self :
?media_type:Media_type.t ->
?hreflang:string ->
?length:int ->
?title:string ->
string ->
link
self
is link ~rel:Self
.
val enclosure :
?media_type:Media_type.t ->
?hreflang:string ->
?length:int ->
?title:string ->
string ->
link
enclosure
is link ~rel:enclosure
.
val via :
?media_type:Media_type.t ->
?hreflang:string ->
?length:int ->
?title:string ->
string ->
link
via
is link ~rel:Via
.
If an entry is copied from one feed into another feed, then the source feed's metadata (all child elements of feed other than the entry elements) MAY be preserved within the copied entry by adding an source child element, if it is not already present in the entry, and including some or all of the source feed's Metadata elements as the source element's children. Such metadata SHOULD be preserved if the source feed contains any of the child elements author, contributor, rights, or category and those child elements are not present in the source entry.
val source :
?subtitle:text_construct ->
?contributors:Person.t list ->
?categories:Category.t list ->
?generator:Generator.t option ->
?icon:string ->
?logo:string ->
?links:link list ->
?rights:text_construct ->
?updated:Datetime.t ->
?title:text_construct ->
?authors:Person.t list ->
?id:string ->
unit ->
source
Construct a source
.
The content element either contains or links to the content of the entry. The content of content is Language-Sensitive.
val content_text : string -> content
content_text s
constructs a textual content.
val content_html : string -> content
content_html s
constructs an HTML content.
content_xhtml ?need_prefix s
constructs an XHTML content (like xhtml
).
val content_mime : ?media_type:Media_type.t -> string -> content
content_mime ?media_type value
constructs a mime content.
val content_src : ?media_type:Media_type.t -> string -> content
content_src ?media_type uri
constructs a source content.
The "entry" element represents an individual entry, acting as a container for metadata and data associated with the entry. This element can appear as a child of the feed element, or it can appear as the document (i.e., top-level) element of a stand-alone Atom Entry Document.
val entry :
?authors:Person.t list ->
?contributors:Person.t list ->
?links:link list ->
?categories:Category.t list ->
?published:Datetime.t ->
?rights:text_construct ->
?source:source ->
?summary:text_construct ->
?content:content ->
title:text_construct ->
id:string ->
updated:Datetime.t ->
unit ->
entry
Constructs an entry.
val updated_from_entries :
?default_value:Datetime.t ->
unit ->
updated_strategy
Uses entries to describe the last update date. If no entry is provided, the date provisioned by default_value
will be used.
val updated_given : Datetime.t -> updated_strategy
Use a fixed updated
value.
val feed :
?encoding:string ->
?standalone:bool ->
?subtitle:text_construct ->
?contributors:Person.t list ->
?categories:Category.t list ->
?generator:Generator.t option ->
?icon:string ->
?logo:string ->
?links:link list ->
?rights:text_construct ->
updated:updated_strategy ->
title:text_construct ->
authors:Person.t Yocaml.Nel.t ->
id:string ->
('a -> entry) ->
'a list ->
Xml.t
Build an Atom feed.
val from :
?encoding:string ->
?standalone:bool ->
?subtitle:text_construct ->
?contributors:Person.t list ->
?categories:Category.t list ->
?generator:Generator.t option ->
?icon:string ->
?logo:string ->
?links:link list ->
?rights:text_construct ->
updated:updated_strategy ->
title:text_construct ->
authors:Person.t Yocaml.Nel.t ->
id:string ->
('a -> entry) ->
('a list, string) Yocaml.Task.t
An arrow that build a feed that from an arbitrary list.
val from_articles :
?encoding:string ->
?standalone:bool ->
?subtitle:text_construct ->
?contributors:Person.t list ->
?categories:Category.t list ->
?generator:Generator.t option ->
?icon:string ->
?logo:string ->
?links:link list ->
?rights:text_construct ->
?updated:updated_strategy ->
?id:string ->
site_url:string ->
feed_url:string ->
title:text_construct ->
authors:Person.t Yocaml.Nel.t ->
unit ->
((Yocaml.Path.t * Yocaml.Archetype.Article.t) list, string) Yocaml.Task.t
An arrow that build a feed that fit with Yocaml.Archetype.Articles.fetch
. link
is concatenate with the given path
to compute the url
of an item.