コード例 #1
0
 def createNameFilter(self):
     '''
     returns name filter (InflFilterMatch instance) based on control values
     '''
     filter = InfluenceNameFilter()
     filter.setFilterString(self.influenceNameFilter.getValue())
     return filter
コード例 #2
0
ファイル: layerListsUI.py プロジェクト: xtoof/Tapp
 def createNameFilter(self):
     '''
     returns name filter (InflFilterMatch instance) based on control values
     '''
     filter = InfluenceNameFilter()
     filter.setFilterString(self.influenceNameFilter.getValue())
     return filter
コード例 #3
0
 def testPartialMatch(self):
     f = InfluenceNameFilter().setFilterString("joint")
     self.assertTrue(f.isMatch("joint1"))
     self.assertTrue(f.isMatch("joint2"))
コード例 #4
0
 def testFilterOutGarbage(self):
     f = InfluenceNameFilter().setFilterString("joint)({}#$%^@#@!&&&#1")
     self.assertTrue(f.isMatch("joint1"))
     self.assertFalse(f.isMatch("joint2"))
コード例 #5
0
 def testCaseInsensitive(self):
     f = InfluenceNameFilter().setFilterString("L_finger4_1 l_finger4_2")
     
     self.assertTrue(f.isMatch("l_finger4_1"))
     self.assertTrue(f.isMatch("L_finger4_2"))
     self.assertFalse(f.isMatch("R_finger4_1"))
コード例 #6
0
 def testMultiMatch(self):
     f = InfluenceNameFilter().setFilterString("joint1 joint2")
     
     self.assertTrue(f.isMatch("joint1"))
     self.assertTrue(f.isMatch("joint2"))
     self.assertFalse(f.isMatch("joint3"))
コード例 #7
0
 def testWildcardMatch(self):
     f = InfluenceNameFilter().setFilterString("joint*_1")
     self.assertTrue(f.isMatch("joint1_1"))
     self.assertTrue(f.isMatch("joint55_1"))
     self.assertTrue(f.isMatch("joint_1"))
     self.assertFalse(f.isMatch("joint1_2"))
コード例 #8
0
 def testPartialMatch(self):
     f = InfluenceNameFilter().setFilterString("joint")
     self.assertTrue(f.isMatch("joint1"))
     self.assertTrue(f.isMatch("joint2"))
コード例 #9
0
    def testCaseInsensitive(self):
        f = InfluenceNameFilter().setFilterString("L_finger4_1 l_finger4_2")

        self.assertTrue(f.isMatch("l_finger4_1"))
        self.assertTrue(f.isMatch("L_finger4_2"))
        self.assertFalse(f.isMatch("R_finger4_1"))
コード例 #10
0
 def testFilterOutGarbage(self):
     f = InfluenceNameFilter().setFilterString("joint)({}#$%^@#@!&&&#1")
     self.assertTrue(f.isMatch("joint1"))
     self.assertFalse(f.isMatch("joint2"))
コード例 #11
0
 def testWildcardMatch(self):
     f = InfluenceNameFilter().setFilterString("joint*_1")
     self.assertTrue(f.isMatch("joint1_1"))
     self.assertTrue(f.isMatch("joint55_1"))
     self.assertTrue(f.isMatch("joint_1"))
     self.assertFalse(f.isMatch("joint1_2"))
コード例 #12
0
    def testMultiMatch(self):
        f = InfluenceNameFilter().setFilterString("joint1 joint2")

        self.assertTrue(f.isMatch("joint1"))
        self.assertTrue(f.isMatch("joint2"))
        self.assertFalse(f.isMatch("joint3"))