| Modifier and Type | Field and Description |
|---|---|
static String |
NO_KNOWN_ALLERGIES |
static String |
SEE_LIST |
static String |
UNKNOWN |
| Constructor and Description |
|---|
Allergies() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(Allergy allergy) |
void |
add(int index,
Allergy element) |
boolean |
addAll(Collection<? extends Allergy> c) |
boolean |
addAll(int index,
Collection<? extends Allergy> c) |
void |
clear() |
void |
confirmNoKnownAllergies() |
boolean |
contains(Object o) |
boolean |
containsAll(Collection<?> c) |
boolean |
containsAllergen(Allergy allergy)
Checks if we already have an allergen similar to that in the given allergy
|
boolean |
containsAllergen(Allergy allergy,
Collection<? extends Allergy> allergies)
Checks if a given allergy has the same allergen as any in the given allergies
|
Allergy |
get(int index) |
Allergy |
getAllergy(Integer allergyId)
Gets an allergy with a given id
|
String |
getAllergyStatus() |
int |
indexOf(Object o) |
boolean |
isEmpty() |
Iterator<Allergy> |
iterator() |
int |
lastIndexOf(Object o) |
ListIterator<Allergy> |
listIterator() |
ListIterator<Allergy> |
listIterator(int index) |
boolean |
remove(Allergy allergy) |
Allergy |
remove(int index) |
boolean |
remove(Object o) |
boolean |
removeAll(Collection<?> c) |
boolean |
retainAll(Collection<?> c) |
Allergy |
set(int index,
Allergy element) |
int |
size() |
List<Allergy> |
subList(int fromIndex,
int toIndex) |
Object[] |
toArray() |
<T> T[] |
toArray(T[] a) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitequals, hashCode, replaceAll, sort, spliteratorparallelStream, removeIf, streampublic static final String UNKNOWN
public static final String NO_KNOWN_ALLERGIES
public static final String SEE_LIST
public String getAllergyStatus()
public boolean add(Allergy allergy)
public boolean remove(Allergy allergy)
public void clear()
public void confirmNoKnownAllergies()
public Iterator<Allergy> iterator()
iterator in interface Iterable<Allergy>iterator in interface Collection<Allergy>iterator in interface List<Allergy>List.iterator()public void add(int index,
Allergy element)
add in interface List<Allergy>List.add(int, java.lang.Object)public boolean addAll(Collection<? extends Allergy> c)
addAll in interface Collection<Allergy>addAll in interface List<Allergy>List.addAll(java.util.Collection)public boolean addAll(int index,
Collection<? extends Allergy> c)
addAll in interface List<Allergy>List.addAll(int, java.util.Collection)public boolean contains(Object o)
contains in interface Collection<Allergy>contains in interface List<Allergy>List.contains(java.lang.Object)public boolean containsAll(Collection<?> c)
containsAll in interface Collection<Allergy>containsAll in interface List<Allergy>List.containsAll(java.util.Collection)public Allergy get(int index)
get in interface List<Allergy>List.get(int)public int indexOf(Object o)
indexOf in interface List<Allergy>List.indexOf(java.lang.Object)public boolean isEmpty()
isEmpty in interface Collection<Allergy>isEmpty in interface List<Allergy>List.isEmpty()public int lastIndexOf(Object o)
lastIndexOf in interface List<Allergy>List.lastIndexOf(java.lang.Object)public ListIterator<Allergy> listIterator()
listIterator in interface List<Allergy>List.listIterator()public ListIterator<Allergy> listIterator(int index)
listIterator in interface List<Allergy>List.listIterator(int)public Allergy remove(int index)
remove in interface List<Allergy>List.remove(int)public boolean remove(Object o)
remove in interface Collection<Allergy>remove in interface List<Allergy>List.remove(java.lang.Object)public boolean removeAll(Collection<?> c)
removeAll in interface Collection<Allergy>removeAll in interface List<Allergy>List.removeAll(java.util.Collection)public boolean retainAll(Collection<?> c)
retainAll in interface Collection<Allergy>retainAll in interface List<Allergy>List.retainAll(java.util.Collection)public Allergy set(int index, Allergy element)
set in interface List<Allergy>List.set(int, java.lang.Object)public int size()
size in interface Collection<Allergy>size in interface List<Allergy>List.size()public List<Allergy> subList(int fromIndex, int toIndex)
subList in interface List<Allergy>List.subList(int, int)public Object[] toArray()
toArray in interface Collection<Allergy>toArray in interface List<Allergy>List.toArray()public <T> T[] toArray(T[] a)
public Allergy getAllergy(Integer allergyId)
allergyId - the allergy idpublic boolean containsAllergen(Allergy allergy, Collection<? extends Allergy> allergies)
allergy - the allergy whose allergen to compare withallergies - the allergies whose allergens to compare withpublic boolean containsAllergen(Allergy allergy)
allergy - the allergy whose allergen to compare withCopyright © 2024 OpenMRS Inc.. All rights reserved.