Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Config
- # ... il y a du code avant
- # Find the appropriate signature for the given file
- def find(_text)
- processed = Signature.splitSentence(_text)
- values = {}
- @signatures.each do |sig|
- values\[sig.compute(processed)\]=sig
- end
- sortedValues = values.sort {|a,b| -1*(a\[0\]< =>b\[0\])}
- return sortedValues\[0\]\[1\].signatureText
- end
Add Comment
Please, Sign In to add comment