53 lines
1.3 KiB
Java
53 lines
1.3 KiB
Java
package org.gcube.informationsystem.collector.impl.resources;
|
|
|
|
import java.net.URI;
|
|
|
|
import org.w3c.dom.Document;
|
|
|
|
/**
|
|
*
|
|
* Interface for DAIXResouces' behavior
|
|
*
|
|
* @author Manuele Simi (ISTI-CNR)
|
|
*
|
|
*/
|
|
public interface DAIXResource {
|
|
|
|
public void setResourceName(String resourceName);
|
|
|
|
public String getResourceName() throws MalformedResourceException;
|
|
|
|
public URI getResourceURI();
|
|
|
|
public String toString();
|
|
|
|
public void setCollectionName(String collectionName);
|
|
|
|
public String getCollectionName() throws MalformedResourceException;
|
|
|
|
public void setContent(Document content) throws MalformedResourceException;
|
|
|
|
public void setContent(String content) throws MalformedResourceException;
|
|
|
|
public Document getContent() throws MalformedResourceException;
|
|
|
|
public boolean equals(Object obj);
|
|
|
|
public int hashCode();
|
|
|
|
|
|
/**
|
|
*
|
|
* Malformed resource exception
|
|
*
|
|
* @author Manuele Simi (ISTI-CNR)
|
|
*
|
|
*/
|
|
public static class MalformedResourceException extends Exception {
|
|
private static final long serialVersionUID = 1L;
|
|
public MalformedResourceException(Exception e) {super(e);}
|
|
public MalformedResourceException(String message) {super(message);}
|
|
}
|
|
|
|
}
|