ConflictResolvingLeftArrowRule.cc
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #include "SimpleCenterLeftArrowRule.h"
00018
00019 SimpleCenterLeftArrowRule::SimpleCenterLeftArrowRule
00020 (const std::string &name,
00021 const SymbolPair ¢er,
00022 const OtherSymbolTransducerVector &contexts):
00023 LeftArrowRule(name,OtherTransducer(center.first,center.second),contexts)
00024 {}
00025
00026 bool SimpleCenterLeftArrowRule::conflicts_this
00027 (SimpleCenterLeftArrowRule &another)
00028 { return context.is_empty_intersection(another); }
00029
00030 bool SimpleCenterLeftArrowRule::resolvable_conflict
00031 (SimpleCenterLeftArrowRule &another)
00032 { return context.is_subset(another); }
00033
00034 void SimpleCenterLeftArrowRule::resolve_conflict
00035 (const SimpleCenterLeftArrowRule &another)
00036 { context.apply(&HfstTransducer::subtract,another); }
00037