com.tle.core.taxonomy
Interface TermSoapService
Declaration: public interface TermSoapService

 

A SOAP interface for editing locally stored taxonomy terms.

 

 

Methods Summary
abstract void deleteTerm(java.lang.String taxonomyUuid, java.lang.String termFullPath)
    
Delete a term from the taxonomy.
abstract java.lang.String getData(java.lang.String taxonomyUuid, java.lang.String termFullPath, java.lang.String dataKey)
    
Retrieve an stored data value for a key against a term.
abstract void insertTerm(java.lang.String taxonomyUuid, java.lang.String parentFullPath, java.lang.String term, int index)
    
Insert a new term into the taxonomy.
abstract java.lang.String[] listTerms(java.lang.String taxonomyUuid, java.lang.String parentFullPath)
    
List the child terms for a parent term.
abstract void lockTaxonomyForEditing(java.lang.String taxonomyUuid)
    
Before terms can be edited, this method must be invoked to aquire an editing lock on the taxonomy.
abstract void move(java.lang.String taxonomyUuid, java.lang.String termToMove, java.lang.String newParent, int index)
    
Moves a term to a (possibly) new parent term and child index.
abstract void renameTermValue(java.lang.String taxonomyUuid, java.lang.String termToRename, java.lang.String newValue)
    
Renames a term.
abstract void setData(java.lang.String taxonomyUuid, java.lang.String termFullPath, java.lang.String dataKey, java.lang.String dataValue)
    
Set an arbitrary data value for a key against a term.
abstract void unlockTaxonomy(java.lang.String taxonomyUuid, boolean force)
    
Unlock a taxonomy that you previously acquired a lock on.

 

 

 

 

lockTaxonomyForEditing

 

public abstract void lockTaxonomyForEditing( java.lang.String taxonomyUuid)

 

Before terms can be edited, this method must be invoked to aquire an editing lock on the taxonomy. An error will be raised if the lock cannot be acquired, most likely because it has already been locked by a different user.

 

Parameters:
taxonomyUuid-
The UUID of the taxonomy to you want to edit.

 

 

 

unlockTaxonomy

 

public abstract void unlockTaxonomy( java.lang.String taxonomyUuid,
boolean force)

 

Unlock a taxonomy that you previously acquired a lock on. You can also choose to forcefully unlock the taxonomy, which will remove any existing lock, even if it has been made by another user. It is recommended that the force option is used with care.

 

Parameters:
taxonomyUuid-
The UUID of the taxonomy that you have finished editing.
force-
true if the taxonomy should be unlocked, even if your session is not the lock owner. It is recommended that you should you used false in nearly all case.

 

 

 

listTerms

 

public abstract java.lang.String[] listTerms( java.lang.String taxonomyUuid,
java.lang.String parentFullPath)

 

List the child terms for a parent term. This will only list the immediate children of the parent, ie, not grand-children, great grand-children, etc...

 

Parameters:
taxonomyUuid-
The UUID of the taxonomy.
parentFullPath-
The full path of the parent term the new term will be added to, eg, Mammalia\Felidae\Panthera. Passing in an empty string will list the root terms.
Returns:
An array of immediate child terms, eg, [Tiger, Lion, Jaguar, Leopard]

 

 

 

insertTerm

 

public abstract void insertTerm( java.lang.String taxonomyUuid,
java.lang.String parentFullPath,
java.lang.String term,
int index)

 

Insert a new term into the taxonomy.

This method requires an editing lock to have been acquired for the taxonomy.

 

Parameters:
taxonomyUuid-
The UUID of the taxonomy.
parentFullPath-
The full path of the parent term the new term will be added to, eg, Mammalia\Felidae\Panthera.
index-
The index the term should be inserted into in relation to its siblings. Zero inserts it as the first sibling, one as the second sibling, and so on. If the index is less than zero or greater than the number of siblings minus one, then the term will be added as the last sibling.
termValue-
The term to be added, eg, Tiger.

 

 

 

move

 

public abstract void move( java.lang.String taxonomyUuid,
java.lang.String termToMove,
java.lang.String newParent,
int index)

 

Moves a term to a (possibly) new parent term and child index. Children of the term are also moved. The user should always remember that changing the lineage of a term will also change the lineage of child terms, and depending on the number of terms that require modification, could be an expensive operation. Leaving the term under the same parent term, but changing the index, does not change the lineage of the term or its children.

This method requires an editing lock to have been acquired for the taxonomy.

 

Parameters:
taxonomyUuid-
The UUID of the taxonomy.
termToMove-
The full path of the term to move, eg, Aves\Falconiformes\Accipitridae\Flying Fish
index-
The index the term should be placed in relation to its siblings. Zero inserts it as the first sibling, one as the second sibling, and so on. If the index is less than zero or greater than the number of siblings minus one, then the term will be added as the last sibling.
moveToParent-
The full path of the parent term it should be moved to, eg, Actinopterygii\Exocoetidae. Null or an empty string will move the term to the root of the taxonomy.

 

 

 

renameTermValue

 

public abstract void renameTermValue( java.lang.String taxonomyUuid,
java.lang.String termToRename,
java.lang.String newValue)

 

Renames a term. The user should always remember that renaming a term will change the lineage of child terms, and depending on the number of terms that require modification, could be an expensive operation.

This method requires an editing lock to have been acquired for the taxonomy.

 

Parameters:
taxonomyUuid-
The UUID of the taxonomy.
termToRename-
the full path of the term to rename, eg, Aves\Falconiformes\Accipitridae\Tigger
newValue-
the new value that the term should become, eg, Tiger

 

 

 

deleteTerm

 

public abstract void deleteTerm( java.lang.String taxonomyUuid,
java.lang.String termFullPath)

 

Delete a term from the taxonomy. Child terms will also be deleted.

This method requires an editing lock to have been acquired for the taxonomy.

 

Parameters:
taxonomyUuid-
The UUID of the taxonomy.
termFullPath-
The full path of the term to delete, eg, Mammalia\Felidae\Panthera\Tiger.

 

 

 

getData

 

public abstract java.lang.String getData( java.lang.String taxonomyUuid,
java.lang.String termFullPath,
java.lang.String dataKey)

 

Retrieve an stored data value for a key against a term.

 

Parameters:
taxonomyUuid-
The UUID of the taxonomy.
termFullPath-
The full path of the term to retrieve the data for, eg, Mammalia\Felidae\Panthera\Tiger.
dataKey-
The key for the data to be retrieved.
Returns:
The data stored for that key and term.

 

 

 

setData

 

public abstract void setData( java.lang.String taxonomyUuid,
java.lang.String termFullPath,
java.lang.String dataKey,
java.lang.String dataValue)

 

Set an arbitrary data value for a key against a term.

This method requires an editing lock to have been acquired for the taxonomy.

 

Parameters:
taxonomyUuid-
The UUID of the taxonomy.
termFullPath-
The full path of the term to store the data for, eg, Mammalia\Felidae\Panthera\Tiger
dataKey-
The key that the data should be stored for.
dataValue-
The arbitrary data to store.