|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.ontopia.topicmaps.entry.AbstractPathTopicMapSource
public abstract class AbstractPathTopicMapSource
INTERNAL: Abstract class implementing TopicMapSourceIF; locates topic map file references from a given directory on the local file system. Only files that match the given suffix are used.
| Field Summary | |
|---|---|
protected LocatorIF |
base_address
|
protected boolean |
duplicate_suppression
|
protected boolean |
hidden
|
protected String |
id
|
protected String |
path
|
protected Map<String,TopicMapReferenceIF> |
refmap
|
protected String |
suffix
|
protected String |
title
|
| Constructor Summary | |
|---|---|
AbstractPathTopicMapSource()
|
|
AbstractPathTopicMapSource(String path,
FileFilter filter)
|
|
AbstractPathTopicMapSource(String path,
FileFilter filter,
LocatorIF base_address)
|
|
AbstractPathTopicMapSource(String path,
String suffix)
|
|
AbstractPathTopicMapSource(String path,
String suffix,
LocatorIF base_address)
|
|
| Method Summary | |
|---|---|
boolean |
accept(File file)
INTERNAL: A file filter method implementation. |
protected TopicMapReferenceIF |
createReference(URL url,
String id,
String title)
|
protected abstract TopicMapReferenceIF |
createReference(URL url,
String id,
String title,
LocatorIF base_address)
|
TopicMapReferenceIF |
createTopicMap(String name,
String baseAddress)
PUBLIC: Creates a new topic map in the underlying source and returns a reference to the created topic map. |
LocatorIF |
getBase()
INTERNAL: Gets the base locator of the topic maps retrieved from the source. |
String |
getBaseAddress()
INTERNAL: Gets the base address of the topic maps retrieved from the source. |
boolean |
getDuplicateSuppression()
INTERNAL: Gets the duplicate suppression flag. |
FileFilter |
getFileFilter()
INTERNAL: Returns the FileFilter used to in the specified path. |
boolean |
getHidden()
|
String |
getId()
PUBLIC: Gets the id of the source. |
String |
getPath()
INTERNAL: Gets the path in which the source locates its references. |
Collection<TopicMapReferenceIF> |
getReferences()
PUBLIC: Returns an unmodifiable collection of TopicMapReferenceIFs found by the topic map source. |
String |
getSuffix()
INTERNAL: Gets the file suffix that should be used for filtering. |
String |
getTitle()
PUBLIC: Gets the title of the source. |
void |
refresh()
PUBLIC: Refreshes the collection of references. |
protected Map |
refreshFromClasspath()
|
protected Map<String,TopicMapReferenceIF> |
refreshFromFilesystem()
|
void |
setBase(LocatorIF base_address)
INTERNAL: Sets the base locator of the topic maps retrieved from the source. |
void |
setBaseAddress(String base_address)
INTERNAL: Sets the base address of the topic maps retrieved from the source. |
void |
setDuplicateSuppression(boolean duplicate_suppression)
INTERNAL: Sets the duplicate suppression flag. |
void |
setFileFilter(FileFilter filter)
INTERNAL: Sets a FileFilter used to filter the files in the specified path. |
void |
setHidden(boolean hidden)
|
void |
setId(String id)
PUBLIC: Sets the id of the source. |
void |
setPath(String path)
INTERNAL: Sets the path in which the source locates its references. |
void |
setSuffix(String suffix)
INTERNAL: Sets the file suffix that should be used for filtering. |
void |
setTitle(String title)
PUBLIC: Sets the title of the source. |
boolean |
supportsCreate()
PUBLIC: Returns true if the source supports creating new topic maps with the createTopicMap. |
boolean |
supportsDelete()
PUBLIC: Returns true if the source supports deleting topic map with the TopicMapReferenceIF.delete() method. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected String id
protected String title
protected String path
protected String suffix
protected LocatorIF base_address
protected boolean duplicate_suppression
protected boolean hidden
protected Map<String,TopicMapReferenceIF> refmap
| Constructor Detail |
|---|
public AbstractPathTopicMapSource()
public AbstractPathTopicMapSource(String path,
String suffix)
public AbstractPathTopicMapSource(String path,
FileFilter filter)
public AbstractPathTopicMapSource(String path,
String suffix,
LocatorIF base_address)
public AbstractPathTopicMapSource(String path,
FileFilter filter,
LocatorIF base_address)
| Method Detail |
|---|
public String getId()
TopicMapSourceIF
getId in interface TopicMapSourceIFpublic void setId(String id)
TopicMapSourceIFUnsupportedOperationException if it does not support
setting the id.
setId in interface TopicMapSourceIFpublic String getTitle()
TopicMapSourceIF
getTitle in interface TopicMapSourceIFpublic void setTitle(String title)
TopicMapSourceIF
setTitle in interface TopicMapSourceIFpublic String getPath()
public void setPath(String path)
public String getSuffix()
public void setSuffix(String suffix)
public LocatorIF getBase()
public void setBase(LocatorIF base_address)
public String getBaseAddress()
public void setBaseAddress(String base_address)
public boolean getDuplicateSuppression()
public void setDuplicateSuppression(boolean duplicate_suppression)
public Collection<TopicMapReferenceIF> getReferences()
TopicMapSourceIFTopicMapReferenceIFs found by the topic map source.
getReferences in interface TopicMapSourceIFpublic boolean supportsCreate()
TopicMapSourceIF
supportsCreate in interface TopicMapSourceIFpublic boolean supportsDelete()
TopicMapSourceIF
supportsDelete in interface TopicMapSourceIF
public TopicMapReferenceIF createTopicMap(String name,
String baseAddress)
TopicMapSourceIF
createTopicMap in interface TopicMapSourceIFpublic void refresh()
TopicMapSourceIF
refresh in interface TopicMapSourceIFprotected Map<String,TopicMapReferenceIF> refreshFromFilesystem()
protected Map refreshFromClasspath()
protected TopicMapReferenceIF createReference(URL url,
String id,
String title)
protected abstract TopicMapReferenceIF createReference(URL url,
String id,
String title,
LocatorIF base_address)
public FileFilter getFileFilter()
public void setFileFilter(FileFilter filter)
filter - a java.io.FileFilter object for filtering the filespublic boolean accept(File file)
accept in interface FileFilterpublic boolean getHidden()
public void setHidden(boolean hidden)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||