Class AbstractOntopolyTopicMapSource

java.lang.Object
net.ontopia.topicmaps.entry.AbstractPathTopicMapSource
net.ontopia.topicmaps.entry.AbstractOntopolyTopicMapSource
All Implemented Interfaces:
FileFilter, AutoCloseable, TopicMapSourceIF
Direct Known Subclasses:
CTMPathTopicMapSource, LTMPathTopicMapSource, TMXMLPathTopicMapSource, XTMPathTopicMapSource

public abstract class AbstractOntopolyTopicMapSource extends AbstractPathTopicMapSource
INTERNAL: Common abstract superclass for sources that support what Ontopoly needs, which is full-text indexing and creation of new topic maps.
  • Field Details

    • supportsCreate

      protected boolean supportsCreate
    • supportsDelete

      protected boolean supportsDelete
    • maintainFulltextIndexes

      protected boolean maintainFulltextIndexes
    • indexDirectory

      protected String indexDirectory
    • alwaysReindexOnLoad

      protected boolean alwaysReindexOnLoad
  • Constructor Details

    • AbstractOntopolyTopicMapSource

      public AbstractOntopolyTopicMapSource()
    • AbstractOntopolyTopicMapSource

      public AbstractOntopolyTopicMapSource(String path, String suffix)
    • AbstractOntopolyTopicMapSource

      public AbstractOntopolyTopicMapSource(String path, FileFilter filter)
    • AbstractOntopolyTopicMapSource

      public AbstractOntopolyTopicMapSource(String path, String suffix, LocatorIF base_address)
    • AbstractOntopolyTopicMapSource

      public AbstractOntopolyTopicMapSource(String path, FileFilter filter, LocatorIF base_address)
  • Method Details

    • getMaintainFulltextIndexes

      public boolean getMaintainFulltextIndexes()
    • setMaintainFulltextIndexes

      public void setMaintainFulltextIndexes(boolean maintainFulltextIndexes)
    • getIndexDirectory

      public String getIndexDirectory()
    • setIndexDirectory

      public void setIndexDirectory(String indexDirectory)
    • getAlwaysReindexOnLoad

      public boolean getAlwaysReindexOnLoad()
    • setAlwaysReindexOnLoad

      public void setAlwaysReindexOnLoad(boolean alwaysReindexOnLoad)
    • supportsCreate

      public boolean supportsCreate()
      Description copied from interface: TopicMapSourceIF
      PUBLIC: Returns true if the source supports creating new topic maps with the createTopicMap.
      Specified by:
      supportsCreate in interface TopicMapSourceIF
      Overrides:
      supportsCreate in class AbstractPathTopicMapSource
    • getSupportsCreate

      public boolean getSupportsCreate()
    • setSupportsCreate

      public void setSupportsCreate(boolean supportsCreate)
    • supportsDelete

      public boolean supportsDelete()
      Description copied from interface: TopicMapSourceIF
      PUBLIC: Returns true if the source supports deleting topic map with the TopicMapReferenceIF.delete() method.
      Specified by:
      supportsDelete in interface TopicMapSourceIF
      Overrides:
      supportsDelete in class AbstractPathTopicMapSource
    • getSupportsDelete

      public boolean getSupportsDelete()
    • setSupportsDelete

      public void setSupportsDelete(boolean supportsDelete)
    • createTopicMap

      public TopicMapReferenceIF createTopicMap(String name, String baseAddress)
      Description copied from interface: TopicMapSourceIF
      PUBLIC: Creates a new topic map in the underlying source and returns a reference to the created topic map. The method takes a name and the base address for the topic map to create.
      Specified by:
      createTopicMap in interface TopicMapSourceIF
      Overrides:
      createTopicMap in class AbstractPathTopicMapSource
    • createReference

      public abstract TopicMapReferenceIF createReference(URL url, String id, String title, LocatorIF base_address)
      Specified by:
      createReference in class AbstractPathTopicMapSource
    • getWriter

      protected abstract TopicMapWriterIF getWriter(File file) throws IOException
      INTERNAL: Used by createTopicMap to serialize the new topic map.
      Throws:
      IOException