예제 #1
0
파일: objects.py 프로젝트: flynx/pli
	def __getattr__(self, name):
		'''
		'''
		if not hasattr(self, '__implements__') or self.__implements__ == None or \
				interface.isreadable(self, name):
			return getattr(self.__source__, name)
		raise interface.InterfaceError, 'can\'t read attribute "%s".' % name
예제 #2
0
파일: objects.py 프로젝트: flynx/pli
	def __getattribute__(self, name):
		'''
		'''
		if name in ('__implements__',) or \
				not hasattr(self, '__implements__') or self.__implements__ == None or \
				interface.isreadable(self, name):
			return super(ObjectWithInterface, self).__getattribute__(name)
		raise interface.InterfaceError, 'can\'t read attribute "%s".' % name