
org.integratedmodelling.utils.xml.GeoRSS Maven / Gradle / Ivy
/*******************************************************************************
* Copyright (C) 2007, 2014:
*
* - Ferdinando Villa
* - integratedmodelling.org
* - any other authors listed in @author annotations
*
* All rights reserved. This file is part of the k.LAB software suite,
* meant to enable modular, collaborative, integrated
* development of interoperable data and model components. For
* details, see http://integratedmodelling.org.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the Affero General Public License
* Version 3 or any later version.
*
* This program is distributed in the hope that it will be useful,
* but without any warranty; without even the implied warranty of
* merchantability or fitness for a particular purpose. See the
* Affero General Public License for more details.
*
* You should have received a copy of the Affero General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
* The license is also available at: https://www.gnu.org/licenses/agpl.html
*******************************************************************************/
package org.integratedmodelling.utils.xml;
import org.integratedmodelling.exceptions.KlabException;
/**
* @author Ferdinando Villa
*
*/
public class GeoRSS extends XML {
public static class GeoRSSNode extends XmlNode {
private static final long serialVersionUID = -749115666134776879L;
public GeoRSSNode href(String href) {
return (GeoRSSNode) attr("href", href);
}
}
public static GeoRSSNode feed(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "feed", objects).attr("xmlns",
"http://www.w3.org/2005/Atom").attr("xmlns:georss", "http://www.georss.org/georss");
}
public static GeoRSSNode RDF(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "rdf:RDF", objects)
.attr("xmlns:rdf", "http://www.w3.org/1999/02/22-rdf-syntax-ns#")
.attr("xmlns", "http://purl.org/rss/1.0/")
.attr("xmlns:dc", "http://purl.org/dc/elements/1.1/")
.attr("xmlns:georss", "http://www.georss.org/georss");
}
public static GeoRSSNode items(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "items", objects);
}
public static GeoRSSNode description(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "description", objects);
}
public static GeoRSSNode id(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "id", objects);
}
public static GeoRSSNode item(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "item", objects);
}
public static GeoRSSNode email(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "email", objects);
}
public static GeoRSSNode channel(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "channel", objects);
}
public static GeoRSSNode name(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "name", objects);
}
public static GeoRSSNode author(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "author", objects);
}
public static GeoRSSNode creator(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "dc:creator", objects);
}
public static GeoRSSNode date(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "dc:date", objects);
}
public static GeoRSSNode updated(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "updated", objects);
}
public static GeoRSSNode link(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "link", objects);
}
public static GeoRSSNode title(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "title", objects);
}
public static GeoRSSNode entry(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "entry", objects);
}
public static GeoRSSNode summary(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "summary", objects);
}
public static GeoRSSNode point(Object... objects) throws KlabException {
return (GeoRSSNode) node(new GeoRSSNode(), "georss:point", objects);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy