本文整理了Java中uk.ac.ebi.intact.model.Feature.setComponent()
方法的一些代码示例,展示了Feature.setComponent()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Feature.setComponent()
方法的具体详情如下:
包路径:uk.ac.ebi.intact.model.Feature
类名称:Feature
方法名:setComponent
[英]This method adds a 'callback' to the Component to which a Feature applies. It has the SIDE EFFECT of also adding the Feature object to the Component's list of binding domians.
[中]此方法向应用功能的组件添加“回调”。它的副作用是将要素对象添加到组件的绑定域列表中。
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core-readonly
public void removeFeature( Feature feature ) {
boolean removed = this.bindingDomains.remove( feature );
if ( removed ) {
feature.setComponent( null );
}
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core-readonly
public void addFeature( Feature feature ) {
// we accept duplicated features in a participant if we want to link a binding site to different features
//if ( !this.bindingDomains.contains( feature ) ) {
this.bindingDomains.add( feature );
feature.setComponent( this );
//}
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core
public void removeFeature( Feature feature ) {
boolean removed = this.bindingDomains.remove( feature );
if ( removed ) {
feature.setComponent( null );
}
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core
public void addFeature( Feature feature ) {
// we accept duplicated features in a participant if we want to link a binding site to different features
//if ( !this.bindingDomains.contains( feature ) ) {
this.bindingDomains.add( feature );
feature.setComponent( this );
//}
}
代码示例来源:origin: uk.ac.ebi.intact/intact-core
public void removeBindingDomain( Feature feature ) {
boolean removed = this.bindingDomains.remove( feature );
if ( removed ) {
feature.setComponent( null );
}
}
代码示例来源:origin: uk.ac.ebi.intact/intact-core
public void addBindingDomain( Feature feature ) {
if ( !this.bindingDomains.contains( feature ) ) {
this.bindingDomains.add( feature );
feature.setComponent( this );
}
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core
/**
* This creates a stable (non-random) interaction
*/
public Interaction createDeterministicInteraction() {
Interaction interaction = createInteraction("fooprey-barbait",
createDeterministicProtein("A2", "barbait"),
createDeterministicProtein("A1", "fooprey"),
createDeterministicExperiment());
interaction.getAnnotations().add(createAnnotation("This is an annotation", CvTopic.COMMENT_MI_REF, CvTopic.COMMENT));
CvFeatureType featureType = createCvObject(CvFeatureType.class, CvFeatureType.EXPERIMENTAL_FEATURE_MI_REF, CvFeatureType.EXPERIMENTAL_FEATURE);
Feature feature = createFeature("feature1", featureType);
feature.setComponent(null);
Range range = createRange(1, 1, 5, 5);
feature.addRange(range);
interaction.getComponents().iterator().next().addBindingDomain(feature);
// interaction.getComponents().iterator().next().addComponentParameter(createDeterministicComponentParameter());
// interaction.addXref(createPrimaryReferenceXref( interaction , "testreference"));
interaction.addConfidence( createDeterministicConfidence());
interaction.addParameter( createDeterministicInteractionParameter() );
return interaction;
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core-readonly
/**
* This creates a stable (non-random) interaction
*/
public Interaction createDeterministicInteraction() {
Interaction interaction = createInteraction("fooprey-barbait",
createDeterministicProtein("A2", "barbait"),
createDeterministicProtein("A1", "fooprey"),
createDeterministicExperiment());
interaction.getAnnotations().add(createAnnotation("This is an annotation", CvTopic.COMMENT_MI_REF, CvTopic.COMMENT));
CvFeatureType featureType = createCvObject(CvFeatureType.class, CvFeatureType.EXPERIMENTAL_FEATURE_MI_REF, CvFeatureType.EXPERIMENTAL_FEATURE);
Feature feature = createFeature("feature1", featureType);
feature.setComponent(null);
Range range = createRange(1, 1, 5, 5);
feature.addRange(range);
interaction.getComponents().iterator().next().addBindingDomain(feature);
// interaction.getComponents().iterator().next().addComponentParameter(createDeterministicComponentParameter());
// interaction.addXref(createPrimaryReferenceXref( interaction , "testreference"));
interaction.addConfidence( createDeterministicConfidence());
interaction.addParameter( createDeterministicInteractionParameter() );
return interaction;
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core-readonly
private void synchronizeFeature( Feature feature, boolean synchronizeAnnotatedAttributes ) {
feature.setBoundDomain( synchronize( feature.getBoundDomain() ) );
feature.setComponent( synchronize( feature.getComponent() ) );
feature.setCvFeatureIdentification( synchronize( feature.getCvFeatureIdentification() ) );
feature.setCvFeatureType( synchronize( feature.getCvFeatureType() ) );
// cannot call setRanges in interaction because of orphan relationship limitation
if (IntactCore.isInitializedAndDirty(feature.getRanges())){
Collection<Range> ranges = synchronizeRanges(feature.getRanges(), feature);
feature.getRanges().clear();
feature.getRanges().addAll(ranges);
}
if (synchronizeAnnotatedAttributes){
synchronizeAnnotatedObjectCommons( feature );
}
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core
private void synchronizeFeature( Feature feature, boolean synchronizeAnnotatedAttributes ) {
feature.setBoundDomain( synchronize( feature.getBoundDomain() ) );
feature.setComponent( synchronize( feature.getComponent() ) );
feature.setCvFeatureIdentification( synchronize( feature.getCvFeatureIdentification() ) );
feature.setCvFeatureType( synchronize( feature.getCvFeatureType() ) );
// cannot call setRanges in interaction because of orphan relationship limitation
if (IntactCore.isInitializedAndDirty(feature.getRanges())){
Collection<Range> ranges = synchronizeRanges(feature.getRanges(), feature);
feature.getRanges().clear();
feature.getRanges().addAll(ranges);
}
if (synchronizeAnnotatedAttributes){
synchronizeAnnotatedObjectCommons( feature );
}
}
代码示例来源:origin: uk.ac.ebi.intact.dataexchange.psimi/intact-psixml-converters
Feature feature = featureConverter.psiToIntact(psiFeature);
component.getBindingDomains().add(feature);
feature.setComponent(component);
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core
protected void copyComponent( Component source, Component target ) {
copyProperty(source, "stoichiometry", target);
copyProperty(source, "interaction", target);
copyProperty(source, "interactor", target);
copyProperty(source, "cvBiologicalRole", target);
copyProperty(source, "cvExperimentalRole", target);
copyProperty(source, "expressedIn", target);
copyCollection( source.getBindingDomains(), target.getBindingDomains() );
for (Feature bindingDomain : target.getBindingDomains()) {
bindingDomain.setComponent(target);
}
copyCollection( source.getExperimentalPreparations(), target.getExperimentalPreparations() );
copyCollection( source.getParticipantDetectionMethods(), target.getParticipantDetectionMethods() );
copyCollection( source.getParameters(), target.getParameters() );
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core-readonly
protected void copyComponent( Component source, Component target ) {
copyProperty(source, "stoichiometry", target);
copyProperty(source, "interaction", target);
copyProperty(source, "interactor", target);
copyProperty(source, "cvBiologicalRole", target);
copyProperty(source, "cvExperimentalRole", target);
copyProperty(source, "expressedIn", target);
copyCollection( source.getBindingDomains(), target.getBindingDomains() );
for (Feature bindingDomain : target.getBindingDomains()) {
bindingDomain.setComponent(target);
}
copyCollection( source.getExperimentalPreparations(), target.getExperimentalPreparations() );
copyCollection( source.getParticipantDetectionMethods(), target.getParticipantDetectionMethods() );
copyCollection( source.getParameters(), target.getParameters() );
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core
public Feature cloneFeature(Feature feature) throws IntactClonerException {
if (feature == null) return null;
Feature clone = new Feature();
clonerManager.addClone(feature, clone);
clone.setOwner(clone(feature.getOwner()));
clone.setShortLabel(feature.getShortLabel());
clone.setCvFeatureType(clone(feature.getCvFeatureType()));
clone.setCvFeatureIdentification(clone(feature.getCvFeatureIdentification()));
if (isCollectionClonable(feature.getRanges())) {
Collection<Range> ranges = IntactCore.ensureInitializedRanges(feature);
for (Range range : ranges) {
clone.addRange(clone(range));
}
}
clone.setComponent(clone(feature.getComponent()));
return clone;
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-core-readonly
public Feature cloneFeature(Feature feature) throws IntactClonerException {
if (feature == null) return null;
Feature clone = new Feature();
clonerManager.addClone(feature, clone);
clone.setOwner(clone(feature.getOwner()));
clone.setShortLabel(feature.getShortLabel());
clone.setCvFeatureType(clone(feature.getCvFeatureType()));
clone.setCvFeatureIdentification(clone(feature.getCvFeatureIdentification()));
if (isCollectionClonable(feature.getRanges())) {
Collection<Range> ranges = IntactCore.ensureInitializedRanges(feature);
for (Range range : ranges) {
clone.addRange(clone(range));
}
}
clone.setComponent(clone(feature.getComponent()));
return clone;
}
代码示例来源:origin: uk.ac.ebi.intact.core/intact-persister
intactObject.setComponent(component);
内容来源于网络,如有侵权,请联系作者删除!