Class QualifiedAlternateOf
- java.lang.Object
-
- org.openprovenance.prov.vanilla.QualifiedAlternateOf
-
- All Implemented Interfaces:
Equals,HashCode,ToString,AlternateOf,QualifiedAlternateOf,HasLabel,HasOther,HasType,Identifiable,QualifiedRelation,Relation,Statement,StatementOrBundle,UnqualifiedRelation,HasAttributes
public class QualifiedAlternateOf extends Object implements QualifiedAlternateOf, Equals, HashCode, ToString, HasAttributes
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.openprovenance.prov.model.StatementOrBundle
StatementOrBundle.Kind
-
-
Field Summary
Fields Modifier and Type Field Description protected QualifiedNamealternate1protected QualifiedNamealternate2
-
Constructor Summary
Constructors Constructor Description QualifiedAlternateOf(QualifiedName id, Collection<Attribute> attributes)QualifiedAlternateOf(QualifiedName id, QualifiedName alternate1, QualifiedName alternate2, Collection<Attribute> attributes)
-
Method Summary
Modifier and Type Method Description booleanequals(Object object)voidequals(Object object, EqualsBuilder equalsBuilder)voidequals2(Object object, EqualsBuilder equalsBuilder)QualifiedNamegetAlternate1()Returns the identifier for the first of the two entities.QualifiedNamegetAlternate2()Returns the identifier for the second of the two entities.Collection<Attribute>getAttributes()QualifiedNamegetId()Gets the value of the id property.Map<QualifiedName,Set<Attribute>>getIndexedAttributes()StatementOrBundle.KindgetKind()Gets the type of a provenance statementList<LangString>getLabel()Gets the value of the label property.List<Other>getOther()Gets the list of non-PROV attributes.List<Type>getType()Gets the value of theprov:typeproperty.inthashCode()voidhashCode(HashCodeBuilder hashCodeBuilder)booleanisUnqualified()voidsetAlternate1(QualifiedName informed)Sets the identifier for the first of the two entities.voidsetAlternate2(QualifiedName alternate2)Sets the identifier for the second of the two entities.voidsetId(QualifiedName value)Sets the value of the id property.voidsetIndexedAttributes(Object qn, Set<Attribute> attributes)StringtoString()voidtoString(ToStringBuilder toStringBuilder)
-
-
-
Field Detail
-
alternate1
protected QualifiedName alternate1
-
alternate2
protected QualifiedName alternate2
-
-
Constructor Detail
-
QualifiedAlternateOf
public QualifiedAlternateOf(QualifiedName id, Collection<Attribute> attributes)
-
QualifiedAlternateOf
public QualifiedAlternateOf(QualifiedName id, QualifiedName alternate1, QualifiedName alternate2, Collection<Attribute> attributes)
-
-
Method Detail
-
isUnqualified
public boolean isUnqualified()
- Specified by:
isUnqualifiedin interfaceQualifiedAlternateOf
-
setAlternate1
public void setAlternate1(QualifiedName informed)
Description copied from interface:AlternateOfSets the identifier for the first of the two entities.- Specified by:
setAlternate1in interfaceAlternateOf- Parameters:
informed- aQualifiedNamefor second entity
-
setAlternate2
public void setAlternate2(QualifiedName alternate2)
Description copied from interface:AlternateOfSets the identifier for the second of the two entities.- Specified by:
setAlternate2in interfaceAlternateOf- Parameters:
alternate2- aQualifiedNamefor second entity
-
getAlternate2
public QualifiedName getAlternate2()
Description copied from interface:AlternateOfReturns the identifier for the second of the two entities.- Specified by:
getAlternate2in interfaceAlternateOf- Returns:
- a
QualifiedName
-
getAlternate1
public QualifiedName getAlternate1()
Description copied from interface:AlternateOfReturns the identifier for the first of the two entities.- Specified by:
getAlternate1in interfaceAlternateOf- Returns:
- a
QualifiedName
-
getId
public QualifiedName getId()
Description copied from interface:IdentifiableGets the value of the id property. A null value means that the object has not been identified.Entity,Activity,Agenthave a non-null identifier.- Specified by:
getIdin interfaceIdentifiable- Returns:
- possible object is
QualifiedName
-
getKind
public StatementOrBundle.Kind getKind()
Description copied from interface:StatementOrBundleGets the type of a provenance statement- Specified by:
getKindin interfaceStatementOrBundle- Returns:
StatementOrBundle.Kind
-
setId
public void setId(QualifiedName value)
Description copied from interface:IdentifiableSets the value of the id property.- Specified by:
setIdin interfaceIdentifiable- Parameters:
value- allowed object isQualifiedName
-
getLabel
public List<LangString> getLabel()
Description copied from interface:HasLabelGets the value of the label property.This 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 object. This is why there is not a
setmethod for the label property.For example, to add a new item, do as follows:
getLabel().add(newItem);Objects of the following type(s) are allowed in the list
LangString
-
getType
public List<Type> getType()
Description copied from interface:HasTypeGets the value of theprov:typeproperty.This 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 type property.For example, to add a new item, do as follows:
getType().add(newItem);Objects of the following type(s) are allowed in the list
Type
-
getOther
public List<Other> getOther()
Description copied from interface:HasOtherGets the list of non-PROV attributes.This accessor method returns a reference to the live list, not a snapshot. Therefore, any modification made to the returned list will be present inside the object. This is why there is not a
setmethod for the role property.For example, to add a new item, do as follows:
getOther().add(newItem);
-
equals
public void equals(Object object, EqualsBuilder equalsBuilder)
-
equals2
public void equals2(Object object, EqualsBuilder equalsBuilder)
-
hashCode
public void hashCode(HashCodeBuilder hashCodeBuilder)
-
toString
public void toString(ToStringBuilder toStringBuilder)
-
getAttributes
public Collection<Attribute> getAttributes()
- Specified by:
getAttributesin interfaceHasAttributes
-
getIndexedAttributes
public Map<QualifiedName,Set<Attribute>> getIndexedAttributes()
- Specified by:
getIndexedAttributesin interfaceHasAttributes
-
-