public class SlimModCollection extends Object implements List<SlimModification>
Constructor and Description |
---|
SlimModCollection()
Constructor that create a new List of Slim modifications
|
SlimModCollection(List<SlimModification> modCollection)
Constructor that create an instance of the SlimModCollection class
and initializes the collection of slim modification with the parameter.
|
Modifier and Type | Method and Description |
---|---|
void |
add(int index,
SlimModification element)
Add an Slim Modification in the list in an specific position (index)
|
boolean |
add(SlimModification mod)
Add an slim modification to the list of modifications
|
boolean |
addAll(Collection<? extends SlimModification> c)
Add a collection of slim modifications to the current list of slim modifications.
|
boolean |
addAll(int index,
Collection<? extends SlimModification> c)
Add a collection of slim modifications from the index integer
|
void |
clear()
Clear the List of modifications
|
boolean |
contains(Object o)
Verified if a Modification exist in the List of the current modifications.
|
boolean |
containsAll(Collection<?> c)
Compare if a list of slim modifications are included in the List of
modifications
|
SlimModification |
get(int index)
Get a modification in the list.
|
SlimModCollection |
getbyDelta(double deltaMass,
double difference)
This method return an object of SlimCollection with a list of the slim modifications
by a given mass and small windows or error between the delta mass of the modifications
and the parameter deltaMass.
|
SlimModification |
getbyName(String name)
Get the list of slim modifications compare only with the default specificity of
each modification.
|
SlimModCollection |
getbySpecificity(Specificity.AminoAcid specificity)
This method return an SlimModCollection object, a list of the slim modifications that
contain an specific specificity in the list of possible specificities.
|
SlimModCollection |
getbySpecificity(Specificity.AminoAcid specificity,
double mass,
double difference)
This method allow users to obtain the slim modification filtering with a delta mass
a possible error (difference) and one specificity in the list of the possible
specificities for each modification.
|
SlimModCollection |
getbySpecificity(String nameSpecificity)
This method return an SlimModCollection object, a list of the slim modifications that
contain an specific specificity in the list of possible specificities.
|
SlimModCollection |
getbySpecificity(String nameSpecificity,
double mass,
double difference)
This method allow users to obtain the slim modification filtering with a delta mass
a possible error (difference) and one specificity in the list of the possible
specificities for each modification.
|
int |
indexOf(Object o)
Index of the Object slim modification in the List of modifications
|
boolean |
isEmpty()
Get if the modification list is Empty.
|
Iterator<SlimModification> |
iterator()
An iterator through the modification List
|
int |
lastIndexOf(Object o)
Index after the element passed by parameters in the list
|
ListIterator<SlimModification> |
listIterator()
Get List of Iterator of the List of modifications
|
ListIterator<SlimModification> |
listIterator(int index)
Get List of Iterator of the List of modifications from specific position
|
SlimModification |
remove(int index)
Remove an slim object from the list of slim modification by index.
|
boolean |
remove(Object o)
Remove an modification passed by parameters from the List of modifications
|
boolean |
removeAll(Collection<?> c)
Remove a collection of slim modifications from the current List of slim modifications
|
boolean |
retainAll(Collection<?> c) |
SlimModification |
set(int index,
SlimModification element)
Set slim modification with the value passed by parameter element in the position
index of the list.
|
int |
size()
Get the size of the modification List.
|
List<SlimModification> |
subList(int fromIndex,
int toIndex)
Get a collection of modification between to indexes.
|
Object[] |
toArray()
Convert the current List to an Array of Objects
|
<T> T[] |
toArray(T[] a) |
public SlimModCollection()
public SlimModCollection(List<SlimModification> modCollection)
modCollection
- public SlimModCollection getbyDelta(double deltaMass, double difference)
deltaMass
- the value of the delta mass to filter modifications.difference
- an small error allowed between the mass and the param deltaMass.public SlimModCollection getbySpecificity(Specificity.AminoAcid specificity)
specificity
- the specificity to looking in the List of specificities in each modificationpublic SlimModCollection getbySpecificity(String nameSpecificity)
nameSpecificity
- String one character representation of Amino Acids.public SlimModCollection getbySpecificity(Specificity.AminoAcid specificity, double mass, double difference)
specificity
- an specificity in the form of class Specificitymass
- the delta massdifference
- the difference or error between the parameter mass and the delta mas
of each modification.public SlimModCollection getbySpecificity(String nameSpecificity, double mass, double difference)
nameSpecificity
- an specificity in the form of String.mass
- the delta massdifference
- the difference or error between the parameter mass and the delta mas
of each modification.public SlimModification getbyName(String name)
name
- the name of the modification.public boolean add(SlimModification mod)
add
in interface Collection<SlimModification>
add
in interface List<SlimModification>
mod
- new modificationpublic int size()
size
in interface Collection<SlimModification>
size
in interface List<SlimModification>
public boolean isEmpty()
isEmpty
in interface Collection<SlimModification>
isEmpty
in interface List<SlimModification>
public boolean contains(Object o)
contains
in interface Collection<SlimModification>
contains
in interface List<SlimModification>
o
- generic slim modification objectpublic Iterator<SlimModification> iterator()
iterator
in interface Iterable<SlimModification>
iterator
in interface Collection<SlimModification>
iterator
in interface List<SlimModification>
public Object[] toArray()
toArray
in interface Collection<SlimModification>
toArray
in interface List<SlimModification>
public <T> T[] toArray(T[] a)
toArray
in interface Collection<SlimModification>
toArray
in interface List<SlimModification>
T
- a
- public boolean remove(Object o)
remove
in interface Collection<SlimModification>
remove
in interface List<SlimModification>
o
- modificationpublic boolean containsAll(Collection<?> c)
containsAll
in interface Collection<SlimModification>
containsAll
in interface List<SlimModification>
c
- a collection of objectspublic boolean addAll(Collection<? extends SlimModification> c)
addAll
in interface Collection<SlimModification>
addAll
in interface List<SlimModification>
c
- collection of slim modificationspublic boolean removeAll(Collection<?> c)
removeAll
in interface Collection<SlimModification>
removeAll
in interface List<SlimModification>
c
- collection of slim modificationspublic boolean retainAll(Collection<?> c)
retainAll
in interface Collection<SlimModification>
retainAll
in interface List<SlimModification>
c
- public void clear()
clear
in interface Collection<SlimModification>
clear
in interface List<SlimModification>
public boolean addAll(int index, Collection<? extends SlimModification> c)
addAll
in interface List<SlimModification>
index
- an index of the first position to add slim modifications.c
- a collection of the slim modifications to add to the list.public SlimModification get(int index)
get
in interface List<SlimModification>
index
- the position of the slim modification to returnpublic SlimModification set(int index, SlimModification element)
set
in interface List<SlimModification>
index
- element
- public void add(int index, SlimModification element)
add
in interface List<SlimModification>
index
- position to add the slim modification in the list.element
- an slim modificationpublic SlimModification remove(int index)
remove
in interface List<SlimModification>
index
- public int indexOf(Object o)
indexOf
in interface List<SlimModification>
o
- public int lastIndexOf(Object o)
lastIndexOf
in interface List<SlimModification>
o
- public ListIterator<SlimModification> listIterator()
listIterator
in interface List<SlimModification>
public ListIterator<SlimModification> listIterator(int index)
listIterator
in interface List<SlimModification>
index
- public List<SlimModification> subList(int fromIndex, int toIndex)
subList
in interface List<SlimModification>
fromIndex
- toIndex
- Copyright © 2015. All Rights Reserved.