MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/Falcor / AliasStubsGenerator

Class AliasStubsGenerator

build_scripts/pybind11_stubgen.py:862–885  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

860
861
862class AliasStubsGenerator(StubsGenerator):
863
864 def __init__(self, alias_name, origin):
865 self.alias_name = alias_name
866 self.origin = origin
867
868 def parse(self):
869 pass
870
871 def to_lines(self): # type: () -> List[str]
872 return [
873 "{alias} = {origin}".format(
874 alias=self.alias_name,
875 origin=self.fully_qualified_name(self.origin)
876 )
877 ]
878
879 def get_involved_modules_names(self): # type: () -> Set[str]
880 if inspect.ismodule(self.origin):
881 return {self.origin.__name__}
882 elif inspect.isroutine(self.origin) or inspect.isclass(self.origin):
883 return {self.origin.__module__.__name__}
884 else:
885 return set()
886
887
888class ModuleStubsGenerator(StubsGenerator):

Callers 2

parseMethod · 0.85
parseMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected