Module prov.model

Interface Used

All Superinterfaces:
HasLabel, HasLocation, HasOther, HasRole, HasTime, HasType, Identifiable, Influence, QualifiedRelation, Relation, Statement, StatementOrBundle
All Known Implementing Classes:
Used

Interface for PROV Usage association.

PROV-DM Definition for Usage: Usage is the beginning of utilizing an entity by an activity. Before usage, the activity had not begun to utilize this entity and could not have been affected by the entity.

The constructor method ProvFactory.newUsed(QualifiedName, QualifiedName, QualifiedName) can be used to create an instance of Used. The following code snippet creates a new usage statement, with a role attribute, and current time. The instance of usage is given an identifier myId.

 QualifiedName myId= ... ;  // some qualified name
 QualifiedName activityId= ... ;  // some activity qualified name
 QualifiedName entityId= ... ;    // some entity qualified name
 Used myUsed=provFactory.newUsed(myId,activityId,entityId);
 myUsed.getRole().add(provFactory.newRole("parameter"));
 myUsed.setTime(provFactory.newTimeNow())
 

Relevant Factory Methods:

Schema Definition:

The following schema fragment specifies the expected content contained within this class.

 <complexType name="Usage">
   <complexContent>
     <restriction base="{http://www.w3.org/2001/XMLSchema}anyType">
       <sequence>
         <element name="activity" type="{http://www.w3.org/ns/prov#}IDRef"/>
         <element name="entity" type="{http://www.w3.org/ns/prov#}IDRef"/>
         <element name="time" type="{http://www.w3.org/2001/XMLSchema}dateTime" minOccurs="0"/>
         <element ref="{http://www.w3.org/ns/prov#}label" maxOccurs="unbounded" minOccurs="0"/>
         <element ref="{http://www.w3.org/ns/prov#}location" maxOccurs="unbounded" minOccurs="0"/>
         <element ref="{http://www.w3.org/ns/prov#}role" maxOccurs="unbounded" minOccurs="0"/>
         <element ref="{http://www.w3.org/ns/prov#}type" maxOccurs="unbounded" minOccurs="0"/>
         <any namespace='##other' maxOccurs="unbounded" minOccurs="0"/>
       </sequence>
       <attribute ref="{http://www.w3.org/ns/prov#}id"/>
     </restriction>
   </complexContent>
 </complexType>
 

See Also: