Package org.openprovenance.prov.model
Interface HadMember
-
- All Superinterfaces:
Relation,Statement,StatementOrBundle,UnqualifiedRelation
- All Known Subinterfaces:
QualifiedHadMember
- All Known Implementing Classes:
HadMember,QualifiedHadMember
public interface HadMember extends Relation, UnqualifiedRelation
Interface for PROV Collection Membership
PROV-DM Definition for Collection Membership: Membership is the belonging of an entity to a collection.
Relevant Factory Methods:
-
ProvFactory.newHadMember(QualifiedName, java.util.Collection) -
ProvFactory.newHadMember(QualifiedName, QualifiedName...) -
ObjectFactory.createHadMember()
Schema Definition:
The following schema fragment specifies the expected content contained within this class.
<complexType name="Membership"> <complexContent> <extension base="{http://www.w3.org/ns/prov#}AStatement"> <sequence> <element name="collection" type="{http://www.w3.org/ns/prov#}IDRef"/> <element name="entity" type="{http://www.w3.org/ns/prov#}IDRef" maxOccurs="unbounded"/> </sequence> </extension> </complexContent> </complexType>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.openprovenance.prov.model.StatementOrBundle
StatementOrBundle.Kind
-
-
Method Summary
Modifier and Type Method Description QualifiedNamegetCollection()Get an identifier for the collection whose member is assertedList<QualifiedName>getEntity()Get the list of identifiers of entities that are member of the collection.voidsetCollection(QualifiedName collection)Set an identifier for the collection whose member is asserted-
Methods inherited from interface org.openprovenance.prov.model.StatementOrBundle
getKind
-
-
-
-
Method Detail
-
getCollection
QualifiedName getCollection()
Get an identifier for the collection whose member is asserted- Returns:
- QualifiedName for the collection
- See Also:
- membership collection
-
getEntity
List<QualifiedName> getEntity()
Get the list of identifiers of entities that are member of the collection.- Returns:
- a list of
QualifiedNameThis accessor method returns a reference to the live list, not a snapshot. Therefore any modification you make to the returned list will be present inside the JAXB object. This is why there is not a
setmethod for the entity property.For example, to add a new item, do as follows:
getEntity().add(newItem);Objects of the following type(s) are allowed in the list
QualifiedName - See Also:
- membership entity
-
setCollection
void setCollection(QualifiedName collection)
Set an identifier for the collection whose member is asserted- Parameters:
collection- QualifiedName for the collection- See Also:
- membership collection
-
-