| Trees | Indices | Help |
|
|---|
|
|
1 # Copyright 2004-2008 Roman Yakovenko. 2 # Distributed under the Boost Software License, Version 1.0. (See 3 # accompanying file LICENSE_1_0.txt or copy at 4 # http://www.boost.org/LICENSE_1_0.txt) 5 6 import os 7 import types 8 import algorithm 9 import code_creator 10 import declaration_based 11 import registration_based 12 from pygccxml import declarations13 14 -class indexing_suite1_t( registration_based.registration_based_t 15 , declaration_based.declaration_based_t ):23 24 @property17 registration_based.registration_based_t.__init__( self ) 18 declaration_based.declaration_based_t.__init__( self, declaration=container )19 20 @property 22 return self.declaration.indexing_suite26 return self.declaration2729 if self.container.name.startswith( 'vector' ): 30 return 'boost::python::vector_indexing_suite' 31 else: 32 return 'boost::python::map_indexing_suite'3335 suite_identifier = algorithm.create_identifier( self, self.guess_suite_name() ) 36 args = [ self.container.partial_decl_string ] 37 try: 38 no_proxy = str( self.configuration.no_proxy ).lower() 39 except: 40 no_proxy = 'false' 41 if self.configuration.derived_policies: 42 args.append( no_proxy ) 43 args.append( self.configuration.derived_policies ) 44 else: 45 if 'true' == no_proxy: 46 args.append( no_proxy) 47 return declarations.templates.join( suite_identifier, args )48 50 return "def( %s() )" % self._create_suite_declaration() 51 5455 -class indexing_suite2_t( registration_based.registration_based_t 56 , declaration_based.declaration_based_t ):