public class SampleServiceImpl extends Object implements SampleService
SampleServiceImpl class.
NAME
Constructor and Description |
---|
SampleServiceImpl()
Constructor for SampleServiceImpl.
|
Modifier and Type | Method and Description |
---|---|
void |
delete(Sample sample,
boolean deleteRealFiles)
delete.
|
List<Sample> |
findByCriteria(String criteria,
boolean isCaseSens)
findByCriteria.
|
Sample |
findByID(Integer sampleId)
findByID.
|
Sample |
findByName(String name)
findByName.
|
List<Sample> |
findByOwnerID(Integer registrationId)
findByOwnerID.
|
Sample |
findBySWAccession(Integer swAccession)
findBySWAccession.
|
Sample |
findByTitle(String title)
findByTitle.
|
List<File> |
getFiles(Integer sampleId)
getFiles.
|
List<File> |
getFiles(Integer studyId,
String metaType)
getFiles.
|
Sample |
getRootSample(Sample childSample)
getRootSample.
|
List<Sample> |
getRootSamples(Study study)
getRootSamples.
|
boolean |
hasNameBeenUsed(String oldName,
String newName)
hasNameBeenUsed.
|
Integer |
insert(Registration registration,
Sample sample)
insert.
|
Integer |
insert(Sample sample)
insert.
|
boolean |
isHasFile(Integer sampleId)
isHasFile.
|
boolean |
isHasFile(Integer studyId,
String metaType)
isHasFile.
|
List<Sample> |
list()
list.
|
List<Sample> |
listComplete()
listComplete.
|
List<Sample> |
listIncomplete()
listIncomplete.
|
List<Sample> |
listSample(Registration registration)
listSample.
|
SortedSet<Sample> |
listWithHasFile(Integer expId,
SortedSet<Sample> list,
String metaType)
listWithHasFile.
|
List<Sample> |
matchName(String name) |
void |
setFileDAO(FileDAO fileDAO)
Sets a private member variable with an instance of an implementation of FileDAO.
|
void |
setSampleDAO(SampleDAO sampleDAO)
setSampleDAO.
|
SortedSet<Sample> |
setWithHasFile(Integer expId,
SortedSet<Sample> list)
setWithHasFile.
|
void |
update(Registration registration,
Sample sample)
update.
|
void |
update(Sample sample)
update.
|
Sample |
updateDetached(Registration registration,
Sample sample)
updateDetached.
|
Sample |
updateDetached(Sample sample)
updateDetached.
|
public void setSampleDAO(SampleDAO sampleDAO)
setSampleDAO.
Sets a private member variable with an instance of an implementation of SampleDAO. This method is called by the Spring framework at run time.setSampleDAO
in interface SampleService
sampleDAO
- a SampleDAO
object.SampleDAO
public void setFileDAO(FileDAO fileDAO)
fileDAO
- implementation of FileDAOFileDAO
public Integer insert(Sample sample)
insert.
Inserts an instance of Sample into the database.insert
in interface SampleService
sample
- a Sample
object.Integer
object.public void update(Sample sample)
update.
Updates an instance of Sample in the database.update
in interface SampleService
sample
- a Sample
object.public void delete(Sample sample, boolean deleteRealFiles)
delete.
Deletes an instance of Sample in the database.delete
in interface SampleService
sample
- deleteRealFiles
- public List<File> getFiles(Integer sampleId)
getFiles.
getFiles
in interface SampleService
sampleId
- a Integer
object.List
object.public boolean isHasFile(Integer sampleId)
isHasFile.
isHasFile
in interface SampleService
sampleId
- a Integer
object.public List<File> getFiles(Integer studyId, String metaType)
getFiles.
getFiles
in interface SampleService
studyId
- a Integer
object.metaType
- a String
object.List
object.public boolean isHasFile(Integer studyId, String metaType)
isHasFile.
isHasFile
in interface SampleService
studyId
- a Integer
object.metaType
- a String
object.public SortedSet<Sample> setWithHasFile(Integer expId, SortedSet<Sample> list)
setWithHasFile.
setWithHasFile
in interface SampleService
expId
- a Integer
object.list
- a SortedSet
object.SortedSet
object.public SortedSet<Sample> listWithHasFile(Integer expId, SortedSet<Sample> list, String metaType)
listWithHasFile.
listWithHasFile
in interface SampleService
expId
- a Integer
object.list
- a SortedSet
object.metaType
- a String
object.SortedSet
object.public Sample findByTitle(String title)
findByTitle.
findByTitle
in interface SampleService
title
- a String
object.Sample
object.public Sample findByName(String name)
findByName.
Finds an instance of Sample in the database by the Sample emailAddress, and copies the Sample properties to an instance of Sample.findByName
in interface SampleService
name
- a String
object.Sample
object.public List<Sample> matchName(String name)
matchName
in interface SampleService
public Sample findByID(Integer sampleId)
findByID.
findByID
in interface SampleService
sampleId
- Sample
object.public Sample findBySWAccession(Integer swAccession)
findBySWAccession.
findBySWAccession
in interface SampleService
swAccession
- a Integer
object.Sample
object.public List<Sample> findByOwnerID(Integer registrationId)
findByOwnerID.
findByOwnerID
in interface SampleService
registrationId
- a Integer
object.List
object.public List<Sample> findByCriteria(String criteria, boolean isCaseSens)
findByCriteria.
findByCriteria
in interface SampleService
criteria
- a String
object.isCaseSens
- a boolean.List
object.public boolean hasNameBeenUsed(String oldName, String newName)
hasNameBeenUsed.
Determines if an email address has already been used.hasNameBeenUsed
in interface SampleService
oldName
- a String
object.newName
- a String
object.public List<Sample> listComplete()
listComplete.
listComplete
in interface SampleService
List
object.public List<Sample> listIncomplete()
listIncomplete.
listIncomplete
in interface SampleService
List
object.public List<Sample> listSample(Registration registration)
listSample.
listSample
in interface SampleService
registration
- a Registration
object.List
object.public Sample updateDetached(Sample sample)
updateDetached.
updateDetached
in interface SampleService
sample
- a Sample
object.Sample
object.public List<Sample> getRootSamples(Study study)
getRootSamples.
getRootSamples
in interface SampleService
study
- a Study
object.List
object.public Sample getRootSample(Sample childSample)
getRootSample.
getRootSample
in interface SampleService
childSample
- a Sample
object.Sample
object.public List<Sample> list()
list.
list
in interface SampleService
List
object.public void update(Registration registration, Sample sample)
update.
update
in interface SampleService
registration
- a Registration
object.sample
- a Sample
object.public Integer insert(Registration registration, Sample sample)
insert.
insert
in interface SampleService
registration
- a Registration
object.sample
- a Sample
object.Integer
object.public Sample updateDetached(Registration registration, Sample sample)
updateDetached.
updateDetached
in interface SampleService
registration
- a Registration
object.sample
- a Sample
object.Sample
object.Copyright © 2015 SeqWare. All rights reserved.