X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fdatamodel%2Ffeatures%2FFeatureMatcherI.java;h=f1f85855bdd6ad22ba87c7c4eb9102616388550d;hb=da8e34c5aeee5e83aa844d374eb21e4c2e3cebef;hp=078f4a49593ed7a992fe84f75603c0a90ba6a0bf;hpb=1aa039ed9dfe0528cb7b40231734cf3004452c39;p=jalview.git diff --git a/src/jalview/datamodel/features/FeatureMatcherI.java b/src/jalview/datamodel/features/FeatureMatcherI.java index 078f4a4..f1f8585 100644 --- a/src/jalview/datamodel/features/FeatureMatcherI.java +++ b/src/jalview/datamodel/features/FeatureMatcherI.java @@ -21,11 +21,33 @@ public interface FeatureMatcherI boolean matches(SequenceFeature feature); /** - * Answers the value key this matcher operates on + * Answers the attribute key this matcher operates on (or null if match is by + * Label or Score) * * @return */ - String[] getKey(); + String[] getAttribute(); + + /** + * Answers true if match is against feature label (description), else false + * + * @return + */ + boolean isByLabel(); + + /** + * Answers true if match is against feature score, else false + * + * @return + */ + boolean isByScore(); + + /** + * Answers true if match is against a feature attribute (text or range) + * + * @return + */ + boolean isByAttribute(); /** * Answers the match condition that is applied @@ -33,4 +55,11 @@ public interface FeatureMatcherI * @return */ MatcherI getMatcher(); + + /** + * Answers a string representation of this object suitable for use when + * persisting data, in a format that can be reliably read back. Any changes to + * the format should be backwards compatible. + */ + String toStableString(); }