Changeset 23
- Timestamp:
- 02/01/08 15:15:56 (1 year ago)
- Files:
-
- project/trunk/src/pyxoo/__init__.py (modified) (2 diffs)
- project/trunk/src/pyxoo/command.py (modified) (1 diff)
- project/trunk/src/pyxoo/core.py (modified) (1 diff)
- project/trunk/src/pyxoo/event.py (modified) (1 diff)
- project/trunk/src/pyxoo/exceptions.py (modified) (1 diff)
- project/trunk/src/pyxoo/model.py (modified) (1 diff)
- project/trunk/src/pyxoo/plugin.py (modified) (1 diff)
- project/trunk/src/pyxoo/service.py (modified) (1 diff)
- project/trunk/src/pyxoo/utils/__init__.py (modified) (1 diff)
- project/trunk/src/pyxoo/utils/interface.py (modified) (1 diff)
- project/trunk/src/pyxoo/utils/map.py (modified) (1 diff)
- project/trunk/src/pyxoo/utils/stringifier.py (modified) (1 diff)
- project/trunk/src/pyxoo/utils/type.py (modified) (1 diff)
- project/trunk/src/pyxoo/view.py (modified) (1 diff)
- project/trunk/test/commands/TestFrontController.py (modified) (1 diff)
- project/trunk/test/model/TestModelLocator.py (modified) (2 diffs)
- project/trunk/test/plugin/TestChannelExpert.py (modified) (1 diff)
- project/trunk/test/view/TestViewLocator.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
project/trunk/src/pyxoo/__init__.py
r22 r23 1 """ 2 Pyxoo 1 2 __licence__=""" 3 Pyxoo 3 4 4 5 Copyright the original author or authors. … … 17 18 """ 18 19 19 20 20 __version__ = "0.1" 21 21 __author__ = "Alexis Couronne" 22 __url__ = "www.pyxoo.org" 23 22 24 23 25 project/trunk/src/pyxoo/command.py
r22 r23 1 """ 2 Pyxoo 3 4 Copyright the original author or authors. 5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License"); 7 you may not use this file except in compliance with the License. 8 You may obtain a copy of the License at 9 10 http://www.mozilla.org/MPL/MPL-1.1.html 11 12 Unless required by applicable law or agreed to in writing, software 13 distributed under the License is distributed on an "AS IS" BASIS, 14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 See the License for the specific language governing permissions and 16 limitations under the License. 17 """ 1 18 2 19 3 import pyxoo, logging 20 4 21 5 __version__ = pyxoo.__version__ 6 __licence__ = pyxoo.__licence__ 7 __url__ = pyxoo.__url__ 22 8 __author__ = "Alexis Couronne" 9 23 10 24 11 project/trunk/src/pyxoo/core.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo, sys 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 project/trunk/src/pyxoo/event.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo, threading, logging, time 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 project/trunk/src/pyxoo/exceptions.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo, exceptions 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 project/trunk/src/pyxoo/model.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 project/trunk/src/pyxoo/plugin.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 24 9 25 class Plugin :10 class Plugin( pyxoo.utils.Interface ) : 26 11 def fireOnInitPlugin( self ): 27 12 """fireOnInitPlugin():void""" project/trunk/src/pyxoo/service.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Benoit Bar" project/trunk/src/pyxoo/utils/__init__.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 project/trunk/src/pyxoo/utils/interface.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo, types 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 project/trunk/src/pyxoo/utils/map.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 project/trunk/src/pyxoo/utils/stringifier.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 project/trunk/src/pyxoo/utils/type.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 1 19 2 import pyxoo, types 20 3 21 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 22 7 __author__ = "Alexis Couronne" 23 8 project/trunk/src/pyxoo/view.py
r22 r23 1 """2 Pyxoo3 4 Copyright the original author or authors.5 6 Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");7 you may not use this file except in compliance with the License.8 You may obtain a copy of the License at9 10 http://www.mozilla.org/MPL/MPL-1.1.html11 12 Unless required by applicable law or agreed to in writing, software13 distributed under the License is distributed on an "AS IS" BASIS,14 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.15 See the License for the specific language governing permissions and16 limitations under the License.17 """18 19 1 20 2 import pyxoo 21 3 22 4 __version__ = pyxoo.__version__ 5 __licence__ = pyxoo.__licence__ 6 __url__ = pyxoo.__url__ 23 7 __author__ = "Alexis Couronne" 24 8 project/trunk/test/commands/TestFrontController.py
r21 r23 30 30 def setUp( self ): 31 31 self.instance = pyxoo.command.FrontController() 32 self.aPlugin = pyxoo.plugin. Plugin()32 self.aPlugin = pyxoo.plugin.AbstractPlugin() 33 33 34 34 def testGetOwner( self ): project/trunk/test/model/TestModelLocator.py
r21 r23 32 32 def testMultiton( self ): 33 33 self.assertTrue( id( self.instance ) == id( pyxoo.model.ModelLocator.getInstance() ) ) 34 self.assertFalse( id( self.instance ) == id( pyxoo.model.ModelLocator.getInstance( pyxoo.plugin. Plugin() ) ) )35 pluginA, pluginB = pyxoo.plugin. Plugin(), pyxoo.plugin.Plugin()34 self.assertFalse( id( self.instance ) == id( pyxoo.model.ModelLocator.getInstance( pyxoo.plugin.AbstractPlugin() ) ) ) 35 pluginA, pluginB = pyxoo.plugin.AbstractPlugin(), pyxoo.plugin.AbstractPlugin() 36 36 self.assertTrue( id( pyxoo.model.ModelLocator.getInstance( pluginA ) ) == id( pyxoo.model.ModelLocator.getInstance( pluginA ) ) ) 37 37 self.assertFalse( id( pyxoo.model.ModelLocator.getInstance( pluginA ) ) == id( pyxoo.model.ModelLocator.getInstance( pluginB ) ) ) … … 43 43 44 44 def testRegisterModelWithPlugin( self ): 45 pluginA, pluginB = pyxoo.plugin. Plugin(), pyxoo.plugin.Plugin()45 pluginA, pluginB = pyxoo.plugin.AbstractPlugin(), pyxoo.plugin.AbstractPlugin() 46 46 self.assertTrue( pyxoo.model.ModelLocator.getInstance( pluginA ).registerModel( "v1", self.m1 ) ) 47 47 self.assertFalse( pyxoo.model.ModelLocator.getInstance( pluginA ).registerModel( "v1", self.m1 ) ) project/trunk/test/plugin/TestChannelExpert.py
r21 r23 23 23 class MockPlugin( pyxoo.plugin.Plugin ): 24 24 def getChannel( self ): 25 return self.channel 25 return self.channel 26 27 def fireOnInitPlugin( self ):pass 28 def fireOnReleasePlugin( self ):pass 29 def fireExternalEvent( self, event, eventChannel ):pass 30 def firePublicEvent( self, event ):pass 31 def firePrivateEvent( self, event ):pass 32 def getModelLocator( self ):pass 33 def getViewLocator( self ):pass 34 26 35 27 36 class TestChannelExpert( unittest.TestCase ): project/trunk/test/view/TestViewLocator.py
r21 r23 30 30 def testMultiTon( self ): 31 31 self.assertTrue( id( self.instance ) == id( pyxoo.view.ViewLocator.getInstance() ) ) 32 self.assertFalse( id( self.instance ) == id( pyxoo.view.ViewLocator.getInstance( pyxoo.plugin. Plugin() ) ) )33 pluginA, pluginB = pyxoo.plugin. Plugin(), pyxoo.plugin.Plugin()32 self.assertFalse( id( self.instance ) == id( pyxoo.view.ViewLocator.getInstance( pyxoo.plugin.AbstractPlugin() ) ) ) 33 pluginA, pluginB = pyxoo.plugin.AbstractPlugin(), pyxoo.plugin.AbstractPlugin() 34 34 self.assertTrue( id( pyxoo.view.ViewLocator.getInstance( pluginA ) ) == id( pyxoo.view.ViewLocator.getInstance( pluginA ) ) ) 35 35 self.assertFalse( id( pyxoo.view.ViewLocator.getInstance( pluginA ) ) == id( pyxoo.view.ViewLocator.getInstance( pluginB ) ) ) … … 43 43 44 44 def testResgisterViewWithPlugin( self ): 45 pluginA, pluginB = pyxoo.plugin. Plugin(), pyxoo.plugin.Plugin()45 pluginA, pluginB = pyxoo.plugin.AbstractPlugin(), pyxoo.plugin.AbstractPlugin() 46 46 self.assertTrue( pyxoo.view.ViewLocator.getInstance( pluginA ).registerView( "v1", self.view ) ) 47 47 self.assertFalse( pyxoo.view.ViewLocator.getInstance( pluginA ).registerView( "v1", self.view ) )
