Package org.apache.nutch.parse
Class Outlink
- java.lang.Object
-
- org.apache.nutch.parse.Outlink
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)StringgetAnchor()MapWritablegetMetadata()StringgetToUrl()inthashCode()static Outlinkread(DataInput in)voidreadFields(DataInput in)voidsetMetadata(MapWritable md)voidsetUrl(String toUrl)static voidskip(DataInput in)Skips over one Outlink in the input.StringtoString()voidwrite(DataOutput out)
-
-
-
Constructor Detail
-
Outlink
public Outlink()
-
Outlink
public Outlink(String toUrl, String anchor) throws MalformedURLException
- Throws:
MalformedURLException
-
-
Method Detail
-
readFields
public void readFields(DataInput in) throws IOException
- Specified by:
readFieldsin interfaceWritable- Throws:
IOException
-
skip
public static void skip(DataInput in) throws IOException
Skips over one Outlink in the input.- Parameters:
in- theDataInputtuple stream holding the toUrl and archor pair.- Throws:
IOException- if there is an error processing theDataInput
-
write
public void write(DataOutput out) throws IOException
- Specified by:
writein interfaceWritable- Throws:
IOException
-
read
public static Outlink read(DataInput in) throws IOException
- Throws:
IOException
-
getToUrl
public String getToUrl()
-
setUrl
public void setUrl(String toUrl)
-
getAnchor
public String getAnchor()
-
getMetadata
public MapWritable getMetadata()
-
setMetadata
public void setMetadata(MapWritable md)
-
-