001 /* 002 * Copyright 1999,2004 The Apache Software Foundation. 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016 017 package org.apache.commons.feedparser; 018 019 020 /** 021 * Atom link, RSS 2.0 enclosure, and RSS 1.0 mod_link support. 022 * 023 * Note that you are given callbacks for *all* atom:link and RSS mod_link 024 * callbacks. This includes the HTML permalink URL so its important that you 025 * handle this situation as well. 026 * 027 * More info on the link mechanism: 028 * 029 * http://web.resource.org/rss/1.0/modules/link/ 030 * 031 * http://xml.com/pub/a/2004/06/16/dive.html 032 * 033 * http://www.peerfear.org/rss/permalink/2004/06/17/AtomLinkModel 034 * 035 * 036 * @author <a href="mailto:burton@apache.org">Kevin A. Burton (burtonator)</a> 037 * @version $Id: LinkFeedParserListener.java 373614 2006-01-30 22:31:21Z mvdb $ 038 */ 039 public interface LinkFeedParserListener { 040 041 /** 042 * 043 * 044 * @param length The length of the content or -1 if not specified. 045 */ 046 public void onLink( FeedParserState state, 047 String rel, 048 String type, 049 String href, 050 String title, 051 long length ) throws FeedParserException; 052 053 } 054