public class VocabularyResource extends Resource
Modifier and Type | Field and Description |
---|---|
protected boolean |
forceMmap
Force mmap ? (if true mem will be shared but perfs will be impacted)
|
protected boolean |
mlock
Is the resource in RAM ?
|
Constructor and Description |
---|
VocabularyResource(java.lang.String name,
java.lang.String path,
int lang)
Loads a VocabularyResource.
|
VocabularyResource(java.lang.String name,
java.lang.String path,
int lang,
boolean forceMmap) |
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
_getParametersDigest() |
protected void |
alloc(java.lang.String name,
java.lang.String path,
int lang,
boolean mlock,
boolean forceMmap)
Allocate resource.
|
protected void |
allocate()
Function you should override to perform allocation of the underlying
data.
|
void |
dumpVocabulary()
Debug: print the vocabulary to std::out
|
VocabularyIterator |
enumerate()
Allows to iterate on the resource's contents.
|
protected void |
free()
Function you should override to perform deallocation of the underlying
data.
|
equals, finalize, getExpandedPath, getExpandedPath, getExpandedPath, getExpandedPathIfExists, getExpandedPathIfExists, getIdentifier, getLang, getLangName, getName, hashCode, hasPath, register, register, release, release
protected final boolean mlock
protected boolean forceMmap
public VocabularyResource(java.lang.String name, java.lang.String path, int lang)
name
- the resource's name.path
- URI of the resource.lang
- the resource's language.public VocabularyResource(java.lang.String name, java.lang.String path, int lang, boolean forceMmap)
protected java.lang.String _getParametersDigest()
_getParametersDigest
in class Resource
public VocabularyIterator enumerate()
public void dumpVocabulary()
protected void allocate() throws ResourceNotFoundException
allocate
in class Resource
ResourceNotFoundException
protected void alloc(java.lang.String name, java.lang.String path, int lang, boolean mlock, boolean forceMmap)
Copyright © 2013 Dassault Systèmes, All Rights Reserved.