o.a.w.attachment.Attachment implements o.a.w.api.core.Attachment
@@ -25,15 +25,14 @@ import org.apache.wiki.api.core.Engine;
/**
* Describes an attachment. Attachments are actually derivatives of a WikiPage, since they do actually have a WikiName as well.
*/
-public class Attachment extends WikiPage {
+public class Attachment extends WikiPage implements org.apache.wiki.api.core.Attachment {
private String m_fileName;
private String m_parentName;
private boolean m_cacheable = true;
/**
- * Creates a new attachment. The final name of the attachment will be
- * a synthesis of the parent page name and the file name.
+ * Creates a new attachment. The final name of the attachment will be a synthesis of the parent page name and the file name.
*
* @param engine The Engine which is hosting this attachment.
* @param parentPage The page which will contain this attachment.
@@ -41,7 +40,6 @@ public class Attachment extends WikiPage {
*/
public Attachment( final Engine engine, final String parentPage, final String fileName ) {
super( engine, parentPage + "/" + fileName );
-
m_parentName = parentPage;
m_fileName = fileName;
}
@@ -51,7 +49,8 @@ public class Attachment extends WikiPage {
*
* @return A debugging string
*/
- @Override public String toString() {
+ @Override
+ public String toString() {
return "Attachment [" + getName() + ";mod=" + getLastModified() + "]";
}
@@ -69,8 +68,7 @@ public class Attachment extends WikiPage {
*
* @param name The name of the attachment. Must be a legal file name without the path.
*/
- public void setFileName( final String name )
- {
+ public void setFileName( final String name ) {
m_fileName = name;
}
