java.lang.Object
org.biopax.paxtools.pattern.constraint.ConBox

public class ConBox extends Object
Some predefined constraints.
Author:
Ozgun Babur
  • Constructor Details

    • ConBox

      public ConBox()
  • Method Details

    • erToPE

      public static Constraint erToPE()
      From EntityReference to the member PhysicalEntity
      Returns:
      generative constraint to get to the member PhysicalEntity of the EntityReference
    • peToER

      public static Constraint peToER()
      From SimplePhysicalEntity to its EntityReference.
      Returns:
      generative constraint to get the EntityReference of the SimplePhysicalEntity
    • peToControl

      public static Constraint peToControl()
      From PhysicalEntity to the downstream Control
      Returns:
      generative constraint to get the Control that the PhysicalEntity is a controller
    • peToControlledConv

      public static Constraint peToControlledConv()
      From PhysicalEntity to the downstream Conversion.
      Returns:
      generative constraint to get the Conversion that the PhysicalEntity is a controller
    • peToControlledInter

      public static Constraint peToControlledInter()
      From PhysicalEntity to the downstream Interaction.
      Returns:
      generative constraint to get the Interaction that the PhysicalEntity is a controller
    • peToInter

      public static Constraint peToInter()
      From PhysicalEntity to the related Interaction.
      Returns:
      generative constraint to get the Interaction that the PhysicalEntity is a controller
    • simplePEToConv

      public static Constraint simplePEToConv(RelType type)
      From simple PhysicalEntity to related Conversion. The relation can be through complexes and generics.
      Parameters:
      type - relationship type
      Returns:
      generative constraint
    • interToPE

      public static Constraint interToPE()
      From Interaction to the related PhysicalEntity.
      Returns:
      the constraint
    • controlled

      public static Constraint controlled()
      From Control to the controlled Process
      Returns:
      generative constraint to get the controlled Process of the Control
    • controllerPE

      public static Constraint controllerPE()
      From Control to the controller PhysicalEntity
      Returns:
      generative constraint to get the controller PhysicalEntity of the Control
    • controlToConv

      public static Constraint controlToConv()
      From Control to the controlled Conversion, traversing downstream Controls recursively.
      Returns:
      generative constraint to get the downstream (controlled) Conversion of the Control
    • controlToTempReac

      public static Constraint controlToTempReac()
      From Control to the controlled TemplateReaction, traversing downstream Controls recursively.
      Returns:
      generative constraint to get the downstream (controlled) TemplateReaction of the Control
    • controlToInter

      public static Constraint controlToInter()
      From Control to the controlled Interaction, traversing downstream Controls recursively.
      Returns:
      generative constraint to get the downstream (controlled) Interaction of the Control
    • convToControl

      public static Constraint convToControl()
      From Conversion to the upstream Control (and its upstream Control recursively).
      Returns:
      generative constraint to get the upstream Controls of the Conversion
    • convToController

      public static Constraint convToController()
      From Conversion to the controller of the upstream Control (and its upstream Control recursively).
      Returns:
      the constraint
    • interToControl

      public static Constraint interToControl()
      From Interaction to the upstream Control (and its upstream Control recursively).
      Returns:
      generative constraint to get the upstream Controls of the Interaction
    • controlsConv

      public static Constraint controlsConv()
      From PhysicalEntity to the controlled Conversion, skipping the middle Control.
      Returns:
      generative constraint to get the Conversion that the PhysicalEntity controls
    • controlsInteraction

      public static Constraint controlsInteraction()
      From PhysicalEntity to the controlled Interaction, skipping the middle Control.
      Returns:
      generative constraint to get the Interaction that the PhysicalEntity controls
    • nextInteraction

      public static Constraint nextInteraction()
      Starts from an Interaction and gets next Interactions in temporal order, if ever defined in a Pathway.
      Returns:
      generative constraint
    • genericEquiv

      public static Constraint genericEquiv()
      From PhysicalEntity to its generic equivalents, i.e. either parent PhysicalEntity recursively or member PhysicalEntity recursively. Note that another member of the parent is not a generic equivalent.
      Returns:
      generative constraint to get the generic equivalents of the PhysicalEntity
    • complexMembers

      public static Constraint complexMembers()
      From Complex to its members recursively (also getting member of the inner complexes).
      Returns:
      generative constraint to get the members of the Complex
    • simpleMembers

      public static Constraint simpleMembers()
      From complex to its simple members (members which are of type SimplePhysicalEntity) recursively.
      Returns:
      generative constraint to get the simple members of the Complex recursively
    • withComplexMembers

      public static Constraint withComplexMembers()
      From Complex to its members, or the complex itself.
      Returns:
      generative constraint to get the members of a complex and to itself
    • withSimpleMembers

      public static Constraint withSimpleMembers()
      From complex to its simple members recursively, or the Complex itself
      Returns:
      generative constraint to get the simple members of the Complex recursively, or the Complex itself
    • complexes

      public static Constraint complexes()
      From PhysicalEntity to its parent Complex recursively.
      Returns:
      generative constraint to get the parent Complex of the PhysicalEntity recursively
    • withComplexes

      public static Constraint withComplexes()
      From PhysicalEntity to parent Complex recursively, or to itself.
      Returns:
      generative constraint to get the parent Complex of PhysicalEntity recursively, ot to itself
    • left

      public static Constraint left()
      From Conversion to its left participants.
      Returns:
      generative constraint to get the left participants of the Conversion
    • right

      public static Constraint right()
      From Conversion to its right participants.
      Returns:
      generative constraint to get the right participants of the Conversion
    • participatesInConv

      public static Constraint participatesInConv()
      From PhysicalEntity to the Conversion that it participates.
      Returns:
      generative constraint to get the Conversions that the PhysicalEntity is a participant of
    • participatesInInter

      public static Constraint participatesInInter()
      From PhysicalEntity to the Interaction that it participates.
      Returns:
      generative constraint to get the Interactions that the PhysicalEntity is a participant of
    • interToController

      public static Constraint interToController()
      From Interaction to the controlling Controls recursively, and their controller PEs.
      Returns:
      the constraint
    • compToER

      public static Constraint compToER()
      From Complex or SimplePhysicalEntity to the related EntityReference. If Complex, then EntityReference of simple members (recursively) are related.
      Returns:
      generative constraint to get the related EntityReference of the Complex or SimplePhysicalEntity
    • nameEquals

      public static Constraint nameEquals(String name)
      Filters Named to contain a specific name.
      Parameters:
      name - name to require
      Returns:
      constraint to check if the name exists in among names
    • nameEquals

      public static Constraint nameEquals(String... name)
      Filters Named to contain a name from the input set.
      Parameters:
      name - name to require
      Returns:
      constraint
    • differentialActivity

      public static Constraint differentialActivity(boolean activating)
      Gets a constraint to ensure that ensures only one of the two PhysicalEntities has an activity. Size of this constraint is 2.
      Parameters:
      activating - true/false (TODO explain)
      Returns:
      constraint to make sure only one of the PhysicalEntity has an activity
    • participant

      public static Constraint participant()
      From Interaction to its PhysicalEntity participants.
      Returns:
      generative constraint to get the participants of the Interaction
    • participantER

      public static Constraint participantER()
      From Interaction to the related EntityReference of its participants.
      Returns:
      generative constraint to get the related PhysicalEntity of the participants of an Interaction
    • product

      public static Constraint product()
      From TemplateReaction to its products.
      Returns:
      generative constraint to get the products of the TemplateReaction
    • notControlled

      public static Constraint notControlled()
      Makes sure the Interaction has no Control
      Returns:
      constraint to filter out Interactions with a Control
    • isHuman

      public static Constraint isHuman()
      Makes sure the EntityReference or the PhysicalEntity belongs to human. Please note that this check depends on the display name of the related BioSource object to be "Homo sapiens". If that is not the case, the constraint won't work.
      Returns:
      constraint to make sure the EntityReference or the PhysicalEntity belongs to human
    • hasXref

      public static Constraint hasXref(String xrefID)
      Makes sure that the object has an Xref with the given ID. This id is not an RDF ID, it is the value of the Xref, like gene symbol.
      Parameters:
      xrefID - xref id
      Returns:
      constraint
    • hasProvenance

      public static Constraint hasProvenance(String name)
      Makes sure that the object is associated with a Provenance with the given name. This id is not an RDF ID, it is the name of the resource, like TRANSFAC.
      Parameters:
      name - name of the provenance
      Returns:
      constraint
    • notAParticipant

      public static Constraint notAParticipant()
      Makes sure that the second element (PhysicalEntity) is not a participant of the first element (Interaction).
      Returns:
      constraint to make sure that the PhysicalEntity in second index is not a participant of the Interaction in first index
    • peNotRelatedToER

      public static Constraint peNotRelatedToER()
      Makes sure that the given physical entity is not related to the entity reference.
      Returns:
      the constraint todo: method not tested
    • notControlsThis

      public static Constraint notControlsThis()
      Makes sure the second element (Control) is not a controller to the first element (Interaction).
      Returns:
      constraint to filter out cases where the Control at the second index is controlling the Interaction at the first index.
    • notLabeledInactive

      public static Constraint notLabeledInactive()
      Makes sure a PhysicalEntity of any linked member PhysicalEntities toward members are not labeled as inactive.
      Returns:
      constraint to filter out PhysicalEntity labeled as inactive.
    • modificationConstraint

      public static Constraint modificationConstraint(String modifTerm)
      Makes sure that the PhysicalEntity or any linked PE contains the modification term. Size = 1.
      Parameters:
      modifTerm - term to check
      Returns:
      constraint to filter out PhysicalEntity not associated to a modification term
    • linkToSpecific

      public static Constraint linkToSpecific()
      Makes a linker constraint from PhysicalEntity to its linked PhysicalEntity towards member direction.
      Returns:
      the constraint
    • linkToComplex

      public static Constraint linkToComplex()
      Makes a linker constraint from PhysicalEntity to its linked PhysicalEntity towards complex direction.
      Returns:
      the constraint
    • linkedER

      public static Constraint linkedER(boolean up)
    • linkToSimple

      public static Constraint linkToSimple(Blacklist blacklist)
      Makes a linker constraint from PhysicalEntity to its linked PhysicalEntity towards member direction.
      Parameters:
      blacklist - used to detect ubiquitous small molecules
      Returns:
      the constraint
    • linkToComplex

      public static Constraint linkToComplex(Blacklist blacklist)
      Makes a linker constraint from PhysicalEntity to its linked PhysicalEntity towards complex direction.
      Parameters:
      blacklist - used to detect ubiquitous small molecules
      Returns:
      the constraint
    • equal

      public static Constraint equal(boolean equal)
      Makes a linker constraint from PhysicalEntity to its linked PhysicalEntity towards complex direction.
      Parameters:
      equal - true/false (TODO explain)
      Returns:
      the constraint
    • type

      public static Constraint type(Class<? extends BioPAXElement> clazz)
      Creates an element type constraint.
      Parameters:
      clazz - a BioPAX type, i.e., corresponding interface class
      Returns:
      the constraint
    • notGeneric

      public static Constraint notGeneric()
      Makes sure that the PhysicalEntity do not have member physical entities..
      Returns:
      the constraint
    • maxDegree

      public static Constraint maxDegree(int limit)
      Makes sure the participant degree (number of Conversions that this is a participant) of the PhysicalEntity is less than or equal to the parameter.
      Parameters:
      limit - max degree limit
      Returns:
      the constraint
    • source

      public static Constraint source(String dbname)
    • inSamePathway

      public static Constraint inSamePathway()
      Makes sure that the two interactions are members of the same pathway.
      Returns:
      non-generative constraint
    • moreControllerThanParticipant

      public static Constraint moreControllerThanParticipant()
      Makes sure that the PhysicalEntity is controlling more reactions than it participates (excluding complex assembly).
      Returns:
      non-generative constraint
    • hasDifferentCompartments

      public static Constraint hasDifferentCompartments()
      Checks if two physical entities have non-empty and different compartments.
      Returns:
      the constraint
    • isPrey

      public static Constraint isPrey()
      Checks if the molecule is a prey of a Y2H experiment.
      Returns:
      the constraint
    • isBait

      public static Constraint isBait()
      Checks if the molecule is a bait of a Y2H experiment.
      Returns:
      the constraint