org.kuali.rice.krms.impl.repository.mock
Class TermRepositoryServiceMockImpl
java.lang.Object
org.kuali.rice.krms.impl.repository.mock.TermRepositoryServiceMockImpl
- All Implemented Interfaces:
- TermRepositoryService
public class TermRepositoryServiceMockImpl
- extends Object
- implements TermRepositoryService
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TermRepositoryServiceMockImpl
public TermRepositoryServiceMockImpl()
clear
public void clear()
findTermResolversByNamespace
public List<TermResolverDefinition> findTermResolversByNamespace(String namespace)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Retrieves all
TermResolverDefinitions for the given namespace.
- Specified by:
findTermResolversByNamespace in interface TermRepositoryService
- Parameters:
namespace - the namespace for which to get all term resolvers.
- Returns:
- the List of
TermResolverDefinitions for the given namespace. May be empty, but never null.
- Throws:
RiceIllegalArgumentException - if the namespace is null or blank.
getTerm
public TermDefinition getTerm(String termId)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Retrieves the
TermDefinition with the given termId.
- Specified by:
getTerm in interface TermRepositoryService
- Parameters:
termId - the identifier of the term to retrieve.
- Returns:
- the
TermDefinition with the given termId. May be null if there is no term with the given termId
in the repository.
- Throws:
RiceIllegalArgumentException - if the termId is null or blank.
getTermSpecificationById
public TermSpecificationDefinition getTermSpecificationById(String id)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Retrieves the
TermSpecificationDefinition with the given TermSpecificationId.
- Specified by:
getTermSpecificationById in interface TermRepositoryService
- Parameters:
id - the identifier of the term specification to retrieve.
- Returns:
- the
TermSpecificationDefinition with the given id. May be null if there is no term specification
with the given id in the repository.
- Throws:
RiceIllegalArgumentException - if the id is null or blank.
createTermSpecification
public TermSpecificationDefinition createTermSpecification(TermSpecificationDefinition termSpec)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Creates a
TermSpecificationDefinition
- Specified by:
createTermSpecification in interface TermRepositoryService
- Parameters:
termSpec - the term specification to be created
- Returns:
- the
TermSpecificationDefinition after it has been created
in the repository.
- Throws:
RiceIllegalArgumentException - termSpec is null or invalid
createTerm
public TermDefinition createTerm(TermDefinition termDef)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Create a
TermDefinition
- Specified by:
createTerm in interface TermRepositoryService
- Parameters:
termDef - to be created
- Returns:
- the
TermDefinition term definition after it has been
created in the repository.
- Throws:
RiceIllegalArgumentException - if
the termDef is null or blank.
getTermResolverById
public TermResolverDefinition getTermResolverById(String id)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Retrieves the
TermResolverDefinition with the given id.
- Specified by:
getTermResolverById in interface TermRepositoryService
- Parameters:
id - the identifier of the term to retrieve.
- Returns:
- the
TermResolverDefinition with the given id. May be null
if there is no term with the given id in the repository.
- Throws:
RiceIllegalArgumentException - if
the id is null or blank.
findTermResolversByOutputId
public List<TermResolverDefinition> findTermResolversByOutputId(String id,
String namespace)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Get the
TermResolverDefinitions for any term resolvers in the
specified namespace that have the given term specification as their
output.
- Specified by:
findTermResolversByOutputId in interface TermRepositoryService
- Parameters:
id - the id for the term specificationnamespace - the namespace to search
- Returns:
- the List of term resolvers found. If none are found, an empty
list will be returned.
- Throws:
RiceIllegalArgumentException
createTermResolver
public TermResolverDefinition createTermResolver(TermResolverDefinition termResolver)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Creates the
TermResolverDefinition.
- Specified by:
createTermResolver in interface TermRepositoryService
- Parameters:
termResolver - to be created
- Returns:
- the
TermResolver after it has been created in the
repository.
- Throws:
RiceIllegalArgumentException - if
the termResolver is null or blank.
updateTermSpecification
public void updateTermSpecification(TermSpecificationDefinition termSpec)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Updates a
TermSpecificationDefinition
- Specified by:
updateTermSpecification in interface TermRepositoryService
- Parameters:
termSpec - the term specification to be updated
- Throws:
RiceIllegalArgumentException - termSpec is null or invalid
deleteTermSpecification
public void deleteTermSpecification(String id)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Deletes a
TermSpecificationDefinition
- Specified by:
deleteTermSpecification in interface TermRepositoryService
- Parameters:
id - the id of the term specification to be deleted
- Throws:
RiceIllegalArgumentException - id is null or invalid
updateTerm
public void updateTerm(TermDefinition termDef)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Update a
TermDefinition
- Specified by:
updateTerm in interface TermRepositoryService
- Parameters:
termDef - to be updated
- Throws:
RiceIllegalArgumentException - if
the termDef is null or blank.
deleteTerm
public void deleteTerm(String id)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Delete a
TermDefinition
- Specified by:
deleteTerm in interface TermRepositoryService
- Parameters:
id - of the termDefinition to be deleted
- Throws:
RiceIllegalArgumentException - if
the id is null or blank.
updateTermResolver
public void updateTermResolver(TermResolverDefinition termResolver)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Updates the
TermResolverDefinition.
- Specified by:
updateTermResolver in interface TermRepositoryService
- Parameters:
termResolver - to be created
- Throws:
RiceIllegalArgumentException - if
the termResolver is null or blank.
deleteTermResolver
public void deleteTermResolver(String id)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- deletes the
TermResolverDefinition with the given id
- Specified by:
deleteTermResolver in interface TermRepositoryService
- Parameters:
id - of the term resolver to be deleted
- Throws:
RiceIllegalArgumentException - if
the termResolver is null or blank.
getTermResolverByNameAndNamespace
public TermResolverDefinition getTermResolverByNameAndNamespace(String name,
String namespace)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Retrieves the
TermResolverDefinition for the given name and namespace
- Specified by:
getTermResolverByNameAndNamespace in interface TermRepositoryService
- Parameters:
name - the name for which to get term resolvernamespace - the namespace for which to get term resolver
- Returns:
- the
TermResolverDefinition for the given name and namespace, null if none exist.
- Throws:
RiceIllegalArgumentException - if the name or namespace is null or blank.
getTermSpecificationByNameAndNamespace
public TermSpecificationDefinition getTermSpecificationByNameAndNamespace(String name,
String namespace)
throws RiceIllegalArgumentException
- Description copied from interface:
TermRepositoryService
- Retrieves the
TermSpecificationDefinition for the given name and namespace
- Specified by:
getTermSpecificationByNameAndNamespace in interface TermRepositoryService
- Parameters:
name - the name for which to get term specificationnamespace - the namespace for which to get term resolver
- Returns:
- the
TermSpecificationDefinition for the given name and namespace, null if none exist.
- Throws:
RiceIllegalArgumentException - if the name or namespace is null or blank.
Copyright © 2004-2013 The Kuali Foundation. All Rights Reserved.