|
GATE Version 3.1-2270 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectgate.util.AbstractFeatureBearer
gate.creole.AbstractResource
gate.creole.AbstractLanguageResource
gate.creole.gazetteer.GazetteerList
public class GazetteerList
Gazetteer List provides the means for uploading, managing and storing the data in the gazetteer list files.
| Field Summary | |
|---|---|
static int |
LIST_MODE
indicates list representation of the gazetteer list |
static int |
STRING_MODE
indicates representation of the gaz list as a single string |
| Fields inherited from class gate.creole.AbstractLanguageResource |
|---|
dataStore, lrPersistentId |
| Fields inherited from class gate.creole.AbstractResource |
|---|
name |
| Fields inherited from class gate.util.AbstractFeatureBearer |
|---|
features |
| Constructor Summary | |
|---|---|
GazetteerList()
create a new gazetteer list |
|
| Method Summary | |
|---|---|
void |
add(int index,
Object element)
|
boolean |
add(Object o)
|
boolean |
addAll(Collection c)
Adds entire collection |
boolean |
addAll(int index,
Collection c)
|
void |
clear()
|
boolean |
contains(Object o)
|
boolean |
containsAll(Collection c)
|
boolean |
equals(Object o)
|
Object |
get(int index)
|
String |
getEncoding()
Gets the encoding of the list |
int |
getMode()
Retrieves the current mode of the gaz list |
URL |
getURL()
Gets the URL of the list |
int |
indexOf(Object o)
|
boolean |
isEmpty()
|
boolean |
isModified()
Returns true of an LR has been modified since the last sync. |
Iterator |
iterator()
Gets an iterator over the list. |
int |
lastIndexOf(Object o)
|
ListIterator |
listIterator()
|
ListIterator |
listIterator(int index)
|
void |
load()
Loads a gazetteer list |
Object |
remove(int index)
|
boolean |
remove(Object o)
|
boolean |
removeAll(Collection c)
|
boolean |
retainAll(Collection c)
|
Object |
set(int index,
Object element)
|
void |
setEncoding(String encod)
Sets the encoding of the list |
void |
setMode(int m)
Sets mode of the gazetteer list |
void |
setModified(boolean modified)
Sets the modified status of the current list |
void |
setURL(URL theUrl)
Sets the URL of the list |
int |
size()
|
void |
store()
Stores the list to the specified url |
List |
subList(int fromIndex,
int toIndex)
|
Object[] |
toArray()
|
Object[] |
toArray(Object[] a)
|
String |
toString()
Retrieves the string representation of the gaz list according to its mode. |
void |
updateContent(String newContent)
Updates the content of the gaz list with the given parameter. |
| Methods inherited from class gate.creole.AbstractLanguageResource |
|---|
cleanup, getDataStore, getLRPersistenceId, getParent, setDataStore, setLRPersistenceId, setParent, sync |
| Methods inherited from class gate.creole.AbstractResource |
|---|
checkParameterValues, getBeanInfo, getName, getParameterValue, getParameterValue, init, removeResourceListeners, setName, setParameterValue, setParameterValue, setParameterValues, setParameterValues, setResourceListeners |
| Methods inherited from class gate.util.AbstractFeatureBearer |
|---|
getFeatures, setFeatures |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface java.util.List |
|---|
hashCode |
| Methods inherited from interface gate.Resource |
|---|
getParameterValue, init, setParameterValue, setParameterValues |
| Methods inherited from interface gate.util.FeatureBearer |
|---|
getFeatures, setFeatures |
| Methods inherited from interface gate.util.NameBearer |
|---|
getName, setName |
| Field Detail |
|---|
public static final int LIST_MODE
public static final int STRING_MODE
| Constructor Detail |
|---|
public GazetteerList()
| Method Detail |
|---|
public boolean isModified()
AbstractLanguageResource
isModified in interface LanguageResourceisModified in class AbstractLanguageResourcepublic void setModified(boolean modified)
modified - is modified flagpublic int getMode()
public void setMode(int m)
m - the mode to be setpublic void setEncoding(String encod)
encod - the encoding to be setpublic String getEncoding()
public void load()
throws ResourceInstantiationException
ResourceInstantiationException
public void store()
throws ResourceInstantiationException
ResourceInstantiationExceptionpublic void setURL(URL theUrl)
theUrl - the URL of the Listpublic URL getURL()
public int size()
size in interface Collectionsize in interface Listpublic boolean isEmpty()
isEmpty in interface CollectionisEmpty in interface Listpublic boolean contains(Object o)
contains in interface Collectioncontains in interface Listpublic Iterator iterator()
iterator in interface Iterableiterator in interface Collectioniterator in interface Listpublic Object[] toArray()
toArray in interface CollectiontoArray in interface Listpublic Object[] toArray(Object[] a)
toArray in interface CollectiontoArray in interface Listpublic boolean add(Object o)
add in interface Collectionadd in interface Listpublic boolean remove(Object o)
remove in interface Collectionremove in interface Listpublic boolean containsAll(Collection c)
containsAll in interface CollectioncontainsAll in interface Listpublic boolean addAll(Collection c)
addAll in interface CollectionaddAll in interface Listc - a collection to be addded
public boolean addAll(int index,
Collection c)
addAll in interface Listpublic boolean removeAll(Collection c)
removeAll in interface CollectionremoveAll in interface Listpublic boolean retainAll(Collection c)
retainAll in interface CollectionretainAll in interface Listpublic void clear()
clear in interface Collectionclear in interface Listpublic boolean equals(Object o)
equals in interface Collectionequals in interface Listequals in class Objectpublic Object get(int index)
get in interface List
public Object set(int index,
Object element)
set in interface List
public void add(int index,
Object element)
add in interface Listpublic Object remove(int index)
remove in interface Listpublic int indexOf(Object o)
indexOf in interface Listpublic int lastIndexOf(Object o)
lastIndexOf in interface Listpublic ListIterator listIterator()
listIterator in interface Listpublic ListIterator listIterator(int index)
listIterator in interface List
public List subList(int fromIndex,
int toIndex)
subList in interface Listpublic String toString()
LIST_MODE then all
the entries are dumped sequentially to a string. If
STRING_MODE then
the content (a string) of the gaz list is retrieved.
toString in class Objectpublic void updateContent(String newContent)
LIST_MODE
the new content is parsed and loaded as single nodes through the
List interface. In the case of
STRING_MODE the new content
is stored as a String and is not parsed.
newContent - the new content of the gazetteer list
|
GATE Version 3.1-2270 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||