public class CrawlingActivity extends Object implements Serializable
| Modifier and Type | Class and Description |
|---|---|
static class |
CrawlingActivity.CrawlingURIState |
| Modifier and Type | Field and Description |
|---|---|
private String |
activityUri
A unique id.
|
private Calendar |
dateEnded
When the activity has ended.
|
private Calendar |
dateStarted
When the activity has started.
|
private long |
numberOfTriples |
private Map<String,org.apache.jena.rdf.model.Resource> |
outputResource
The URIs of the resources generated by this activity as well as their type as
RDF Resource.
|
private static long |
serialVersionUID |
private CrawlingActivity.CrawlingURIState |
state
The crawling state of the uri.
|
private List<String> |
steps |
private CrawleableUri |
uri
The uri for the crawling activity.
|
private String |
workerUri
URI of the worker assigned carrying out this activity.
|
| Constructor and Description |
|---|
CrawlingActivity(CrawleableUri uri,
String workerUri)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addOutputResource(String outputResource,
org.apache.jena.rdf.model.Resource resourceType) |
void |
addStep(Class<?> clazz,
String... actions) |
void |
finishActivity(Sink sink)
Finish the crawling activity and send data to sink
|
CrawleableUri |
getCrawleableUri() |
CrawlingActivity.CrawlingURIState |
getState() |
protected String |
getStepsAsString() |
CrawleableUri |
getUri() |
org.apache.jena.rdf.model.Model |
prepareMetadataModel()
Prepare the metadata model and returns it.
|
void |
setNumberOfTriples(long numberOfTriples) |
void |
setState(CrawlingActivity.CrawlingURIState state) |
private static final long serialVersionUID
private String activityUri
private Calendar dateStarted
private Calendar dateEnded
private CrawleableUri uri
private Map<String,org.apache.jena.rdf.model.Resource> outputResource
private CrawlingActivity.CrawlingURIState state
private String workerUri
private long numberOfTriples
public CrawlingActivity(CrawleableUri uri, String workerUri)
uri - the URI, which was crawledworkerUri - URI of the Worker that crawled the URIpublic void setState(CrawlingActivity.CrawlingURIState state)
public void finishActivity(Sink sink)
public org.apache.jena.rdf.model.Model prepareMetadataModel()
protected String getStepsAsString()
public CrawlingActivity.CrawlingURIState getState()
public CrawleableUri getCrawleableUri()
public CrawleableUri getUri()
public void setNumberOfTriples(long numberOfTriples)
public void addOutputResource(String outputResource, org.apache.jena.rdf.model.Resource resourceType)
Copyright © 2017–2019. All rights reserved.