org.formaria.editor.netbeans.project.pages
Class PageSupport
java.lang.Object
org.formaria.editor.netbeans.project.pages.PageSupport
- All Implemented Interfaces:
- java.beans.PropertyChangeListener, java.util.EventListener, javax.swing.event.DocumentListener, PageCookie
public class PageSupport
- extends java.lang.Object
- implements PageCookie, javax.swing.event.DocumentListener, java.beans.PropertyChangeListener
Copyright (c) Formaria Ltd., 1998-2004
License: see license.txt
|
Constructor Summary |
PageSupport(DataObject obj,
EditorCookie edit)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PageSupport
public PageSupport(DataObject obj,
EditorCookie edit)
propertyChange
public void propertyChange(java.beans.PropertyChangeEvent evt)
- Specified by:
propertyChange in interface java.beans.PropertyChangeListener
addChangeListener
public void addChangeListener(javax.swing.event.ChangeListener l)
- Specified by:
addChangeListener in interface PageCookie
removeChangeListener
public void removeChangeListener(javax.swing.event.ChangeListener l)
- Specified by:
removeChangeListener in interface PageCookie
fireChange
protected void fireChange()
getExtension
public java.lang.String getExtension()
- Get the page extension
- Returns:
- the extension
prepare
public void prepare()
- Specified by:
prepare in interface PageCookie
isValid
public boolean isValid()
- Specified by:
isValid in interface PageCookie
changedUpdate
public void changedUpdate(javax.swing.event.DocumentEvent ev)
- Specified by:
changedUpdate in interface javax.swing.event.DocumentListener
insertUpdate
public void insertUpdate(javax.swing.event.DocumentEvent ev)
- Specified by:
insertUpdate in interface javax.swing.event.DocumentListener
removeUpdate
public void removeUpdate(javax.swing.event.DocumentEvent ev)
- Specified by:
removeUpdate in interface javax.swing.event.DocumentListener
invalidate
protected void invalidate()
setProject
public void setProject(EditorProject s)
throws java.io.IOException
- Specified by:
setProject in interface PageCookie
- Throws:
java.io.IOException
getProject
public EditorProject getProject()
throws java.io.IOException
- Specified by:
getProject in interface PageCookie
- Throws:
java.io.IOException
parse
protected PageResource parse(javax.swing.text.Document doc,
java.lang.String name,
java.lang.String ext)
- Parse the incoming document
- Parameters:
doc - the new documentpageName - the name of the file/documentext - the file name extension
generate
protected void generate(PageResource s,
javax.swing.text.Document doc)
throws javax.swing.text.BadLocationException
- Throws:
javax.swing.text.BadLocationException
getPage
public PageResource getPage()
throws java.io.IOException
- Specified by:
getPage in interface PageCookie
- Throws:
java.io.IOException
setPage
public void setPage(PageResource newPage)
throws java.io.IOException
- Specified by:
setPage in interface PageCookie
- Throws:
java.io.IOException